8000 Quiet sphinx warnings (by using matplotlib.axes.Axes instead of Axes … · matplotlib/matplotlib@f108e62 · GitHub
[go: up one dir, main page]

Skip to content

Commit f108e62

Browse files
committed
Quiet sphinx warnings (by using matplotlib.axes.Axes instead of Axes already in the namespace)
1 parent d832950 commit f108e62

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

lib/matplotlib/pyplot.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,7 +1089,7 @@ def figlegend(*args, **kwargs) -> Legend:
10891089
def axes(
10901090
arg: None | tuple[float, float, float, float] = None,
10911091
**kwargs
1092-
) -> Axes:
1092+
) -> matplotlib.axes.Axes:
10931093
"""
10941094
Add an Axes to the current figure and make it the current Axes.
10951095
@@ -1175,7 +1175,7 @@ def axes(
11751175
return fig.add_axes(arg, **kwargs)
11761176

11771177

1178-
def delaxes(ax: Axes | None = None) -> None:
1178+
def delaxes(ax: matplotlib.axes.Axes | None = None) -> None:
11791179
"""
11801180
Remove an `~.axes.Axes` (defaulting to the current axes) from its figure.
11811181
"""
@@ -1413,7 +1413,7 @@ def subplots(
14131413
subplot_kw: dict[str, Any] | None = None,
14141414
gridspec_kw: dict[str, Any] | None = None,
14151415
**fig_kw
1416-
) -> tuple[Figure, Axes | np.ndarray | SubplotBase]:
1416+
) -> tuple[Figure, matplotlib.axes.Axes | np.ndarray | SubplotBase]:
14171417
"""
14181418
Create a figure and a set of subplots.
14191419
@@ -1577,7 +1577,7 @@ def subplot_mosaic(
15771577
gridspec_kw: dict[str, Any] | None = None,
15781578
per_subplot_kw: dict[Any, dict[str, Any]] | None = None,
15791579
**fig_kw
1580-
) -> tuple[Figure, dict[Any, Axes]]:
1580+
) -> tuple[Figure, dict[Any, matplotlib.axes.Axes]]:
15811581
"""
15821582
Build a layout of Axes based on ASCII art or nested lists.
15831583
@@ -1694,7 +1694,7 @@ def subplot2grid(
16941694
rowspan: int = 1, colspan: int = 1,
16951695
fig: Figure | None = None,
16961696
**kwargs
1697-
) -> Axes:
1697+
) -> matplotlib.axes.Axes:
16981698
"""
16991699
Create a subplot at a specific location inside a regular grid.
17001700
@@ -1756,7 +1756,7 @@ def subplot2grid(
17561756
return ax
17571757

17581758

1759-
def twinx(ax: Axes | None = None) -> _AxesBase:
1759+
def twinx(ax: matplotlib.axes.Axes | None = None) -> _AxesBase:
17601760
"""
17611761
Make and return a second axes that shares the *x*-axis. The new axes will
17621762
overlay *ax* (or the current axes if *ax* is *None*), and its ticks will be
@@ -1772,7 +1772,7 @@ def twinx(ax: Axes | None = None) -> _AxesBase:
17721772
return ax1
17731773

17741774

1775-
def twiny(ax: Axes | None = None) -> _AxesBase:
1775+
def twiny(ax: matplotlib.axes.Axes | None = None) -> _AxesBase:
17761776
"""
17771777
Make and return a second axes that shares the *y*-axis. The new axes will
17781778
overlay *ax* (or the current axes if *ax* is *None*), and its ticks will be
@@ -2227,8 +2227,8 @@ def _get_pyplot_commands() -> list[str]:
22272227
@_copy_docstring_and_deprecators(Figure.colorbar)
22282228
def colorbar(
22292229
mappable: ScalarMappable | None = None,
2230-
cax: Axes | None = None,
2231-
ax: Axes | Iterable[Axes] | None = None,
2230+
cax: matplotlib.axes.Axes | None = None,
2231+
ax: matplotlib.axes.Axes | Iterable[matplotlib.axes.Axes] | None = None,
22322232
**kwargs
22332233
) -> Colorbar:
22342234
if mappable is None:

0 commit comments

Comments
 (0)
0