Toggle the pan/zoom tool. Pan with left button, zoom with right.
(self, *args)
| 3173 | return axes_to_trigger |
| 3174 | |
| 3175 | def pan(self, *args): |
| 3176 | """ |
| 3177 | Toggle the pan/zoom tool. |
| 3178 | |
| 3179 | Pan with left button, zoom with right. |
| 3180 | """ |
| 3181 | if not self.canvas.widgetlock.available(self): |
| 3182 | self.set_message("pan unavailable") |
| 3183 | return |
| 3184 | if self.mode == _Mode.PAN: |
| 3185 | self.mode = _Mode.NONE |
| 3186 | self.canvas.widgetlock.release(self) |
| 3187 | else: |
| 3188 | self.mode = _Mode.PAN |
| 3189 | self.canvas.widgetlock(self) |
| 3190 | |
| 3191 | _PanInfo = namedtuple("_PanInfo", "button axes cid") |
| 3192 |
no test coverage detected