Skip to content

Commit 0fef3d0

Browse files
committed
DOC: Remove usage of discouraged layout engine API
Fixes #26637
1 parent 1ce35a9 commit 0fef3d0

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

galleries/examples/userdemo/connectionstyle_demo.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def demo_con_style(ax, connectionstyle):
4848

4949
for ax in axs.flat:
5050
ax.set(xlim=(0, 1), ylim=(0, 1.25), xticks=[], yticks=[], aspect=1.25)
51-
fig.set_constrained_layout_pads(wspace=0, hspace=0, w_pad=0, h_pad=0)
51+
fig.get_layout_engine().set(wspace=0, hspace=0, w_pad=0, h_pad=0)
5252

5353
plt.show()
5454

lib/matplotlib/figure.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2466,17 +2466,17 @@ def __init__(self,
24662466
to avoid overlapping axes decorations. Can handle complex plot
24672467
layouts and colorbars, and is thus recommended.
24682468
2469-
See :ref:`constrainedlayout_guide`
2470-
for examples.
2469+
See :ref:`constrainedlayout_guide` for examples.
24712470
24722471
- 'compressed': uses the same algorithm as 'constrained', but
24732472
removes extra space between fixed-aspect-ratio Axes. Best for
24742473
simple grids of axes.
24752474
24762475
- 'tight': Use the tight layout mechanism. This is a relatively
24772476
simple algorithm that adjusts the subplot parameters so that
2478-
decorations do not overlap. See `.set_tight_layout` for
2479-
further details.
2477+
decorations do not overlap.
2478+
2479+
See :ref:`tight_layout_guide` for examples.
24802480
24812481
- 'none': Do not use a layout engine.
24822482

0 commit comments

Comments
 (0)