You could try passing the parent widget to the routine that creates the new Toplevel and then call $parentwidget->focus to give the parent widget focus. You could bind this method to when your new window takes focus.
In Mastering Perl/Tk, there's also the method $widget->focusForce, which allows you to "force a widget to have the focus even if the applicatuion isn't currently active" (p. 299, Mastering Perl/Tk).
In reply to Re: prevent auto-focus in Tk Toplevels
by Rich36
in thread prevent auto-focus in Tk Toplevels
by batkins
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |