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