|
9 | 9 | from matplotlib.backend_bases import ( |
10 | 10 | FigureCanvasBase, ToolContainerBase, |
11 | 11 | CloseEvent, KeyEvent, LocationEvent, MouseEvent, ResizeEvent) |
12 | | -from matplotlib.backend_tools import Cursors |
13 | 12 |
|
14 | 13 | try: |
15 | 14 | import gi |
|
39 | 38 |
|
40 | 39 | @_api.caching_module_getattr # module-level deprecations |
41 | 40 | class __getattr__: |
42 | | - @_api.deprecated("3.5", obj_type="") |
43 | | - @property |
44 | | - def cursord(self): |
45 | | - try: |
46 | | - new_cursor = functools.partial( |
47 | | - Gdk.Cursor.new_from_name, Gdk.Display.get_default()) |
48 | | - return { |
49 | | - Cursors.MOVE: new_cursor("move"), |
50 | | - Cursors.HAND: new_cursor("pointer"), |
51 | | - Cursors.POINTER: new_cursor("default"), |
52 | | - Cursors.SELECT_REGION: new_cursor("crosshair"), |
53 | | - Cursors.WAIT: new_cursor("wait"), |
54 | | - } |
55 | | - except TypeError: |
56 | | - return {} |
57 | | - |
58 | 41 | icon_filename = _api.deprecated("3.6", obj_type="")(property( |
59 | 42 | lambda self: |
60 | 43 | "matplotlib.png" if sys.platform == "win32" else "matplotlib.svg")) |
@@ -493,13 +476,6 @@ def trigger(self, *args, **kwargs): |
493 | 476 | self._make_classic_style_pseudo_toolbar()) |
494 | 477 |
|
495 | 478 |
|
496 | | -@_api.deprecated("3.5", alternative="ToolSetCursor") |
497 | | -class SetCursorGTK3(backend_tools.SetCursorBase): |
498 | | - def set_cursor(self, cursor): |
499 | | - NavigationToolbar2GTK3.set_cursor( |
500 | | - self._make_classic_style_pseudo_toolbar(), cursor) |
501 | | - |
502 | | - |
503 | 479 | @backend_tools._register_tool_class(FigureCanvasGTK3) |
504 | 480 | class HelpGTK3(backend_tools.ToolHelpBase): |
505 | 481 | def _normalize_shortcut(self, key): |
|
0 commit comments