source: python/trunk/Demo/tkinter/matt/not-what-you-might-think-2.py

Last change on this file was 2, checked in by Yuri Dario, 15 years ago

Initial import for vendor code.

  • Property svn:eol-style set to native
File size: 747 bytes
Line 
1from Tkinter import *
2
3
4class Test(Frame):
5 def createWidgets(self):
6
7 self.Gpanel = Frame(self, width='1i', height='1i',
8 background='green')
9
10 # this line turns off the recalculation of geometry by masters.
11 self.Gpanel.propagate(0)
12
13 self.Gpanel.pack(side=LEFT)
14
15 # a QUIT button
16 self.Gpanel.QUIT = Button(self.Gpanel, text='QUIT', foreground='red',
17 command=self.quit)
18 self.Gpanel.QUIT.pack(side=LEFT)
19
20 def __init__(self, master=None):
21 Frame.__init__(self, master)
22 Pack.config(self)
23 self.createWidgets()
24
25test = Test()
26
27test.master.title('packer demo')
28test.master.iconname('packer')
29
30test.mainloop()
Note: See TracBrowser for help on using the repository browser.