mirror of
https://github.com/python/cpython.git
synced 2025-07-23 03:05:38 +00:00
Updated for Python 1.4
This commit is contained in:
parent
c30e95f4b0
commit
89cb67bb64
43 changed files with 731 additions and 961 deletions
|
@ -7,23 +7,20 @@ class Test(Frame):
|
|||
|
||||
def createWidgets(self):
|
||||
# a hello button
|
||||
self.QUIT = Button(self, {'text': 'QUIT',
|
||||
'fg': 'red',
|
||||
'command': self.quit})
|
||||
|
||||
self.QUIT.pack({'side': 'left', 'fill': 'both'})
|
||||
self.QUIT = Button(self, text='QUIT', foreground='red',
|
||||
command=self.quit)
|
||||
self.QUIT.pack(side=LEFT, fill=BOTH)
|
||||
|
||||
self.hi_there = Button(self, text='Hello',
|
||||
command=self.printit)
|
||||
self.hi_there.pack(side=LEFT)
|
||||
|
||||
self.hi_there = Button(self, {'text': 'Hello',
|
||||
'command' : self.printit})
|
||||
self.hi_there.pack({'side': 'left'})
|
||||
# note how Packer defaults to side=TOP
|
||||
|
||||
# note how Packer defaults to {'side': 'top'}
|
||||
|
||||
self.guy2 = Button(self, {'text': 'button 2'})
|
||||
self.guy2 = Button(self, text='button 2')
|
||||
self.guy2.pack()
|
||||
|
||||
self.guy3 = Button(self, {'text': 'button 3'})
|
||||
self.guy3 = Button(self, text='button 3')
|
||||
self.guy3.pack()
|
||||
|
||||
def __init__(self, master=None):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue