File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -824,6 +824,12 @@ def _get_ticker_locator_formatter(self):
824824 b = self .norm .boundaries
825825 if locator is None :
826826 locator = ticker .FixedLocator (b , nbins = 10 )
827+ elif isinstance (self .norm , colors .NoNorm ):
828+ if locator is None :
829+ # put ticks on integers between the boundaries of NoNorm
830+ nv = len (self ._values )
831+ base = 1 + int (nv / 10 )
832+ locator = ticker .IndexLocator (base = base , offset = .5 )
827833 elif self .boundaries is not None :
828834 b = self ._boundaries [self ._inside ]
829835 if locator is None :
@@ -835,12 +841,6 @@ def _get_ticker_locator_formatter(self):
835841 locator = self ._long_axis ().get_major_locator ()
836842 if minorlocator is None :
837843 minorlocator = self ._long_axis ().get_minor_locator ()
838- if isinstance (self .norm , colors .NoNorm ):
839- # default locator:
840- nv = len (self ._values )
841- base = 1 + int (nv / 10 )
842- # put ticks on integers between the boundaries of NoNorm...
843- locator = ticker .IndexLocator (base = base , offset = .5 )
844844
845845 if minorlocator is None :
846846 minorlocator = ticker .NullLocator ()
You can’t perform that action at this time.
0 commit comments