@@ -16,7 +16,7 @@ from matplotlib.font_manager import FontProperties
1616from matplotlib .path import Path
1717from matplotlib .texmanager import TexManager
1818from matplotlib .text import Text
19- from matplotlib .transforms import Transform , TransformedPath , Bbox
19+ from matplotlib .transforms import Bbox , BboxBase , Transform , TransformedPath
2020
2121from collections .abc import Callable , Iterable , Sequence
2222from typing import Any , IO , Literal , NamedTuple , TypeVar
@@ -168,7 +168,7 @@ class GraphicsContextBase:
168168 def set_url (self , url : str | None ) -> None : ...
169169 def set_gid (self , id : int | None ) -> None : ...
170170 def set_snap (self , snap : bool | None ) -> None : ...
171- def set_hatch (self , hatch : str ) -> None : ...
171+ def set_hatch (self , hatch : str | None ) -> None : ...
172172 def get_hatch (self ) -> str | None : ...
173173 def get_hatch_path (self , density : float = ...) -> Path : ...
174174 def get_hatch_color (self ) -> ColorType : ...
@@ -323,7 +323,7 @@ class FigureCanvasBase:
323323 @classmethod
324324 def new_manager (cls , figure : Figure , num : int | str ): ...
325325 def is_saving (self ) -> bool : ...
326- def blit (self , bbox : Bbox | None = ...) -> None : ...
326+ def blit (self , bbox : BboxBase | None = ...) -> None : ...
327327 def inaxes (self , xy : tuple [float , float ]) -> Axes | None : ...
328328 def grab_mouse (self , ax : Axes ) -> None : ...
329329 def release_mouse (self , ax : Axes ) -> None : ...
@@ -386,8 +386,8 @@ class FigureManagerBase:
386386 num : int | str
387387 key_press_handler_id : int | None
388388 button_press_handler_id : int | None
389- toolmanager : ToolManager
390- toolbar : NavigationToolbar2
389+ toolmanager : ToolManager | None
390+ toolbar : NavigationToolbar2 | ToolContainerBase | None
391391 def __init__ (self , canvas : FigureCanvasBase , num : int | str ) -> None : ...
392392 @classmethod
393393 def create_with_canvas (
@@ -429,7 +429,7 @@ class NavigationToolbar2:
429429
430430 class _PanInfo (NamedTuple ):
431431 button : MouseButton
432- axes : Axes
432+ axes : list [ Axes ]
433433 cid : int
434434 def press_pan (self , event : Event ) -> None : ...
435435 def drag_pan (self , event : Event ) -> None : ...
@@ -439,7 +439,7 @@ class NavigationToolbar2:
439439 class _ZoomInfo (NamedTuple ):
440440 direction : Literal ["in" , "out" ]
441441 start_xy : tuple [float , float ]
442- axes : Axes
442+ axes : list [ Axes ]
443443 cid : int
444444 cbar : Colorbar
445445 def press_zoom (self , event : Event ) -> None : ...
0 commit comments