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

Method _set_cursor_cbk

lib/matplotlib/backend_tools.py:286–296  ·  view source on GitHub ↗
(self, event)

Source from the content-addressed store, hash-verified

284 self._set_cursor_cbk(event.canvasevent)
285
286 def _set_cursor_cbk(self, event):
287 if not event or not self.canvas:
288 return
289 if (self._current_tool and getattr(event, "inaxes", None)
290 and event.inaxes.get_navigate()):
291 if self._last_cursor != self._current_tool.cursor:
292 self.canvas.set_cursor(self._current_tool.cursor)
293 self._last_cursor = self._current_tool.cursor
294 elif self._last_cursor != self._default_cursor:
295 self.canvas.set_cursor(self._default_cursor)
296 self._last_cursor = self._default_cursor
297
298
299class ToolCursorPosition(ToolBase):

Callers 1

_tool_trigger_cbkMethod · 0.95

Calls 2

get_navigateMethod · 0.80
set_cursorMethod · 0.45

Tested by

no test coverage detected