tkinter: call root.after from a thread?

Benjamin Rutt rutt at bmi.osu.edu
Thu Mar 17 09:26:20 EST 2005


Let's say we have

root = Tk()
... <layout gui, spawn thread etc....>
root.mainloop()

Is a safe to call the method root.after(...) from a separate thread?
(The registered callback updates the GUI).  I know you're supposed to
avoid calling methods such as pack(), etc. from a thread, but I was
wondering if calling root.after() would be safe?  I'm doing this in a
GUI without any problems, so far.  Thanks,
-- 
Benjamin Rutt



More information about the Python-list mailing list