Commit 668aa49
committed
Turn ContourSet into a standard Collection artist.
Keep (some) backcompat by making access to ContourSet.collection trigger
the self-replacement of the ContourSet by the old-style list of
PathCollections.
The baseline images are slighly shifted, but the new images actually
look more correct:
- contour_corner_mask_False the old implementation would white out some
extra L-shaped areas between masked regions (particularly visible in
the diff image).
- 3d/contour3d: The order of the "contours" on the panes is a bit
arbitrary, but note that previously on the left pane the white
(medium) contour was drawn first, then overlaid with the blue (low)
contour, then overlaid with the red (high) contour; the new image
draws the contours more consistently in the order blue/white/red.
- 3d/tricontour: The new draw order of the unfilled contours (on the left)
is clearly better, with the highest contour (light green) drawn above
the lower one (medium green).
Limitations:
- 3d contours used to rely on being able to set a different sort_zpos
for each contour level; this change gets rid of that. Per the above
it's not clear this is actually worse in practice...1 parent e26542a commit 668aa49Copy full SHA for 668aa49
File tree
Expand file treeCollapse file tree
19 files changed
+536
-379
lines changedOpen diff view settings
Filter options
- doc/api/next_api_changes/deprecations
- examples
- images_contours_and_fields
- misc
- lib
- matplotlib
- axes
- tests
- mpl_toolkits
- axisartist/tests
- mplot3d
- tests
Expand file treeCollapse file tree
19 files changed
+536
-379
lines changedOpen diff view settings
Collapse file
doc/api/next_api_changes/deprecations/25247-AL.rst
Copy file name to clipboard+9Lines changed: 9 additions & 0 deletions
- Display the source diff
- Display the rich diff
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
| 1 | + |
| 2 | + |
| 3 | + |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
Collapse file
examples/images_contours_and_fields/contour_demo.py
Copy file name to clipboardExpand all lines: examples/images_contours_and_fields/contour_demo.py+3-1Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
85 | 85 | |
86 | 86 | |
87 | 87 | |
88 | | - |
| 88 | + |
| 89 | + |
| 90 | + |
89 | 91 | |
90 | 92 | |
91 | 93 | |
|
Collapse file
examples/images_contours_and_fields/contour_image.py
Copy file name to clipboardExpand all lines: examples/images_contours_and_fields/contour_image.py+1-3Lines changed: 1 addition & 3 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
56 | 56 | |
57 | 57 | |
58 | 58 | |
59 | | - |
60 | | - |
61 | | - |
| 59 | + |
62 | 60 | |
63 | 61 | |
64 | 62 | |
|
Collapse file
examples/images_contours_and_fields/contours_in_optimization_demo.py
Copy file name to clipboardExpand all lines: examples/images_contours_and_fields/contours_in_optimization_demo.py+3-7Lines changed: 3 additions & 7 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
17 | 17 | |
18 | 18 | |
19 | 19 | |
20 | | - |
21 | 20 | |
22 | 21 | |
23 | 22 | |
| ||
48 | 47 | |
49 | 48 | |
50 | 49 | |
51 | | - |
52 | | - |
| 50 | + |
53 | 51 | |
54 | 52 | |
55 | | - |
56 | | - |
| 53 | + |
57 | 54 | |
58 | 55 | |
59 | | - |
60 | | - |
| 56 | + |
61 | 57 | |
62 | 58 | |
63 | 59 | |
|
Collapse file
examples/misc/patheffect_demo.py
Copy file name to clipboardExpand all lines: examples/misc/patheffect_demo.py+1-2Lines changed: 1 addition & 2 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
29 | 29 | |
30 | 30 | |
31 | 31 | |
32 | | - |
33 | | - |
| 32 | + |
34 | 33 | |
35 | 34 | |
36 | 35 | |
|
Collapse file
examples/misc/tickedstroke_demo.py
Copy file name to clipboardExpand all lines: examples/misc/tickedstroke_demo.py+3-6Lines changed: 3 additions & 6 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
89 | 89 | |
90 | 90 | |
91 | 91 | |
92 | | - |
93 | | - |
| 92 | + |
94 | 93 | |
95 | 94 | |
96 | | - |
97 | | - |
| 95 | + |
98 | 96 | |
99 | 97 | |
100 | | - |
101 | | - |
| 98 | + |
102 | 99 | |
103 | 100 | |
104 | 101 | |
|
Collapse file
lib/matplotlib/axes/_base.py
Copy file name to clipboardExpand all lines: lib/matplotlib/axes/_base.py+1-4Lines changed: 1 addition & 4 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
2179 | 2179 | |
2180 | 2180 | |
2181 | 2181 | |
2182 | | - |
2183 | | - |
2184 | | - |
2185 | | - |
| 2182 | + |
2186 | 2183 | |
2187 | 2184 | |
2188 | 2185 | |
|
Collapse file
+5-5Lines changed: 5 additions & 5 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
767 | 767 | |
768 | 768 | |
769 | 769 | |
770 | | - |
771 | | - |
| 770 | + |
| 771 | + |
772 | 772 | |
773 | 773 | |
774 | 774 | |
775 | 775 | |
776 | | - |
777 | | - |
778 | | - |
| 776 | + |
| 777 | + |
| 778 | + |
779 | 779 | |
780 | 780 | |
781 | 781 | |
|
0 commit comments