@@ -10,7 +10,7 @@ Changes in 1.3.1
10
10
It is rare that we make an API change in a bugfix release, however,
11
11
for 1.3.1 since 1.3.0 the following change was made:
12
12
13
- - `text.Text.cached ` (used to cache font objects) has been made into a
13
+ - `` text.Text.cached ` ` (used to cache font objects) has been made into a
14
14
private variable. Among the obvious encapsulation benefit, this
15
15
removes this confusing-looking member from the documentation.
16
16
@@ -24,49 +24,52 @@ Code removal
24
24
* The following items that were deprecated in version 1.2 or earlier
25
25
have now been removed completely.
26
26
27
- - The Qt 3.x backends (`qt ` and `qtagg `) have been removed in
28
- favor of the Qt 4.x backends (`qt4 ` and `qt4agg `).
27
+ - The Qt 3.x backends (`` qt `` and `` qtagg ` `) have been removed in
28
+ favor of the Qt 4.x backends (`` qt4 `` and `` qt4agg ` `).
29
29
30
30
- The FltkAgg and Emf backends have been removed.
31
31
32
- - The `matplotlib.nxutils ` module has been removed. Use the
32
+ - The `` matplotlib.nxutils ` ` module has been removed. Use the
33
33
functionality on `matplotlib.path.Path.contains_point ` and
34
34
friends instead.
35
35
36
- - Instead of `axes.Axes.get_frame `, use `axes.Axes.patch `.
36
+ - Instead of `` axes.Axes.get_frame `` , use `. axes.Axes.patch `.
37
37
38
- - The following ` kwargs ` to the `legend ` function have been
39
- renamed:
38
+ - The following keyword arguments to the `~.axes.Axes. legend ` function have
39
+ been renamed:
40
40
41
- - ` pad ` -> ` borderpad `
42
- - ` labelsep ` -> ` labelspacing `
43
- - ` handlelen ` -> ` handlelength `
44
- - ` handletextsep ` -> ` handletextpad `
45
- - ` axespad ` -> ` borderaxespad `
41
+ - * pad * -> * borderpad *
42
+ - * labelsep * -> * labelspacing *
43
+ - * handlelen * -> * handlelength *
44
+ - * handletextsep * -> * handletextpad *
45
+ - * axespad * -> * borderaxespad *
46
46
47
47
Related to this, the following rcParams have been removed:
48
48
49
- - `legend.pad `, `legend.labelsep `, `legend.handlelen `,
50
- `legend.handletextsep ` and `legend.axespad `
49
+ - ``legend.pad ``,
50
+ - ``legend.labelsep ``,
51
+ - ``legend.handlelen ``,
52
+ - ``legend.handletextsep `` and
53
+ - ``legend.axespad ``
51
54
52
- - For the `hist ` function, instead of ` width ` , use ` rwidth `
55
+ - For the `~.axes.Axes. hist ` function, instead of * width * , use * rwidth *
53
56
(relative width).
54
57
55
- - On `patches.Circle `, the ` resolution ` kwarg has been removed.
58
+ - On `. patches.Circle `, the * resolution * keyword argument has been removed.
56
59
For a circle made up of line segments, use
57
- `patches.CirclePolygon `.
60
+ `. patches.CirclePolygon `.
58
61
59
62
- The printing functions in the Wx backend have been removed due
60
63
to the burden of keeping them up-to-date.
61
64
62
- - `mlab.liaupunov ` has been removed.
65
+ - `` mlab.liaupunov ` ` has been removed.
63
66
64
- - `mlab.save `, `mlab.load `, `pylab.save ` and `pylab.load ` have
67
+ - `` mlab.save `` , `` mlab.load `` , `` pylab.save `` and `` pylab.load ` ` have
65
68
been removed. We recommend using `numpy.savetxt ` and
66
69
`numpy.loadtxt ` instead.
67
70
68
- - `widgets.HorizontalSpanSelector ` has been removed. Use
69
- `widgets.SpanSelector ` instead.
71
+ - `` widgets.HorizontalSpanSelector ` ` has been removed. Use
72
+ `. widgets.SpanSelector ` instead.
70
73
71
74
Code deprecation
72
75
----------------
@@ -76,35 +79,33 @@ Code deprecation
76
79
77
80
* The top-level functions in `matplotlib.path ` that are implemented in
78
81
C++ were never meant to be public. Instead, users should use the
79
- Pythonic wrappers for them in the `path.Path ` and
80
- `collections.Collection ` classes. Use the following mapping to update
82
+ Pythonic wrappers for them in the `. path.Path ` and
83
+ `. collections.Collection ` classes. Use the following mapping to update
81
84
your code:
82
85
83
- - `point_in_path ` -> `path.Path.contains_point `
84
- - `get_path_extents ` -> `path.Path.get_extents `
85
- - `point_in_path_collection ` -> `collection .Collection.contains `
86
- - `path_in_path ` -> `path.Path.contains_path `
87
- - `path_intersects_path ` -> `path.Path.intersects_path `
88
- - `convert_path_to_polygons ` -> `path.Path.to_polygons `
89
- - `cleanup_path ` -> `path.Path.cleaned `
90
- - `points_in_path ` -> `path.Path.contains_points `
91
- - `clip_path_to_rect ` -> `path.Path.clip_to_bbox `
92
-
93
- * `matplotlib.colors.normalize ` and `matplotlib.colors.no_norm ` have
86
+ - `` point_in_path `` -> `. path.Path.contains_point `
87
+ - `` get_path_extents `` -> `. path.Path.get_extents `
88
+ - `` point_in_path_collection `` -> `.collections .Collection.contains `
89
+ - `` path_in_path `` -> `. path.Path.contains_path `
90
+ - `` path_intersects_path `` -> `. path.Path.intersects_path `
91
+ - `` convert_path_to_polygons `` -> `. path.Path.to_polygons `
92
+ - `` cleanup_path `` -> `. path.Path.cleaned `
93
+ - `` points_in_path `` -> `. path.Path.contains_points `
94
+ - `` clip_path_to_rect `` -> `. path.Path.clip_to_bbox `
95
+
96
+ * `` matplotlib.colors.normalize `` and `` matplotlib.colors.no_norm ` ` have
94
97
been deprecated in favour of `matplotlib.colors.Normalize ` and
95
98
`matplotlib.colors.NoNorm ` respectively.
96
99
97
- * The `ScalarMappable ` class' `set_colorbar ` is now
98
- deprecated. Instead, the
99
- :attr: `matplotlib.cm.ScalarMappable.colorbar ` attribute should be
100
- used. In previous Matplotlib versions this attribute was an
101
- undocumented tuple of ``(colorbar_instance, colorbar_axes) `` but is
102
- now just ``colorbar_instance ``. To get the colorbar axes it is
103
- possible to just use the
104
- :attr: `~matplotlib.colorbar.ColorbarBase.ax ` attribute on a colorbar
100
+ * The `.ScalarMappable ` class' ``set_colorbar `` method is now deprecated.
101
+ Instead, the :attr: `matplotlib.cm.ScalarMappable.colorbar ` attribute should
102
+ be used. In previous Matplotlib versions this attribute was an undocumented
103
+ tuple of ``(colorbar_instance, colorbar_axes) `` but is now just
104
+ ``colorbar_instance ``. To get the colorbar axes it is possible to just use
105
+ the :attr: `~matplotlib.colorbar.ColorbarBase.ax ` attribute on a colorbar
105
106
instance.
106
107
107
- * The `~ matplotlib.mpl ` module is now deprecated. Those who relied on this
108
+ * The `` matplotlib.mpl `` module is now deprecated. Those who relied on this
108
109
module should transition to simply using ``import matplotlib as mpl ``.
109
110
110
111
Code changes
@@ -131,9 +132,9 @@ Code changes
131
132
large ``linewidth ``. Previously, :class: `~matplotlib.patches.Patch ` used
132
133
``capstyle='projecting' ``.
133
134
134
- * `Path ` objects can now be marked as ` readonly ` by passing
135
- `readonly=True ` to its constructor. The built-in path singletons,
136
- obtained through `Path.unit* ` class methods return readonly paths.
135
+ * `. Path ` objects can now be marked as * readonly * by passing
136
+ `` readonly=True ` ` to its constructor. The built-in path singletons,
137
+ obtained through `` Path.unit* ` ` class methods return readonly paths.
137
138
If you have code that modified these, you will need to make a
138
139
deepcopy first, using either::
139
140
@@ -144,23 +145,23 @@ Code changes
144
145
145
146
path = Path.unit_circle().deepcopy()
146
147
147
- Deep copying a `Path ` always creates an editable (i.e. non-readonly)
148
- `Path `.
148
+ Deep copying a `. Path ` always creates an editable (i.e. non-readonly)
149
+ `. Path `.
149
150
150
151
* The list at ``Path.NUM_VERTICES `` was replaced by a dictionary mapping
151
152
Path codes to the number of expected vertices at
152
153
:attr: `~matplotlib.path.Path.NUM_VERTICES_FOR_CODE `.
153
154
154
- * To support XKCD style plots, the :func: ` matplotlib.path.cleanup_path `
155
+ * To support XKCD style plots, the `` matplotlib.path.cleanup_path ` `
155
156
method's signature was updated to require a sketch argument. Users of
156
- :func: ` matplotlib.path.cleanup_path ` are encouraged to use the new
157
+ `` matplotlib.path.cleanup_path ` ` are encouraged to use the new
157
158
:meth: `~matplotlib.path.Path.cleaned ` Path method.
158
159
159
160
* Data limits on a plot now start from a state of having "null"
160
161
limits, rather than limits in the range (0, 1). This has an effect
161
162
on artists that only control limits in one direction, such as
162
- `axvline ` and `axhline `, since their limits will not longer also
163
- include the range (0, 1). This fixes some problems where the
163
+ `.axes.Axes. axvline ` and `.axes.Axes. axhline `, since their limits will no
164
+ longer also include the range (0, 1). This fixes some problems where the
164
165
computed limits would be dependent on the order in which artists
165
166
were added to the axes.
166
167
@@ -174,7 +175,7 @@ Code changes
174
175
width ``.
175
176
176
177
* It is now possible to provide ``number of levels + 1 `` colors in the case of
177
- `extend='both' ` for contourf (or just ``number of levels `` colors for an
178
+ `` extend='both' ` ` for contourf (or just ``number of levels `` colors for an
178
179
extend value ``min `` or ``max ``) such that the resulting colormap's
179
180
``set_under `` and ``set_over `` are defined appropriately. Any other number
180
181
of colors will continue to behave as before (if more colors are provided
@@ -195,18 +196,18 @@ Code changes
195
196
raises :class: `NotImplementedError ` instead of :class: `OSError ` if the
196
197
:command: `ps ` command cannot be run.
197
198
198
- * The :func: ` matplotlib.cbook.check_output ` function has been moved to
199
- :func: ` matplotlib.compat.subprocess `.
199
+ * The `` matplotlib.cbook.check_output ` ` function has been moved to
200
+ `` matplotlib.compat.subprocess ` `.
200
201
201
202
Configuration and rcParams
202
203
--------------------------
203
204
204
- * On Linux, the user-specific `matplotlibrc ` configuration file is now
205
- located in `~/.config/matplotlib/matplotlibrc ` to conform to the
205
+ * On Linux, the user-specific :file: `matplotlibrc ` configuration file is now
206
+ located in :file: `~/.config/matplotlib/matplotlibrc ` to conform to the
206
207
`XDG Base Directory Specification
207
208
<https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html> `_.
208
209
209
- * The `font.* ` rcParams now affect only text objects created after the
210
+ * The `` font.* ` ` rcParams now affect only text objects created after the
210
211
rcParam has been set, and will not retroactively affect already
211
212
existing text objects. This brings their behavior in line with most
212
213
other rcParams.
0 commit comments