From 33fd5b13e68ca766474c4f9aa04477c8b55ec9b9 Mon Sep 17 00:00:00 2001 From: Elliott Sales de Andrade Date: Fri, 20 Sep 2024 02:52:25 -0400 Subject: [PATCH] DOC: Mark subfigures as no longer provisional Fixes #25947 --- doc/users/next_whats_new/subfigures_change_order.rst | 6 ++++++ .../examples/subplots_axes_and_figures/subfigures.py | 3 --- lib/matplotlib/figure.py | 11 ++--------- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/doc/users/next_whats_new/subfigures_change_order.rst b/doc/users/next_whats_new/subfigures_change_order.rst index 49a018a3fd96..e059d71755bc 100644 --- a/doc/users/next_whats_new/subfigures_change_order.rst +++ b/doc/users/next_whats_new/subfigures_change_order.rst @@ -1,3 +1,9 @@ +Subfigures no longer provisional +-------------------------------- + +The API on `.Figure.subfigures` and `.SubFigure` are now considered stable. + + Subfigures are now added in row-major order ------------------------------------------- diff --git a/galleries/examples/subplots_axes_and_figures/subfigures.py b/galleries/examples/subplots_axes_and_figures/subfigures.py index 5060946b59b2..cbe62f57d6b1 100644 --- a/galleries/examples/subplots_axes_and_figures/subfigures.py +++ b/galleries/examples/subplots_axes_and_figures/subfigures.py @@ -13,9 +13,6 @@ `matplotlib.figure.Figure.subfigures` to make an array of subfigures. Note that subfigures can also have their own child subfigures. -.. note:: - The *subfigure* concept is new in v3.4, and the API is still provisional. - """ import matplotlib.pyplot as plt import numpy as np diff --git a/lib/matplotlib/figure.py b/lib/matplotlib/figure.py index 0d5a686de9d8..7664ee6ded86 100644 --- a/lib/matplotlib/figure.py +++ b/lib/matplotlib/figure.py @@ -6,9 +6,8 @@ Many methods are implemented in `FigureBase`. `SubFigure` - A logical figure inside a figure, usually added to a figure (or parent - `SubFigure`) with `Figure.add_subfigure` or `Figure.subfigures` methods - (provisional API v3.4). + A logical figure inside a figure, usually added to a figure (or parent `SubFigure`) + with `Figure.add_subfigure` or `Figure.subfigures` methods. Figures are typically created using pyplot methods `~.pyplot.figure`, `~.pyplot.subplots`, and `~.pyplot.subplot_mosaic`. @@ -1608,9 +1607,6 @@ def subfigures(self, nrows=1, ncols=1, squeeze=True, the same as a figure, but cannot print itself. See :doc:`/gallery/subplots_axes_and_figures/subfigures`. - .. note:: - The *subfigure* concept is new in v3.4, and the API is still provisional. - .. versionchanged:: 3.10 subfigures are now added in row-major order. @@ -2229,9 +2225,6 @@ class SubFigure(FigureBase): axsR = sfigs[1].subplots(2, 1) See :doc:`/gallery/subplots_axes_and_figures/subfigures` - - .. note:: - The *subfigure* concept is new in v3.4, and the API is still provisional. """ def __init__(self, parent, subplotspec, *,