MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / zoom

Method zoom

lib/matplotlib/backend_bases.py:3239–3249  ·  view source on GitHub ↗
(self, *args)

Source from the content-addressed store, hash-verified

3237 self.push_current()
3238
3239 def zoom(self, *args):
3240 if not self.canvas.widgetlock.available(self):
3241 self.set_message("zoom unavailable")
3242 return
3243 """Toggle zoom to rect mode."""
3244 if self.mode == _Mode.ZOOM:
3245 self.mode = _Mode.NONE
3246 self.canvas.widgetlock.release(self)
3247 else:
3248 self.mode = _Mode.ZOOM
3249 self.canvas.widgetlock(self)
3250
3251 _ZoomInfo = namedtuple("_ZoomInfo", "button start_xy axes cid cbar")
3252

Callers 7

test_toolbar_zoom_panFunction · 0.95
test_interactive_zoomFunction · 0.95
test_widgetlock_zoompanFunction · 0.95
key_press_handlerFunction · 0.45

Calls 3

set_messageMethod · 0.95
availableMethod · 0.80
releaseMethod · 0.45

Tested by 6

test_toolbar_zoom_panFunction · 0.76
test_interactive_zoomFunction · 0.76
test_widgetlock_zoompanFunction · 0.76