We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f04bff0 commit 5c28e95Copy full SHA for 5c28e95
lib/matplotlib/ticker.py
@@ -846,7 +846,11 @@ def set_locs(self, locs):
846
vmin, vmax = self.axis.get_view_interval()
847
self.d = abs(vmax - vmin)
848
849
- if hasattr(self.axis.get_transform(), 'linthresh'):
+ if not hasattr(self.axis, 'get_transform'):
850
+ # This might be a colorbar dummy axis, do not attempt to get
851
+ # transform
852
+ numdec = 10
853
+ elif hasattr(self.axis.get_transform(), 'linthresh'):
854
t = self.axis.get_transform()
855
linthresh = t.linthresh
856
# Only compute the number of decades in the logarithmic part of the
0 commit comments