Hey there,
I have a problem with the following code:
import canvas as cv
# creates canvas
w = 200
h = 500
cv.set_size(w, h)
# size of the image
img_w = 190
img_h = 490
cv.begin_updates()
# draws a white rectangle as the canvas background
cv.set_fill_color(1, 1, 1)
cv.fill_rect(0, 0, w, h)
# draws an image onto the canvas
cv.draw_image("image.png", 0, 0, img_w, img_h)
cv.end_updates()
Whenever is use the canvas.draw_image() function, my Pythonista crashes. This seems to be not because of the image that I‘m trying to draw, since I‘ve tried out other images and even an empty string as the 1. argument too. It didn‘t even give me an error, it just closed the program.
Am I just not using the function correctly or is there something else I need to add?
I would be really happy if someone could help me out.
