From 34fea4bea8688ce66b54161d413ca200a92ff9ad Mon Sep 17 00:00:00 2001 From: weckyy702 Date: Sat, 26 Dec 2020 17:54:50 +0100 Subject: [PATCH] actually fixed said error --- draw/code_to_image.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/draw/code_to_image.py b/draw/code_to_image.py index 8a76419..0c3857e 100644 --- a/draw/code_to_image.py +++ b/draw/code_to_image.py @@ -31,10 +31,6 @@ def draw_debug_tile(x, y, x_sz, y_sz): def draw_generic_instruction(instruction: str, x, y, xsize, ysize) -> Iterable[float]: if not output_img: raise Exception("Output image was not initialized! Make sure to call NSD_init first") - - #size shit - text_y_size = font.getsize(instruction, direction="ltr")[1] - ysize = max(text_y_size, ysize) # ensure the bounding box is alway at least big enought to fit the text #draw shit output_img.rectangle((x,y) + (x + xsize, y + ysize), outline=(0), width=1)