You are reading an old version of the documentation (v3.1.3). For the latest version see https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.get_window_extent.html
Version 3.1.3
matplotlib
Fork me on GitHub

matplotlib.axes.Axes.get_window_extent

Axes.get_window_extent(self, *args, **kwargs)

Return the axes bounding box in display space; args and kwargs are empty.

This bounding box does not include the spines, ticks, ticklables, or other labels. For a bounding box including these elements use get_tightbbox.

See also

matplotlib.axes.Axes.get_tightbbox
matplotlib.axis.Axis.get_tightbbox
matplotlib.spines.get_window_extent