Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4da460e

Browse files
committed
DOC: toolkits [ci doc]
1 parent da9a8a3 commit 4da460e

File tree

10 files changed

+105
-89
lines changed

10 files changed

+105
-89
lines changed

doc/api/toolkits/mplot3d.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ and feel as regular 2D plots. Not the fastest or most feature complete 3D
1212
library out there, but it ships with Matplotlib and thus may be a lighter
1313
weight solution for some use cases.
1414

15-
See the :doc:`mplot3d tutorial </tutorials/toolkits/mplot3d>` for
15+
See the :ref:`mplot3d tutorial <mplot3d>` for
1616
more information.
1717

1818
.. image:: /_static/demo_mplot3d.png

doc/users/prev_whats_new/whats_new_0.99.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ Reinier Heeres has ported John Porter's mplot3d over to the new
2626
matplotlib transformations framework, and it is now available as a
2727
toolkit mpl_toolkits.mplot3d (which now comes standard with all mpl
2828
installs). See :ref:`mplot3d-examples-index` and
29-
:doc:`/tutorials/toolkits/mplot3d`.
29+
:ref:`mplot3d`.
3030

3131
.. plot::
3232

doc/users/prev_whats_new/whats_new_1.1.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ as 2D plotting, Ben Root has made several improvements to the
133133
improved to bring the class towards feature-parity with regular
134134
Axes objects
135135

136-
* Documentation for :doc:`/tutorials/toolkits/mplot3d` was significantly expanded
136+
* Documentation for :ref:`mplot3d` was significantly expanded
137137

138138
* Axis labels and orientation improved
139139

galleries/examples/axes_grid1/simple_axes_divider1.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Simple Axes Divider 1
44
=====================
55
6-
See also :doc:`/tutorials/toolkits/axes_grid`.
6+
See also :ref:`axes_grid`.
77
"""
88

99
import matplotlib.pyplot as plt

galleries/examples/axes_grid1/simple_axes_divider3.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Simple axes divider 3
44
=====================
55
6-
See also :doc:`/tutorials/toolkits/axes_grid`.
6+
See also :ref:`axes_grid`.
77
"""
88

99
import matplotlib.pyplot as plt

galleries/users_explain/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,4 @@ Using Matplotlib
1717
colors/index
1818
text/index
1919
animations/index
20+
toolkits/index

galleries/tutorials/toolkits/README.txt renamed to galleries/users_explain/toolkits/README.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
.. _tutorials-toolkits:
22

3+
.. redirect-from:: /tutorials/toolkits
4+
35
Toolkits
46
--------
57

galleries/tutorials/toolkits/axes_grid.py renamed to galleries/users_explain/toolkits/axes_grid.py

Lines changed: 33 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
r"""
2+
.. redirect-from:: /tutorials/toolkits/axes_grid
3+
24
.. _axes_grid1_users-guide-index:
5+
.. _axes_grid:
36
47
======================
58
The axes_grid1 toolkit
@@ -16,8 +19,8 @@
1619
- AnchoredArtists_ (custom artists which are placed at an anchored position,
1720
similarly to legends).
1821
19-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_demo_axes_grid_001.png
20-
:target: ../../gallery/axes_grid1/demo_axes_grid.html
22+
.. figure:: /gallery/axes_grid1/images/sphx_glr_demo_axes_grid_001.png
23+
:target: /gallery/axes_grid1/demo_axes_grid.html
2124
:align: center
2225
2326
axes_grid1
@@ -32,8 +35,8 @@
3235
`~.axes_grid1.axes_grid.ImageGrid` can be used to achieve such a padding; see
3336
its docs for detailed API information.
3437
35-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axesgrid_001.png
36-
:target: ../../gallery/axes_grid1/simple_axesgrid.html
38+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_axesgrid_001.png
39+
:target: /gallery/axes_grid1/simple_axesgrid.html
3740
:align: center
3841
3942
* The position of each axes is determined at the drawing time (see
@@ -48,14 +51,14 @@
4851
the same row all have the same height. These widths and heights are scaled
4952
in proportion to the axes' view limits (xlim or ylim).
5053
51-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axesgrid2_001.png
52-
:target: ../../gallery/axes_grid1/simple_axesgrid2.html
54+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_axesgrid2_001.png
55+
:target: /gallery/axes_grid1/simple_axesgrid2.html
5356
:align: center
5457
5558
The examples below show what you can do with ImageGrid.
5659
57-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_demo_axes_grid_001.png
58-
:target: ../../gallery/axes_grid1/demo_axes_grid.html
60+
.. figure:: /gallery/axes_grid1/images/sphx_glr_demo_axes_grid_001.png
61+
:target: /gallery/axes_grid1/demo_axes_grid.html
5962
:align: center
6063
6164
AxesDivider Class
@@ -79,8 +82,8 @@
7982
colorbar whose height (or width) is in sync with the main axes
8083
--------------------------------------------------------------
8184
82-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_colorbar_001.png
83-
:target: ../../gallery/axes_grid1/simple_colorbar.html
85+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_colorbar_001.png
86+
:target: /gallery/axes_grid1/simple_colorbar.html
8487
:align: center
8588
8689
scatter_hist.py with AxesDivider
@@ -106,8 +109,8 @@
106109
107110
See the full source code below.
108111
109-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_scatter_hist_locatable_axes_001.png
110-
:target: ../../gallery/axes_grid1/scatter_hist_locatable_axes.html
112+
.. figure:: /gallery/axes_grid1/images/sphx_glr_scatter_hist_locatable_axes_001.png
113+
:target: /gallery/axes_grid1/scatter_hist_locatable_axes.html
111114
:align: center
112115
113116
The :doc:`/gallery/axes_grid1/scatter_hist_locatable_axes` using the
@@ -141,8 +144,8 @@
141144
Example 1: twinx
142145
~~~~~~~~~~~~~~~~
143146
144-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_parasite_simple_001.png
145-
:target: ../../gallery/axes_grid1/parasite_simple.html
147+
.. figure:: /gallery/axes_grid1/images/sphx_glr_parasite_simple_001.png
148+
:target: /gallery/axes_grid1/parasite_simple.html
146149
:align: center
147150
148151
Example 2: twin
@@ -158,16 +161,16 @@
158161
labels=["0", r"$\frac{1}{2}\pi$",
159162
r"$\pi$", r"$\frac{3}{2}\pi$", r"$2\pi$"])
160163
161-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axisline4_001.png
162-
:target: ../../gallery/axes_grid1/simple_axisline4.html
164+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_axisline4_001.png
165+
:target: /gallery/axes_grid1/simple_axisline4.html
163166
:align: center
164167
165168
A more sophisticated example using twin. Note that if you change the
166169
x-limit in the host axes, the x-limit of the parasite axes will change
167170
accordingly.
168171
169-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_parasite_simple2_001.png
170-
:target: ../../gallery/axes_grid1/parasite_simple2.html
172+
.. figure:: /gallery/axes_grid1/images/sphx_glr_parasite_simple2_001.png
173+
:target: /gallery/axes_grid1/parasite_simple2.html
171174
:align: center
172175
173176
AnchoredArtists
@@ -179,8 +182,8 @@
179182
coordinates. There is limited support for arbitrary transforms. For example,
180183
the ellipse in the example below will have width and height in data coordinates.
181184
182-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_anchored_artists_001.png
183-
:target: ../../gallery/axes_grid1/simple_anchored_artists.html
185+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_anchored_artists_001.png
186+
:target: /gallery/axes_grid1/simple_anchored_artists.html
184187
:align: center
185188
186189
InsetLocator
@@ -214,15 +217,15 @@
214217
creates an inset axes whose data scale is half of the parent axes. This can be
215218
useful to mark the zoomed area on the parent axes:
216219
217-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_inset_locator_demo_001.png
218-
:target: ../../gallery/axes_grid1/inset_locator_demo.html
220+
.. figure:: /gallery/axes_grid1/images/sphx_glr_inset_locator_demo_001.png
221+
:target: /gallery/axes_grid1/inset_locator_demo.html
219222
:align: center
220223
221224
`.inset_locator.mark_inset` allows marking the location of the area represented
222225
by the inset axes:
223226
224-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_inset_locator_demo2_001.png
225-
:target: ../../gallery/axes_grid1/inset_locator_demo2.html
227+
.. figure:: /gallery/axes_grid1/images/sphx_glr_inset_locator_demo2_001.png
228+
:target: /gallery/axes_grid1/inset_locator_demo2.html
226229
:align: center
227230
228231
RGBAxes
@@ -240,8 +243,8 @@
240243
r, g, b = get_rgb() # r, g, b are 2D images.
241244
ax.imshow_rgb(r, g, b)
242245
243-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_demo_axes_rgb_001.png
244-
:target: ../../gallery/axes_grid1/demo_axes_rgb.html
246+
.. figure:: /gallery/axes_grid1/images/sphx_glr_demo_axes_rgb_001.png
247+
:target: /gallery/axes_grid1/demo_axes_rgb.html
245248
:align: center
246249
247250
AxesDivider
@@ -318,14 +321,14 @@
318321
319322
See the example,
320323
321-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axes_divider1_001.png
322-
:target: ../../gallery/axes_grid1/simple_axes_divider1.html
324+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_axes_divider1_001.png
325+
:target: /gallery/axes_grid1/simple_axes_divider1.html
323326
:align: center
324327
325328
You can also adjust the size of each axes according to its x or y
326329
data limits (AxesX and AxesY).
327330
328-
.. figure:: ../../gallery/axes_grid1/images/sphx_glr_simple_axes_divider3_001.png
329-
:target: ../../gallery/axes_grid1/simple_axes_divider3.html
331+
.. figure:: /gallery/axes_grid1/images/sphx_glr_simple_axes_divider3_001.png
332+
:target: /gallery/axes_grid1/simple_axes_divider3.html
330333
:align: center
331334
"""

galleries/tutorials/toolkits/axisartist.py renamed to galleries/users_explain/toolkits/axisartist.py

Lines changed: 33 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
r"""
2+
3+
.. redirect-from:: /tutorials/toolkits/axisartist
4+
5+
.. _axisartist:
6+
27
======================
38
The axisartist toolkit
49
======================
@@ -15,8 +20,8 @@
1520
artist (AxisArtist) that can handle ticks, ticklines, etc. for
1621
curved coordinate systems.
1722
18-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_floating_axis_001.png
19-
:target: ../../gallery/axisartist/demo_floating_axis.html
23+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_floating_axis_001.png
24+
:target: /gallery/axisartist/demo_floating_axis.html
2025
:align: center
2126
2227
Since it uses special artists, some Matplotlib commands that work on
@@ -60,17 +65,17 @@
6065
ax.axis["right"].set_visible(False)
6166
ax.axis["top"].set_visible(False)
6267
63-
.. figure:: ../../gallery/axisartist/images/sphx_glr_simple_axisline3_001.png
64-
:target: ../../gallery/axisartist/simple_axisline3.html
68+
.. figure:: /gallery/axisartist/images/sphx_glr_simple_axisline3_001.png
69+
:target: /gallery/axisartist/simple_axisline3.html
6570
:align: center
6671
6772
It is also possible to add a horizontal axis. For example, you may have an
6873
horizontal axis at y=0 (in data coordinate). ::
6974
7075
ax.axis["y=0"] = ax.new_floating_axis(nth_coord=0, value=0)
7176
72-
.. figure:: ../../gallery/axisartist/images/sphx_glr_simple_axisartist1_001.png
73-
:target: ../../gallery/axisartist/simple_axisartist1.html
77+
.. figure:: /gallery/axisartist/images/sphx_glr_simple_axisartist1_001.png
78+
:target: /gallery/axisartist/simple_axisartist1.html
7479
:align: center
7580
7681
Or a fixed axis with some offset ::
@@ -92,8 +97,8 @@
9297
9398
Here is an example that uses ParasiteAxes.
9499
95-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_parasite_axes2_001.png
96-
:target: ../../gallery/axisartist/demo_parasite_axes2.html
100+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_parasite_axes2_001.png
101+
:target: /gallery/axisartist/demo_parasite_axes2.html
97102
:align: center
98103
99104
Curvilinear Grid
@@ -102,8 +107,8 @@
102107
The motivation behind the AxisArtist module is to support a curvilinear grid
103108
and ticks.
104109
105-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_curvelinear_grid_001.png
106-
:target: ../../gallery/axisartist/demo_curvelinear_grid.html
110+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_curvelinear_grid_001.png
111+
:target: /gallery/axisartist/demo_curvelinear_grid.html
107112
:align: center
108113
109114
Floating Axes
@@ -112,8 +117,8 @@
112117
AxisArtist also supports a Floating Axes whose outer axes are defined as
113118
floating axis.
114119
115-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_floating_axes_001.png
116-
:target: ../../gallery/axisartist/demo_floating_axes.html
120+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_floating_axes_001.png
121+
:target: /gallery/axisartist/demo_floating_axes.html
117122
:align: center
118123
119124
axisartist namespace
@@ -144,8 +149,8 @@
144149
* a curvilinear grid.
145150
* a floating axis
146151
147-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_floating_axis_001.png
148-
:target: ../../gallery/axisartist/demo_floating_axis.html
152+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_floating_axis_001.png
153+
:target: /gallery/axisartist/demo_floating_axis.html
149154
:align: center
150155
151156
*mpl_toolkits.axisartist.Axes* class defines a *axis* attribute, which
@@ -305,8 +310,8 @@
305310
ax1.axis["left"].major_ticklabels.set_axis_direction("top")
306311
ax1.axis["right"].label.set_axis_direction("left")
307312
308-
.. figure:: ../../gallery/axisartist/images/sphx_glr_simple_axis_direction01_001.png
309-
:target: ../../gallery/axisartist/simple_axis_direction01.html
313+
.. figure:: /gallery/axisartist/images/sphx_glr_simple_axis_direction01_001.png
314+
:target: /gallery/axisartist/simple_axis_direction01.html
310315
:align: center
311316
312317
The parameter for set_axis_direction is one of ["left", "right",
@@ -330,8 +335,8 @@
330335
to the *ticklabel_direction* or *label_direction*,
331336
respectively. The rotation of ticklabels and label is anchored.
332337
333-
.. figure:: ../../gallery/axisartist/images/sphx_glr_axis_direction_001.png
334-
:target: ../../gallery/axisartist/axis_direction.html
338+
.. figure:: /gallery/axisartist/images/sphx_glr_axis_direction_001.png
339+
:target: /gallery/axisartist/axis_direction.html
335340
:align: center
336341
337342
On the other hand, there is a concept of "axis_direction". This is a
@@ -355,8 +360,8 @@
355360
etc, for settings suitable for "top" axis. The concept of axis
356361
direction can be more clear with curved axis.
357362
358-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_axis_direction_001.png
359-
:target: ../../gallery/axisartist/demo_axis_direction.html
363+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_axis_direction_001.png
364+
:target: /gallery/axisartist/demo_axis_direction.html
360365
:align: center
361366
362367
The axis_direction can be adjusted in the AxisArtist level, or in the
@@ -386,8 +391,8 @@
386391
387392
ax.axis[:].major_ticks.set_tick_out(True)
388393
389-
.. figure:: ../../gallery/axisartist/images/sphx_glr_simple_axis_direction03_001.png
390-
:target: ../../gallery/axisartist/simple_axis_direction03.html
394+
.. figure:: /gallery/axisartist/images/sphx_glr_simple_axis_direction03_001.png
395+
:target: /gallery/axisartist/simple_axis_direction03.html
391396
:align: center
392397
393398
So, in summary,
@@ -421,8 +426,8 @@
421426
422427
Alignment of TickLabels are treated specially. See below
423428
424-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_ticklabel_alignment_001.png
425-
:target: ../../gallery/axisartist/demo_ticklabel_alignment.html
429+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_ticklabel_alignment_001.png
430+
:target: /gallery/axisartist/demo_ticklabel_alignment.html
426431
:align: center
427432
428433
Adjusting pad
@@ -436,8 +441,8 @@
436441
437442
ax.axis["left"].label.set_pad(10)
438443
439-
.. figure:: ../../gallery/axisartist/images/sphx_glr_simple_axis_pad_001.png
440-
:target: ../../gallery/axisartist/simple_axis_pad.html
444+
.. figure:: /gallery/axisartist/images/sphx_glr_simple_axis_pad_001.png
445+
:target: /gallery/axisartist/simple_axis_pad.html
441446
:align: center
442447
443448
GridHelper
@@ -521,8 +526,8 @@ def inv_tr(x, y):
521526
# note that ax2.transData == tr + ax1.transData
522527
# Anything you draw in ax2 will match the ticks and grids of ax1.
523528
524-
.. figure:: ../../gallery/axisartist/images/sphx_glr_demo_curvelinear_grid_001.png
525-
:target: ../../gallery/axisartist/demo_curvelinear_grid.html
529+
.. figure:: /gallery/axisartist/images/sphx_glr_demo_curvelinear_grid_001.png
530+
:target: /gallery/axisartist/demo_curvelinear_grid.html
526531
:align: center
527532
528533
FloatingAxis

0 commit comments

Comments
 (0)