Commit 716a35f
committed
Let Axes.clear iterate over Axises.
... so that the implementation also works for 3D. This means also
adding a sharez() method, which is copy-pasted from sharex()/sharey()
(note that it is resolves a slight inconsistency in the old
Axes3D.clear, which would previously not copy the z-autoscaleness status
of a z-shared axes).
Using Axis._set_lim in the loop also means that we need to pass auto
explicitly to it anyways (it is a required parameter), so we can get rid
of the set_autoscalex/y/z calls.
Also, note that Axis.clear() explicitly resets the scale to "linear", so
the extra `_set_scale("linear")` calls are unneeded.
Finally, remove the silencing of TypeErrors when setting limits in
clear(), which was added in 917de33 to handle initialization order
problems in Axes3D but which seem not needed anymore (and are rather
unsightly, as it's not immediately clear what we're really catching).1 parent 446de7b commit 716a35f
3 files changed
+29
-40
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1212 | 1212 | | |
1213 | 1213 | | |
1214 | 1214 | | |
1215 | | - | |
1216 | | - | |
1217 | | - | |
1218 | | - | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
1219 | 1218 | | |
1220 | 1219 | | |
1221 | 1220 | | |
1222 | 1221 | | |
1223 | 1222 | | |
1224 | 1223 | | |
1225 | | - | |
1226 | | - | |
1227 | | - | |
1228 | | - | |
1229 | | - | |
1230 | | - | |
1231 | | - | |
1232 | | - | |
1233 | | - | |
1234 | | - | |
1235 | | - | |
1236 | | - | |
1237 | | - | |
1238 | | - | |
1239 | | - | |
1240 | | - | |
1241 | | - | |
1242 | | - | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
1243 | 1231 | | |
1244 | 1232 | | |
1245 | 1233 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
689 | 689 | | |
690 | 690 | | |
691 | 691 | | |
692 | | - | |
693 | 692 | | |
694 | 693 | | |
695 | 694 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
933 | 933 | | |
934 | 934 | | |
935 | 935 | | |
| 936 | + | |
| 937 | + | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
| 947 | + | |
| 948 | + | |
| 949 | + | |
| 950 | + | |
| 951 | + | |
| 952 | + | |
| 953 | + | |
| 954 | + | |
936 | 955 | | |
937 | 956 | | |
938 | 957 | | |
939 | | - | |
940 | | - | |
941 | | - | |
942 | | - | |
943 | | - | |
944 | | - | |
945 | | - | |
946 | | - | |
947 | | - | |
948 | | - | |
949 | | - | |
950 | | - | |
951 | | - | |
952 | | - | |
953 | | - | |
954 | | - | |
955 | 958 | | |
956 | 959 | | |
957 | 960 | | |
958 | 961 | | |
959 | | - | |
960 | 962 | | |
961 | 963 | | |
962 | 964 | | |
| |||
0 commit comments