I need to catch the window-resize-event of my Tkinter-Toplevel-Window.
I've tried to do it the following way, but Python 1.5 refuses to let me
do it like that; however, neither in the Python- nor in the
Tk-documentation I've found the appropriate event to bind to. Can
anybody help me?
Thanks in advance, your's, Sven.
from Tkinter import *
class MyModule:
def __init__(self,master):
self.master=master
self.top = Toplevel(menu=self.menubar)
self.top.bind("<Resize>",self.resizeEvent)
...
def resizeEvent(self,event):
print "Toplevel has been resized"
--
--------------------------------------------------------------------------
Sven Havemann - Rosental 24 - 53111 Bonn - Deutschland -
0049/228/656860
Keywords: Polynomial Curves & Surfs, Generative Modeling, 4D
Animation
FG Computergraphik:
Institut f. Informatik III, Tel: (0228) 73-4391
Universitaet Bonn Fax: (0228) 73-4382
Roemerstr. 164, Mail: have...@graphics.cs.uni-bonn.de
D-53117 Bonn, Deutschland WWW:
http://hyperg.cs.uni-bonn.de/~havemann
--------------------------------------------------------------------------
That's the X window manager. If you're on Windows, you won't
find anything about this in the Windows User Guides ;-)
For a list of the most common (and portable) events and protocols, see
http://www.pythonware.com/library/tkinter/introduction/intro06.htm
Cheers /F (tkinter-info-bot)
PS. Don't y'all think that my tk-bot's more likely to survive the
turing test than tchrist's don't-you-dare-thinking-that-anything-
can-be-better-than-perl-bot? ;-)