Merge pull request #968 from ecejeff/unit-label-fix

Fix for AxisItem using old scale to create label
This commit is contained in:
Ogi Moore 2019-07-01 07:01:05 -07:00 committed by GitHub
commit 04114fa126
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -448,11 +448,11 @@ class AxisItem(GraphicsWidget):
if self.labelUnits == '' and prefix in ['k', 'm']: ## If we are not showing units, wait until 1e6 before scaling.
scale = 1.0
prefix = ''
self.autoSIPrefixScale = scale
self.setLabel(unitPrefix=prefix)
else:
scale = 1.0
self.autoSIPrefixScale = 1.0
self.autoSIPrefixScale = scale
self.picture = None
self.update()