8000 DOC: correctly specify return type of `figaspect` · matplotlib/matplotlib@74af1bb · GitHub
[go: up one dir, main page]

Skip to content

Commit 74af1bb

Browse files
DerWehWeh Andreas
authored and
Weh Andreas
committed
DOC: correctly specify return type of figaspect
1 parent 71f5cf3 commit 74af1bb

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

lib/matplotlib/figure.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3655,8 +3655,8 @@ def figaspect(arg):
36553655
36563656
Returns
36573657
-------
3658-
width, height : float
3659-
The figure size in inches.
3658+
size : (2,) array
3659+
The width and height of the figure in inches.
36603660
36613661
Notes
36623662
-----

lib/matplotlib/figure.pyi

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -418,4 +418,6 @@ class Figure(FigureBase):
418418
rect: tuple[float, float, float, float] | None = ...
419419
) -> None: ...
420420

421-
def figaspect(arg: float | ArrayLike) -> tuple[float, float]: ...
421+
def figaspect(
422+
arg: float | ArrayLike,
423+
) -> np.ndarray[tuple[Literal[2]], np.dtype[np.float64]]: ...

0 commit comments

Comments
 (0)
0