From d9f0da5a7c8679095f2716fdc9cd6880855fc159 Mon Sep 17 00:00:00 2001 From: Jeffrey Nichols Date: Thu, 27 Jun 2019 14:45:37 -0400 Subject: [PATCH] Fix for AxisItem using old scale to create label --- pyqtgraph/graphicsItems/AxisItem.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyqtgraph/graphicsItems/AxisItem.py b/pyqtgraph/graphicsItems/AxisItem.py index b34052ae..3a92e2b1 100644 --- a/pyqtgraph/graphicsItems/AxisItem.py +++ b/pyqtgraph/graphicsItems/AxisItem.py @@ -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()