Thank you for your help. Unfortunately this does not quite achieve what I want. For some (slightly frustrating) reason, execution of the program is halted while the splash screen is displayed (the screen does not appear until the call to destroy, which is a blocking call (see below)). I want the splash screen to display while initialization continues in the background.
Yarr!
#!/usr/bin/perl use strict; use warnings; use Tk; use Tk::Splashscreen; my $mw = MainWindow->new; $mw->Button( -text => 'Exit', -command => sub {exit} )->pack; my $sp = $mw->Splashscreen; $sp->Label(-text => 'Tk... Ick!', -font => [-size => 250])->pack; $sp->Splash; #nothing displayed yet sleep(10); # Still no splash screen $sp->Destroy(5000); # Now we see the splash screen # But execution of the program is on hold until # the screen goes away... Boo! MainLoop;
They say that time changes things, but you actually have to change them yourself.
Andy Warhol
In reply to Re^2: Problems with Tk::SplashScreen and Tk::Splash
by JediWizard
in thread Problems with Tk::SplashScreen and Tk::Splash
by JediWizard
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |