VariablePanel.st
changeset 5821 fd8b7742fe2c
parent 5792 f76ee6c34669
child 5952 cee3905f1661
--- a/VariablePanel.st	Tue Aug 09 12:43:19 2016 +0200
+++ b/VariablePanel.st	Tue Aug 09 12:43:31 2016 +0200
@@ -1,5 +1,3 @@
-"{ Encoding: utf8 }"
-
 "
  COPYRIGHT (c) 1991 by Claus Gittinger
 	      All Rights Reserved
@@ -1954,7 +1952,7 @@
     <resource: #style (#'variablePanel.barHeight'
                        #'variablePanel.barHeightMM')>
 
-    |bH h lvl currentDeviceFont|
+    |bH h lvl|
 
     shadowForm notNil ifTrue:[
         bH := shadowForm height + 2.
@@ -1974,7 +1972,6 @@
     knobHeight := bH.
 
     handleLabels notNil ifTrue:[
-        currentDeviceFont := gc createFontOnDevice.
         bH := handleLabels inject:bH into:[:maxSoFar :thisLabel |
                                            thisLabel isNil ifTrue:[
                                                 maxSoFar
@@ -1982,7 +1979,7 @@
                                                 maxSoFar max:(thisLabel heightOn:self)
                                            ]
                                           ].
-        bH := bH + currentDeviceFont descent - 1
+        bH := bH + gc deviceFont descent - 1
     ].
 
     self barHeight:bH.