Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit d9742a4

Browse filesBrowse files
committed
DOC: add missing docs for change to Figure.set_size_inches
1 parent 5a895da commit d9742a4
Copy full SHA for d9742a4

File tree

Expand file treeCollapse file tree

2 files changed

+9
-6
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+9
-6
lines changed

‎doc/users/dflt_style_changes.rst

Copy file name to clipboardExpand all lines: doc/users/dflt_style_changes.rst
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,12 @@ or by setting::
256256

257257
In your :file:`matplotlibrc` file.
258258

259+
In addition, the ``forward`` kwarg to
260+
`~matplotlib.Figure.set_size_inches` now defaults to `True` to improve
261+
the interactive experience. Backend canvases that adjust the size of
262+
their bound `matplotlib.figure.Figure` must pass ``forward=False`` to
263+
avoid circular behavior. This default is not configurable.
264+
259265

260266
Plotting functions
261267
==================

‎lib/matplotlib/figure.py

Copy file name to clipboardExpand all lines: lib/matplotlib/figure.py
+3-6Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -682,15 +682,12 @@ def figimage(self, X,
682682
return im
683683

684684
def set_size_inches(self, w, h=None, forward=True):
685-
"""
686-
set_size_inches(w,h, forward=False)
687-
688-
Set the figure size in inches (1in == 2.54cm)
685+
"""Set the figure size in inches (1in == 2.54cm)
689686
690-
Usage::
687+
Usage ::
691688
692689
fig.set_size_inches(w,h) # OR
693-
fig.set_size_inches((w,h) )
690+
fig.set_size_inches((w,h))
694691
695692
optional kwarg *forward=True* will cause the canvas size to be
696693
automatically updated; e.g., you can resize the figure window

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.