From a3c5f2627b27d773d358200481bfe9ea6c9bb49f Mon Sep 17 00:00:00 2001 From: joshvazquez Date: Wed, 1 Sep 2021 19:08:14 -0700 Subject: [PATCH] Get height from label context Height is hardcoded to 200 and causes printing to fail on QL-810W: `ValueError: Bad image dimensions: (991, 200). Expecting: (306, 991).` This change gets the height from the context instead. --- brother_ql_web.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/brother_ql_web.py b/brother_ql_web.py index dcdeaafb..9a4c1115 100755 --- a/brother_ql_web.py +++ b/brother_ql_web.py @@ -163,7 +163,7 @@ def create_label_grocy(text, **kwargs): product_font = ImageFont.truetype(kwargs['font_path'], 100) duedate_font = ImageFont.truetype(kwargs['font_path'], 60) width = kwargs['width'] - height = 200 + height = kwargs['height'] if kwargs['orientation'] == 'rotated': tw = width width = height