Skip to content

Commit 55fa822

Browse files
authored
Merge pull request #29080 from focardozom/main
Updates the `galleries/tutorials/artists.py` file in response to issue #28920
2 parents 61f4d50 + 2491181 commit 55fa822

File tree

1 file changed

+15
-19
lines changed

1 file changed

+15
-19
lines changed

galleries/tutorials/artists.py

+15-19
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
1212
There are three layers to the Matplotlib API.
1313
14-
* the :class:`matplotlib.backend_bases.FigureCanvas` is the area onto which
14+
* the :class:`!matplotlib.backend_bases.FigureCanvas` is the area onto which
1515
the figure is drawn
16-
* the :class:`matplotlib.backend_bases.Renderer` is the object which knows how
17-
to draw on the :class:`~matplotlib.backend_bases.FigureCanvas`
16+
* the :class:`!matplotlib.backend_bases.Renderer` is the object which knows how
17+
to draw on the :class:`!matplotlib.backend_bases.FigureCanvas`
1818
* and the :class:`matplotlib.artist.Artist` is the object that knows how to use
1919
a renderer to paint onto the canvas.
2020
21-
The :class:`~matplotlib.backend_bases.FigureCanvas` and
22-
:class:`~matplotlib.backend_bases.Renderer` handle all the details of
21+
The :class:`!matplotlib.backend_bases.FigureCanvas` and
22+
:class:`!matplotlib.backend_bases.Renderer` handle all the details of
2323
talking to user interface toolkits like `wxPython
2424
<https://www.wxpython.org>`_ or drawing languages like PostScript®, and
2525
the ``Artist`` handles all the high level constructs like representing
@@ -156,12 +156,10 @@ class in the Matplotlib API, and the one you will be working with most
156156
# (the standard white box with black edges in the typical Matplotlib
157157
# plot, has a ``Rectangle`` instance that determines the color,
158158
# transparency, and other properties of the Axes. These instances are
159-
# stored as member variables :attr:`Figure.patch
160-
# <matplotlib.figure.Figure.patch>` and :attr:`Axes.patch
161-
# <matplotlib.axes.Axes.patch>` ("Patch" is a name inherited from
162-
# MATLAB, and is a 2D "patch" of color on the figure, e.g., rectangles,
163-
# circles and polygons). Every Matplotlib ``Artist`` has the following
164-
# properties
159+
# stored as member variables :attr:`!Figure.patch` and :attr:`!Axes.patch`
160+
# ("Patch" is a name inherited from MATLAB, and is a 2D "patch"
161+
# of color on the figure, e.g., rectangles, circles and polygons).
162+
# Every Matplotlib ``Artist`` has the following properties
165163
#
166164
# ========== =================================================================
167165
# Property Description
@@ -284,7 +282,7 @@ class in the Matplotlib API, and the one you will be working with most
284282
# :class:`matplotlib.figure.Figure`, and it contains everything in the
285283
# figure. The background of the figure is a
286284
# :class:`~matplotlib.patches.Rectangle` which is stored in
287-
# :attr:`Figure.patch <matplotlib.figure.Figure.patch>`. As
285+
# :attr:`!Figure.patch`. As
288286
# you add subplots (:meth:`~matplotlib.figure.Figure.add_subplot`) and
289287
# Axes (:meth:`~matplotlib.figure.Figure.add_axes`) to the figure
290288
# these will be appended to the :attr:`Figure.axes
@@ -331,8 +329,7 @@ class in the Matplotlib API, and the one you will be working with most
331329
#
332330
# As with all ``Artist``\s, you can control this coordinate system by setting
333331
# the transform property. You can explicitly use "figure coordinates" by
334-
# setting the ``Artist`` transform to :attr:`fig.transFigure
335-
# <matplotlib.figure.Figure.transFigure>`:
332+
# setting the ``Artist`` transform to :attr:`!fig.transFigure`:
336333

337334
import matplotlib.lines as lines
338335

@@ -375,7 +372,7 @@ class in the Matplotlib API, and the one you will be working with most
375372
# customize the ``Artists`` it contains. Like the
376373
# :class:`~matplotlib.figure.Figure`, it contains a
377374
# :class:`~matplotlib.patches.Patch`
378-
# :attr:`~matplotlib.axes.Axes.patch` which is a
375+
# :attr:`!matplotlib.axes.Axes.patch` which is a
379376
# :class:`~matplotlib.patches.Rectangle` for Cartesian coordinates and a
380377
# :class:`~matplotlib.patches.Circle` for polar coordinates; this patch
381378
# determines the shape, background and border of the plotting region::
@@ -408,8 +405,7 @@ class in the Matplotlib API, and the one you will be working with most
408405
#
409406
# Similarly, methods that create patches, like
410407
# :meth:`~matplotlib.axes.Axes.bar` creates a list of rectangles, will
411-
# add the patches to the :attr:`Axes.patches
412-
# <matplotlib.axes.Axes.patches>` list:
408+
# add the patches to the :attr:`!Axes.patches` list:
413409
#
414410
# .. sourcecode:: ipython
415411
#
@@ -556,8 +552,8 @@ class in the Matplotlib API, and the one you will be working with most
556552
# important ``Artist`` containers: the :class:`~matplotlib.axis.XAxis`
557553
# and :class:`~matplotlib.axis.YAxis`, which handle the drawing of the
558554
# ticks and labels. These are stored as instance variables
559-
# :attr:`~matplotlib.axes.Axes.xaxis` and
560-
# :attr:`~matplotlib.axes.Axes.yaxis`. The ``XAxis`` and ``YAxis``
555+
# :attr:`!matplotlib.axes.Axes.xaxis` and
556+
# :attr:`!matplotlib.axes.Axes.yaxis`. The ``XAxis`` and ``YAxis``
561557
# containers will be detailed below, but note that the ``Axes`` contains
562558
# many helper methods which forward calls on to the
563559
# :class:`~matplotlib.axis.Axis` instances, so you often do not need to

0 commit comments

Comments
 (0)