From 901e8ae596f30348fda81a355502939e5695929f Mon Sep 17 00:00:00 2001 From: Luke Campagnola Date: Tue, 19 Nov 2013 14:45:57 -0500 Subject: [PATCH] Fixed unicode handling in AxisItem label --- pyqtgraph/graphicsItems/AxisItem.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyqtgraph/graphicsItems/AxisItem.py b/pyqtgraph/graphicsItems/AxisItem.py index 36516f8c..429ff49c 100644 --- a/pyqtgraph/graphicsItems/AxisItem.py +++ b/pyqtgraph/graphicsItems/AxisItem.py @@ -202,13 +202,13 @@ class AxisItem(GraphicsWidget): units = asUnicode('(x%g)') % (1.0/self.autoSIPrefixScale) else: #print repr(self.labelUnitPrefix), repr(self.labelUnits) - units = asUnicode('(%s%s)') % (self.labelUnitPrefix, self.labelUnits) + units = asUnicode('(%s%s)') % (asUnicode(self.labelUnitPrefix), asUnicode(self.labelUnits)) - s = asUnicode('%s %s') % (self.labelText, units) + s = asUnicode('%s %s') % (asUnicode(self.labelText), asUnicode(units)) style = ';'.join(['%s: %s' % (k, self.labelStyle[k]) for k in self.labelStyle]) - return asUnicode("%s") % (style, s) + return asUnicode("%s") % (style, asUnicode(s)) def _updateMaxTextSize(self, x): ## Informs that the maximum tick size orthogonal to the axis has