File tree 1 file changed +6
-2
lines changed
1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -1024,15 +1024,19 @@ def _reset_locator_formatter_scale(self):
1024
1024
self .__scale = 'linear'
1025
1025
self .ax .set_xscale ('linear' )
1026
1026
self .ax .set_yscale ('linear' )
1027
- elif hasattr (self .norm , '_scale' ) and (self .norm ._scale is not None ):
1027
+ elif hasattr (self .norm , '_scale' ) and self .norm ._scale is not None :
1028
+ # use the norm's scale:
1028
1029
self .ax .set_xscale (self .norm ._scale )
1029
1030
self .ax .set_yscale (self .norm ._scale )
1030
1031
self .__scale = self .norm ._scale .name
1031
1032
elif type (self .norm ) is colors .Normalize :
1032
- self . __scale = 'linear'
1033
+ # plain Normalize:
1033
1034
self .ax .set_xscale ('linear' )
1034
1035
self .ax .set_yscale ('linear' )
1036
+ self .__scale = 'linear'
1035
1037
else :
1038
+ # norm._scale is None or not an attr: derive the scale from
1039
+ # the Norm:
1036
1040
funcs = (self ._forward_from_norm , self ._inverse_from_norm )
1037
1041
self .ax .set_xscale ('function' , functions = funcs )
1038
1042
self .ax .set_yscale ('function' , functions = funcs )
You can’t perform that action at this time.
0 commit comments