summaryrefslogtreecommitdiffstats
path: root/src/selection-chemistry.cpp
diff options
context:
space:
mode:
authorKrzysztof Kosi??ski <tweenk.pl@gmail.com>2010-04-03 12:47:02 +0000
committerKrzysztof KosiƄski <tweenk.pl@gmail.com>2010-04-03 12:47:02 +0000
commitc2b0be4faa9e98c00ecce70c4aeb8e2fe1afdb2b (patch)
treee483a6ff0e1ed9f19a391195c8f2e241761a9f8c /src/selection-chemistry.cpp
parentFix tweak and paint bucket tools (diff)
downloadinkscape-c2b0be4faa9e98c00ecce70c4aeb8e2fe1afdb2b.tar.gz
inkscape-c2b0be4faa9e98c00ecce70c4aeb8e2fe1afdb2b.zip
Fix behavior when loading a document
(bzr r9281.1.7)
Diffstat (limited to 'src/selection-chemistry.cpp')
-rw-r--r--src/selection-chemistry.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/selection-chemistry.cpp b/src/selection-chemistry.cpp
index 7ac2e5471..452a4ff9d 100644
--- a/src/selection-chemistry.cpp
+++ b/src/selection-chemistry.cpp
@@ -2273,9 +2273,8 @@ void sp_selection_to_marker(SPDesktop *desktop, bool apply)
}
// calculate the transform to be applied to objects to move them to 0,0
- Geom::Point move_p = Geom::Point(0, sp_document_height(doc)) - *c;
- move_p[Geom::Y] = -move_p[Geom::Y];
- Geom::Matrix move = Geom::Matrix(Geom::Translate(move_p));
+ Geom::Point move_p = -*c;
+ Geom::Matrix move = Geom::Translate(move_p);
GSList *items = g_slist_copy((GSList *) selection->itemList());
@@ -2396,8 +2395,7 @@ sp_selection_tile(SPDesktop *desktop, bool apply)
}
// calculate the transform to be applied to objects to move them to 0,0
- Geom::Point move_p = Geom::Point(0, sp_document_height(doc)) - (r->min() + Geom::Point(0, r->dimensions()[Geom::Y]));
- move_p[Geom::Y] = -move_p[Geom::Y];
+ Geom::Point move_p = -(r->min() + Geom::Point(0, r->dimensions()[Geom::Y]));
Geom::Matrix move = Geom::Matrix(Geom::Translate(move_p));
GSList *items = g_slist_copy((GSList *) selection->itemList());