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
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
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
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):
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
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
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__
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