Commit 929bffb
committed
Don't draw axis (spines, ticks, labels) twice when using parasite axes.
We can just defer to the superclass' draw (axes._base.Axes.draw)
which will correctly draw everything in get_children();
axislines.Axes.get_children already adds the axislines and gridlines to
the superclass' get_children().
Likewise, get_tightbbox() doesn't need to be overridden because the
superclass' get_tightbbox by default uses
get_default_bbox_extra_artists, which fetches all visible children.
(This point is not needed for the bugfix, but we may as well...)
Don't bother using remove_text in the new figures, because that doesn't
remove the labels anyways (and the tests are also about label placement).1 parent 4769f7b commit 929bffb
10 files changed
Lines changed: 11 additions & 26 deletions
File tree
- doc/users
- next_whats_new
- lib/mpl_toolkits
- axisartist
- tests/baseline_images
- test_axisartist_axislines
- test_axisartist_floating_axes
- test_axisartist_grid_helper_curvelinear
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 18 | + | |
22 | 19 | | |
23 | | - | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
651 | 651 | | |
652 | 652 | | |
653 | 653 | | |
654 | | - | |
655 | 654 | | |
656 | 655 | | |
657 | 656 | | |
658 | 657 | | |
659 | 658 | | |
660 | 659 | | |
661 | 660 | | |
662 | | - | |
663 | | - | |
664 | | - | |
665 | | - | |
666 | | - | |
667 | | - | |
668 | | - | |
669 | | - | |
670 | | - | |
671 | | - | |
672 | | - | |
673 | | - | |
674 | | - | |
675 | | - | |
676 | | - | |
677 | | - | |
678 | | - | |
679 | | - | |
680 | | - | |
681 | | - | |
682 | 661 | | |
683 | 662 | | |
684 | 663 | | |
| |||
0 commit comments