IconEditor/IconEditorWindow.py

changeset 414
8c91e942d2da
parent 96
9624a110667d
child 453
a81097a85889
equal deleted inserted replaced
413:3d82e6eb3516 414:8c91e942d2da
1175 Private slot to show the current cursor position. 1175 Private slot to show the current cursor position.
1176 1176
1177 @param x x-coordinate (integer) 1177 @param x x-coordinate (integer)
1178 @param y y-coordinate (integer) 1178 @param y y-coordinate (integer)
1179 """ 1179 """
1180 self.__sbPos.setText("%d, %d" % (x + 1, y + 1)) 1180 self.__sbPos.setText("{0:d}, {1:d}".format(x + 1, y + 1))
1181 1181
1182 def __updateSize(self, w, h): 1182 def __updateSize(self, w, h):
1183 """ 1183 """
1184 Private slot to show the current icon size. 1184 Private slot to show the current icon size.
1185 1185
1186 @param w width of the icon (integer) 1186 @param w width of the icon (integer)
1187 @param h height of the icon (integer) 1187 @param h height of the icon (integer)
1188 """ 1188 """
1189 self.__sbSize.setText("%d x %d" % (w, h)) 1189 self.__sbSize.setText("{0:d} x {1:d}".format(w, h))
1190 1190
1191 def __updateZoom(self): 1191 def __updateZoom(self):
1192 """ 1192 """
1193 Private slot to show the current zoom factor. 1193 Private slot to show the current zoom factor.
1194 """ 1194 """
1195 zoom = self.__editor.zoomFactor() 1195 zoom = self.__editor.zoomFactor()
1196 self.__sbZoom.setText("%d %%" % (zoom * 100, )) 1196 self.__sbZoom.setText("{0:d} %".format(zoom * 100))
1197 self.zoomOutAct.setEnabled(self.__editor.zoomFactor() > 1) 1197 self.zoomOutAct.setEnabled(self.__editor.zoomFactor() > 1)
1198 1198
1199 def __zoomIn(self): 1199 def __zoomIn(self):
1200 """ 1200 """
1201 Private slot called to handle the zoom in action. 1201 Private slot called to handle the zoom in action.

eric ide

mercurial