File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
doc/api/next_api_changes/behavior Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ Axes used to make colorbar now wrapped
2+ ======================================
3+
4+ The axes used to place a colorbar is now wrapped by a new parent class
5+ (``ColorbarAxes ``). This affects calls like::
6+
7+ cb = fig.colorbar(im, cax=cax)
8+ cax.tick_params()
9+
10+ so that this will no longer affect the visible axes ticks. Rather call
11+ methods on the axes stored on the colorbar object::
12+
13+ cb = fig.colorbar(im, cax=cax)
14+ cb.ax.tick_params()
15+
16+ If necessary, the original axes can be accessed via::
17+
18+ assert cb.ax.parent_axes == cax
19+
20+ This change means that the parent axes (``cb.ax.parent_axes ``) handles the
21+ placement of the colorbar axes object, and its aspect ratio, but the child
22+ axes (``cb.ax ``) handles all the tick parameters, labelling, and holds the
23+ artists that make up the colorbar.
24+
25+ Colorbar lines no longer clipped
26+ ================================
27+
28+ If a colorbar has lines added to it (e.g. for contour lines), these will
29+ no longer be clipped. This is an improvement for lines on the edge of
30+ the colorbar, but could lead to lines off the colorbar if the limits of
31+ the colorbar are changed.
You can’t perform that action at this time.
0 commit comments