Resize the canvas the turtles are drawing on. Does not alter the drawing window.
(self, canvwidth=None, canvheight=None, bg=None)
| 771 | self.cv.coords(item, *newcoordlist) |
| 772 | |
| 773 | def _resize(self, canvwidth=None, canvheight=None, bg=None): |
| 774 | """Resize the canvas the turtles are drawing on. Does |
| 775 | not alter the drawing window. |
| 776 | """ |
| 777 | # needs amendment |
| 778 | if not isinstance(self.cv, ScrolledCanvas): |
| 779 | return self.canvwidth, self.canvheight |
| 780 | if canvwidth is canvheight is bg is None: |
| 781 | return self.cv.canvwidth, self.cv.canvheight |
| 782 | if canvwidth is not None: |
| 783 | self.canvwidth = canvwidth |
| 784 | if canvheight is not None: |
| 785 | self.canvheight = canvheight |
| 786 | self.cv.reset(canvwidth, canvheight, bg) |
| 787 | |
| 788 | def _window_size(self): |
| 789 | """ Return the width and height of the turtle window. |