From: dvlierop2 Date: Wed, 25 Jul 2007 12:07:39 +0000 (+0000) Subject: Snapping the transformation origin should also work for paths, not only for shapes X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=031c9271f8126586d050a273aed917eee58d278a;p=inkscape.git Snapping the transformation origin should also work for paths, not only for shapes --- diff --git a/src/selection.cpp b/src/selection.cpp index 44f601362..2b143dd5a 100644 --- a/src/selection.cpp +++ b/src/selection.cpp @@ -28,6 +28,7 @@ #include "sp-shape.h" #include "sp-path.h" +#include "sp-item-group.h" #include @@ -382,6 +383,9 @@ std::vector Selection::getSnapPoints() const { // (Same check occurs in sp-item-group) sp_item_snappoints(this_item, SnapPointsIter(p)); } + //Include the transformation origin for snapping + //For a group only the group's origin is considered + p.push_back(this_item->getCenter()); } return p; diff --git a/src/sp-item.cpp b/src/sp-item.cpp index 469b95222..309c42c90 100644 --- a/src/sp-item.cpp +++ b/src/sp-item.cpp @@ -787,8 +787,6 @@ void sp_item_snappoints(SPItem const *item, SnapPointsIter p) if (item_class.snappoints) { item_class.snappoints(item, p); } - - *p = item->getCenter(); } void