[pywin32-checkins] pywin32/Pythonwin/pywin/Demos/app customprint.py, 1.3, 1.4
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2008-11-14 00:22:31
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/Demos/app In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv24802/Pythonwin/pywin/Demos/app Modified Files: customprint.py Log Message: Various modernizations to .py code via the py3k branch. Index: customprint.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/Demos/app/customprint.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** customprint.py 9 Aug 2008 16:46:40 -0000 1.3 --- customprint.py 14 Nov 2008 00:22:25 -0000 1.4 *************** *** 34,38 **** } self.pens = {} ! for name, color in self.colors.items(): self.pens[name] = win32ui.CreatePen(win32con.PS_SOLID, 5, color) --- 34,38 ---- } self.pens = {} ! for name, color in self.colors.iteritems(): self.pens[name] = win32ui.CreatePen(win32con.PS_SOLID, 5, color) *************** *** 49,53 **** x,y = self.size delta = 2 ! colors = self.colors.keys() colors.sort() colors = colors*2 --- 49,53 ---- x,y = self.size delta = 2 ! colors = list(self.colors.keys()) colors.sort() colors = colors*2 *************** *** 169,173 **** def OnInitDialog(self): self.magCtl = self.GetDlgItem(IDC_PRINT_MAG_EDIT) ! self.magCtl.SetWindowText(`self['mag']`) return dialog.PrintDialog.OnInitDialog(self) def OnOK(self): --- 169,173 ---- def OnInitDialog(self): self.magCtl = self.GetDlgItem(IDC_PRINT_MAG_EDIT) ! self.magCtl.SetWindowText(repr(self['mag'])) return dialog.PrintDialog.OnInitDialog(self) def OnOK(self): |