[Tutor] Tkinter idiosyncracies?
srilyk at gmail.com
Fri Jun 19 23:41:27 CEST 2009
I'm having some problems with Tkinter doing its own thing (or not) when I
try to time events.
import Tkinter as tk
root = tk.Tk()
lbl = tk.Label(text = "Click the button to see weirdness")
btn = tk.Button(text='Click me', command=funky)
I'd expect that upon clicking the button the text of the label would change
to 'Foo', then it would wait for 4 seconds, and then the text would change
to 'Bar'. It doesn't do this - instead, it waits for 4 seconds, and then the
text changes to foo, then bar, almost too fast to see. A similar thing
happens (or the exact same) if you replace funky with this definition:
Am I missing something essential here? Or is this a bug that nobody has
I appreciate any help!
To be considered stupid and to be told so is more painful than being called
gluttonous, mendacious, violent, lascivious, lazy, cowardly: every weakness,
every vice, has found its defenders, its rhetoric, its ennoblement and
exaltation, but stupidity hasn’t. - Primo Levi
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tutor