in reply to getting a Perl application to start as quick as possible
You probably need to intercept the window manager's close command..
#prevents mw from closing and iconifies instead $mw->protocol('WM_DELETE_WINDOW' => sub { $mw->iconify });
For sleep, maybe something like this
tksleep($mw, 100); sub tksleep { # Like sleep, but actually allows the display to be # updated, and takes milliseconds instead of seconds. my $mw = shift; my $ms = shift; my $flag = 0; $mw->after($ms, sub { $flag++ }); $mw->waitVariable(\$flag); }
|
|---|