Re: [Tutor] trying to put Tkinter widget handlers in a module

2008-09-29 Thread Alan Gauld
"John Fouhy" <[EMAIL PROTECTED]> wrote To get around it, you need to supply your handlers with a reference to the Frame object. I guess you could try something like this: ### handlers.py ### def handleCheckButton(obj): def handler(): obj.doNotSend = obj.var.get() if obj.doNo

Re: [Tutor] trying to put Tkinter widget handlers in a module

2008-09-29 Thread Alan Gauld
<[EMAIL PROTECTED]> wrote I am writing a large Python/Tkinter/Pmw program. It has become so big that I would like to move some of the widget handlers to a module for import. The normal way to factor a GUI is by class. Move the entire class into a separate module. You cannot separate the me

Re: [Tutor] trying to put Tkinter widget handlers in a module

2008-09-28 Thread John Fouhy
2008/9/29 <[EMAIL PROTECTED]>: > I am writing a large Python/Tkinter/Pmw program. It has become so big that I > would like to move some of the widget handlers to a module for import. The > following small program illustrates: > > # --- begin code --- [...] >c = Checkbutton( >

[Tutor] trying to put Tkinter widget handlers in a module

2008-09-28 Thread dwbarne
I am writing a large Python/Tkinter/Pmw program. It has become so big that I would like to move some of the widget handlers to a module for import. The following small program illustrates: # --- begin code --- # checkbutton frame using python & Tkinter from Tkinter import * import string clas