summaryrefslogtreecommitdiffstats
path: root/src/ui/tools/tweak-tool.cpp
diff options
context:
space:
mode:
authorMarc Jeanmougin <marc@jeanmougin.fr>2018-09-12 16:02:57 +0000
committerMarc Jeanmougin <marc@jeanmougin.fr>2018-09-12 16:02:57 +0000
commit197d4156fb11ec3e608d04e656a7b9e841c341d8 (patch)
tree148f0e5a97cac35451983625eb028f94fc4556d0 /src/ui/tools/tweak-tool.cpp
parentMore caching in prefs (diff)
parentAllow adding new properties (diff)
downloadinkscape-197d4156fb11ec3e608d04e656a7b9e841c341d8.tar.gz
inkscape-197d4156fb11ec3e608d04e656a7b9e841c341d8.zip
Merge branch 'master' of gitlab.com:inkscape/inkscape
Diffstat (limited to 'src/ui/tools/tweak-tool.cpp')
-rw-r--r--src/ui/tools/tweak-tool.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/ui/tools/tweak-tool.cpp b/src/ui/tools/tweak-tool.cpp
index 060131b49..d0b8209f0 100644
--- a/src/ui/tools/tweak-tool.cpp
+++ b/src/ui/tools/tweak-tool.cpp
@@ -397,7 +397,7 @@ sp_tweak_dilate_recursive (Inkscape::Selection *selection, SPItem *item, Geom::P
if (a->contains(p)) x = 0;
if (x < 1) {
Geom::Point move = force * 0.5 * (cos(M_PI * x) + 1) * vector;
- sp_item_move_rel(item, Geom::Translate(move[Geom::X], -move[Geom::Y]));
+ sp_item_move_rel(item, Geom::Translate(move * selection->desktop()->doc2dt().withoutTranslation()));
did = true;
}
}
@@ -411,7 +411,7 @@ sp_tweak_dilate_recursive (Inkscape::Selection *selection, SPItem *item, Geom::P
if (x < 1) {
Geom::Point move = force * 0.5 * (cos(M_PI * x) + 1) *
(reverse? (a->midpoint() - p) : (p - a->midpoint()));
- sp_item_move_rel(item, Geom::Translate(move[Geom::X], -move[Geom::Y]));
+ sp_item_move_rel(item, Geom::Translate(move * selection->desktop()->doc2dt().withoutTranslation()));
did = true;
}
}
@@ -426,7 +426,7 @@ sp_tweak_dilate_recursive (Inkscape::Selection *selection, SPItem *item, Geom::P
if (a->contains(p)) x = 0;
if (x < 1) {
Geom::Point move = force * 0.5 * (cos(M_PI * x) + 1) * Geom::Point(cos(dp)*dr, sin(dp)*dr);
- sp_item_move_rel(item, Geom::Translate(move[Geom::X], -move[Geom::Y]));
+ sp_item_move_rel(item, Geom::Translate(move * selection->desktop()->doc2dt().withoutTranslation()));
did = true;
}
}
@@ -452,6 +452,7 @@ sp_tweak_dilate_recursive (Inkscape::Selection *selection, SPItem *item, Geom::P
if (a->contains(p)) x = 0;
if (x < 1) {
double angle = (reverse? force : -force) * 0.05 * (cos(M_PI * x) + 1) * M_PI;
+ angle *= -selection->desktop()->yaxisdir();
sp_item_rotate_rel(item, Geom::Rotate(angle));
did = true;
}