On Sep 11, 9:14 am, Hendrik van Rooyen <hend...@microcorp.co.za> wrote: > On Thursday 10 September 2009 18:19:09 Joshua Bronson wrote: > > > True, but it'll still be a lot less painful for me to test my app if I > > can get it to steal focus > > when launched from the command line. If anyone knows how to do this in > > Tkinter, help would be much appreciated. > > look for widget.focus_force() > and look for widget.grab_set_global()
Doesn't work. BTW, forcing the focus or setting the grab globally are usually considered very annoying and I don't know any windowing system or window manager honouring those. For the OP: the problem comes from the tcl/tk level. Running a tcl script just opening a window from the terminal shows the same behaviour. You might want to forward the question to the tcl guys. -- http://mail.python.org/mailman/listinfo/python-list