Closed mwcraig closed 2 years ago
The custom scatter plot and the game of life example fail because the canvas has no attribute size.
E.g. for the game of life example:
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) Input In [8], in <cell line: 50>() 48 canvas.fill_style = '#FFF0C9' 49 canvas.stroke_style = 'white' ---> 50 canvas.fill_rect(0, 0, canvas.size[0], canvas.size[1]) 52 draw(x, canvas, '#5770B3') 54 display(canvas) AttributeError: 'RoughCanvas' object has no attribute 'size'
Mmmh this is due to the removal of this property in latest ipycanvas versions. The proper change should be canvas.fill_rect(0, 0, canvas.width, canvas.height). I can send a PR.
canvas.fill_rect(0, 0, canvas.width, canvas.height)
Thanks!
The custom scatter plot and the game of life example fail because the canvas has no attribute size.
E.g. for the game of life example: