From 502e8785085f9e8b54ee383080442c2dcaf95b15 Mon Sep 17 00:00:00 2001 From: László Németh Date: Sat, 29 Sep 2018 20:32:28 +0200 Subject: LibreLogo: fix regression of line drawing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit related to measurement changes, for example we got only 5.7 cm long line for "FORWARD 10cm", because the processed value measured in 0.0100 mm instead of the correct twips (pt/20 ~ 0.0176mm). Note: only the line drawing was shorter, the turtle path didn't change, so the turle could draw only dashed line for multiple FORWARD or BACK, instead of a continuous one. regression from commit 36bade04d3780bc54c51b46bb0b63e69789658a5 tdf106792 Get rid of SvxShapePolyPolygonBezier Change-Id: I16d75dbdadef5af9c545abc86575490559b3d54c Reviewed-on: https://gerrit.libreoffice.org/61145 Tested-by: Jenkins Reviewed-by: László Németh --- librelogo/source/LibreLogo/LibreLogo.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'librelogo') diff --git a/librelogo/source/LibreLogo/LibreLogo.py b/librelogo/source/LibreLogo/LibreLogo.py index 96d2d131d32b..eb97fe1e1943 100644 --- a/librelogo/source/LibreLogo/LibreLogo.py +++ b/librelogo/source/LibreLogo/LibreLogo.py @@ -968,7 +968,7 @@ def __go__(shapename, n, dot = False, preciseAngle = -1): if shape and not _.pen and not dot: _.continuous = False return - c, c2 = __Point__(pos.X + turtle.BoundRect.Width / 2.0, pos.Y + turtle.BoundRect.Height / 2.0), __Point__(round(dx), round(dy)) + c, c2 = __Point__(pos.X + turtle.BoundRect.Width / 2.0, pos.Y + turtle.BoundRect.Height / 2.0), __Point__(round(dx / __MM10_TO_TWIP__), round(dy / __MM10_TO_TWIP__)) if shape and "LineShape" in shape.ShapeType: if _.continuous or dot: last = shape.PolyPolygon[-1][-1] -- cgit