diff options
| author | Liam P. White <inkscapebrony@gmail.com> | 2014-08-06 16:47:36 +0000 |
|---|---|---|
| committer | Liam P. White <inkscapebrony@gmail.com> | 2014-08-06 16:47:36 +0000 |
| commit | ae2a18ac114c2abc0b9358142ece9d7a93ae10be (patch) | |
| tree | a904b2eba26c0db2d8b64ad6a6cf71221f5f558f /src/sp-star.cpp | |
| parent | Fix bug #1241501, improve tooltip text on path parameter (diff) | |
| download | inkscape-ae2a18ac114c2abc0b9358142ece9d7a93ae10be.tar.gz inkscape-ae2a18ac114c2abc0b9358142ece9d7a93ae10be.zip | |
Fix for bug #1348375 (randomized stars change on translation)
Fixed bugs:
- https://launchpad.net/bugs/1348375
(bzr r13495)
Diffstat (limited to 'src/sp-star.cpp')
| -rw-r--r-- | src/sp-star.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/sp-star.cpp b/src/sp-star.cpp index eac33ed7b..712029468 100644 --- a/src/sp-star.cpp +++ b/src/sp-star.cpp @@ -513,10 +513,12 @@ void SPStar::snappoints(std::vector<Inkscape::SnapCandidatePoint> &p, Inkscape:: } } -Geom::Affine SPStar::set_transform(Geom::Affine const &xform) +Geom::Affine SPStar::set_transform(Geom::Affine const &tform) { + Geom::Affine xform = (randomized == 0 ? tform.withoutTranslation() : tform); + // Only set transform with proportional scaling - if (!xform.withoutTranslation().isUniformScale()) { + if (!xform.isUniformScale()) { return xform; } @@ -530,7 +532,7 @@ Geom::Affine SPStar::set_transform(Geom::Affine const &xform) /* This function takes care of translation and scaling, we return whatever parts we can't handle. */ - Geom::Affine ret(Geom::Affine(xform).withoutTranslation()); + Geom::Affine ret(xform); gdouble const s = hypot(ret[0], ret[1]); if (s > 1e-9) { ret[0] /= s; |
