コード例 #1
0
ファイル: SetZoom.py プロジェクト: sannorozco/ControlBoard
 def controlChanged(self, info):
     
     # Check that the control that changed has the name were looking for:
     if info["name"] == self.controlName:
         
         # If there's a glyph window open
         w = CurrentGlyphWindow()
         if w:
             # Set the zoom scale of the window.
             # Scale the incoming "value" of the control to somewhere between 0.15% and 3000%
             scale = (info["value"] * 30) + 0.15
             w.setGlyphViewScale(scale)