From 280cfb3994a4b47f568c80ac357652b0c5b4e7b7 Mon Sep 17 00:00:00 2001 From: Anand Chitipothu Date: Tue, 23 Mar 2021 06:06:25 +0000 Subject: [PATCH] Fixed an error in rendering a line. Used the wrong arguments to line functions, fixed now. --- community/lms/doctype/lms_sketch/livecode.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/community/lms/doctype/lms_sketch/livecode.py b/community/lms/doctype/lms_sketch/livecode.py index 0069252d..91879000 100644 --- a/community/lms/doctype/lms_sketch/livecode.py +++ b/community/lms/doctype/lms_sketch/livecode.py @@ -42,7 +42,7 @@ def draw_image(commands): if c['function'] == 'circle': img.append(draw.Circle(cx=c['x'], cy=c['y'], r=c['d']/2)) elif c['function'] == 'line': - img.append(draw.Line(x1=c['x1'], y1=c['y1'], x2=c['x2'], y2=c['y2'])) + img.append(draw.Line(sx=c['x1'], sy=c['y1'], ex=c['x2'], ey=c['y2'])) elif c['function'] == 'rect': img.append(draw.Rectangle(x=c['x'], y=c['y'], width=c['w'], height=c['h'])) return img