move object dx units in x direction and dy units in y direction
(self, dx, dy)
| 482 | self.id = None |
| 483 | |
| 484 | def move(self, dx, dy): |
| 485 | |
| 486 | """move object dx units in x direction and dy units in y |
| 487 | direction""" |
| 488 | |
| 489 | self._move(dx,dy) |
| 490 | canvas = self.canvas |
| 491 | if canvas and not canvas.isClosed(): |
| 492 | trans = canvas.trans |
| 493 | if trans: |
| 494 | x = dx/ trans.xscale |
| 495 | y = -dy / trans.yscale |
| 496 | else: |
| 497 | x = dx |
| 498 | y = dy |
| 499 | #self.canvas.move(self.id, x, y) |
| 500 | _tkExec(self.canvas.move, self.id, x, y) |
| 501 | if canvas.autoflush: |
| 502 | #_root.update() |
| 503 | _tkCall(_root.update) |
| 504 | |
| 505 | def _reconfig(self, option, setting): |
| 506 | # Internal method for changing configuration of the object |