Re: main window in tkinter app

2005-07-20 Thread Christopher Subich
William Gill wrote: O.K. I tried from scratch, and the following snippet produces an infinite loop saying: File C:\Python24\lib\lib-tk\Tkinter.py, line 1647, in __getattr__ return getattr(self.tk, attr) If I comment out the __init__ method, I get the titled window, and print

Re: main window in tkinter app

2005-07-20 Thread William Gill
That does it!, thanks. Thinking about it, when I created a derived class with an __init__ method, I overrode the base class's init. It should have been intuitive that I needed to explicitly call baseclass.__init(self), it wasn't. It might have hit me if the fault was related to someting in

Re: main window in tkinter app

2005-07-20 Thread Christopher Subich
William Gill wrote: That does it!, thanks. Thinking about it, when I created a derived class with an __init__ method, I overrode the base class's init. It should have been intuitive that I needed to explicitly call baseclass.__init(self), it wasn't. It might have hit me if the fault

Re: main window in tkinter app

2005-07-19 Thread Eric Brunel
On Mon, 18 Jul 2005 16:57:51 GMT, William Gill [EMAIL PROTECTED] wrote: A short while ago someone posted that(unlike the examples) you should use Tk as the base for your main window in tkinter apps, not Frame. Thus : class MyMain(Frame): def __init__(self, master):

Re: main window in tkinter app

2005-07-19 Thread William Gill
I never ran into this problem. ... O.K. That, means I probably have something else wrong. I will need to start with a 'clean slate' instead of trying to modify existing code. It's getting to convoluted to follow anyway after all the cobbling I've done. If I get a repeat of the original

Re: main window in tkinter app

2005-07-19 Thread William Gill
O.K. I tried from scratch, and the following snippet produces an infinite loop saying: File C:\Python24\lib\lib-tk\Tkinter.py, line 1647, in __getattr__ return getattr(self.tk, attr) If I comment out the __init__ method, I get the titled window, and print out self.var ('1') import

Re: main window in tkinter app

2005-07-19 Thread William Gill
It also seems to operate the same with or without app.mainloop(). Is an explicit call to mainloop needed? William Gill wrote: O.K. I tried from scratch, and the following snippet produces an infinite loop saying: File C:\Python24\lib\lib-tk\Tkinter.py, line 1647, in __getattr__

main window in tkinter app

2005-07-18 Thread William Gill
A short while ago someone posted that(unlike the examples) you should use Tk as the base for your main window in tkinter apps, not Frame. Thus : class MyMain(Frame): def __init__(self, master): self.root = master self.master=master