diff --git a/lib/matplotlib/colorbar.py b/lib/matplotlib/colorbar.py index b8da91c05109..e7b81e433a66 100644 --- a/lib/matplotlib/colorbar.py +++ b/lib/matplotlib/colorbar.py @@ -260,10 +260,8 @@ def __call__(self, ax, renderer): offset = extendlen[0] / len # we need to reset the aspect ratio of the axes to account # of the extends... - if hasattr(ax, '_colorbar_info'): - aspect = ax._colorbar_info['aspect'] - else: - aspect = False + aspect = self._cbar.ax.get_box_aspect() + ax._colorbar_info['aspect'] = aspect # now shrink and/or offset to take into account the # extend tri/rectangles. if self._cbar.orientation == 'vertical':
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: