[Tutor] Frames and the grid manager

Klas Marteleur klas.martelleur at telia.com
Sat Aug 21 22:53:19 CEST 2004


Alan thanks for your reply

I now think i have a little clearer picture of how to design my GUI. But how 
do i actually put some of my controls in another frame?

If i would like for example to put my two push buttons in a separate frame, 
put that frame on row 3 column 2 in my master frame, 
and place my two buttons side by side in that frame using grid.
How would the code look like?

.....
        # Create convert button
        self.convertButton = Button(master, command = self.doProcessFiles)
        self.convertButton.configure(text="Convert")
        self.convertButton.grid(row=3,column=1,sticky=E)

        # Create exit button
        self.exitButton = Button(master, command = self.doExit)
        self.exitButton.configure(text="Exit")
        self.exitButton.grid(row=3,column=2,sticky=E)
......

Many thanks for your patience with me. i really start enjoying python. Good 
brain exercice :)

Klas


More information about the Tutor mailing list