diff options
Diffstat (limited to 'svx/source/svdraw/svdopath.cxx')
-rw-r--r-- | svx/source/svdraw/svdopath.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/svx/source/svdraw/svdopath.cxx b/svx/source/svdraw/svdopath.cxx index dd4b02e4bb8b..f31cd683fd47 100644 --- a/svx/source/svdraw/svdopath.cxx +++ b/svx/source/svdraw/svdopath.cxx @@ -2320,6 +2320,20 @@ void SdrPathObj::NbcMove(const Size& rSiz) void SdrPathObj::NbcResize(const Point& rRef, const Fraction& xFact, const Fraction& yFact) { + const double fResizeX(xFact); + const double fResizeY(yFact); + + if(basegfx::fTools::equal(fResizeX, 1.0) && basegfx::fTools::equal(fResizeY, 1.0)) + { + // tdf#106792 avoid numerical unprecisions: If both scale factors are 1.0, do not + // manipulate at all - that may change aGeo rapidly (and wrongly) in + // SdrTextObj::NbcResize. Combined with the UNO API trying to not 'apply' + // a rotation but to manipulate the existing one, this is fatal. So just + // avoid this error as long as we have to deal with unprecise geometry + // manipulations + return; + } + basegfx::B2DHomMatrix aTrans(basegfx::utils::createTranslateB2DHomMatrix(-rRef.X(), -rRef.Y())); aTrans = basegfx::utils::createScaleTranslateB2DHomMatrix( double(xFact), double(yFact), rRef.X(), rRef.Y()) * aTrans; |