Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

tk::splashscreen(3pm) [debian man page]

Splashscreen(3pm)					       perl/Tk Documentation						 Splashscreen(3pm)

NAME
Tk::Splashscreen - display a Splashscreen during program initialization. SYNOPSIS
$splash = $parent->Splashscreen(-opt => val, ... ); DESCRIPTION
For programs that require large load times, it's a common practice to display a Splashscreen that occupies the user's attention. This Toplevel mega widget provides all the display, destroy and timing events. All you do it create the Splashscreen mega widget, populate it as you see fit, then invoke Splash() to display it and Destroy() to tear it down. Important note: be sure to sprinkle update() calls throughout your initialization code so that any Splashscreen events are handled. Remem- ber, the screen may be animated, or the user may be simply moving the Splashscreen about. OPTIONS
The following option/value pairs are supported: -milliseconds The minimum number of milliseconds the Splashscreen should remain on the screen. Default is 0, which means that the Splashscreen is destroyed as soon as Destroy() is called. Otherwise, Destroy() waits for the specified time interval to elapse before destroying the Splashscreen. METHODS
$splash->Splash([milliseconds]); If milliseconds is specified, it's the minimum number of milliseconds the Splashscreen should remain on the screen. This value takes precedence over that specified on the Splashscreen constructor call. $splash->Destroy([milliseconds]); If milliseconds is specified, it's the minimum number of milliseconds the Splashscreen should remain on the screen. This value takes precedence over that specified on the Splash() call, which takes precedence over that specified during Splashscreen construction. BINDINGS
<ButtonPress-3> Notifies the Splashscreen to set a mark for an impending move. <ButtonRelease-3> Moves the Splashscreen from the mark to the cursor's current position. ADVERTISED WIDGETS
Component subwidgets can be accessed via the Subwidget method. This mega widget has no advertised subwidgets. Instead, treat the widget reference as a Toplevel and populate it as desired. EXAMPLE
$splash = $mw->Splashscreen; ... populate the Splashscreen toplevel as desired ... $splash->Splash(4000); ... program initialization ... $splash->Destroy; AUTHOR
Stephen.O.Lidie@Lehigh.EDU Copyright (C) 2001 - 2002, Steve Lidie. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. KEYWORDS
Splashscreen, Toplevel Tk1.0 2002-09-15 Splashscreen(3pm)

Check Out this Related Man Page

SplashFast(3)						User Contributed Perl Documentation					     SplashFast(3)

NAME
Wx::Perl::SplashFast - Fast splash screen for the Wx module. SYNOPSIS
use Wx::Perl::SplashFast ('/path/to/logo.jpg',3000); # timeout in milliseconds package myApp ; # subclass Wx::App ... package myFrame; # subclass Wx::Frame ... package main; my $myApp = myApp->new(); my $frame = myFrame->new(); $myApp->MainLoop(); DESCRIPTION
Using Wx::SplashScreen from Wx::App::OnInit may cause a high delay before the splash screen is shown on low end machines. This module works around this limitation; you just need to follow the example. USAGE
Just put the code inside the 'BEGIN {}' of your main app, like: sub BEGIN { use Wx::Perl::SplashFast ; Wx::Perl::SplashFast->new("./logo.jpg",5000); } or load the module before any other: use Wx::Perl::SplashFast ("./logo.jpg",5000) ; use Wx ; ... import ( IMG_FILE, SPLASH_TIMEOUT ) IMG_FILE Path of the image file to show. SPLASH_TIMEOUT Timeout of the splash screen in milliseconds. If you "use Wx::Perl::SplashFast './logo.jpg', 1000;" this has the same affetc as. BEGIN { require Wx::Perl::SplashFast; Wx::Perl::SplashFast->new( './logo.jpg', 1000 ); } new ( IMG_FILE , SPLASH_TIMEOUT ) Show the splash screen. IMG_FILE Path of the image file to show. SPLASH_TIMEOUT Timeout of the splash screen in milliseconds. EXAMPLE
use Wx::Perl::SplashFast ("./logo.jpg",5000) ; # Don't forget to put your own image in the same path. Duh package myApp ; use base 'Wx::App'; sub OnInit { return(@_[0]) ;} package myFrame ; use base 'Wx::Frame'; use Wx qw( wxDEFAULT_FRAME_STYLE ); sub new { my $app = shift ; my( $frame ) = $app->SUPER::new( @_[0] , -1, 'wxPerl Test' , [0,0] , [400,300] ) ; return( $frame ) ; } package main ; use Wx ; my $myApp = myApp->new() ; print "window " ; my $win = myFrame->new() ; $win->Show(1) ; $myApp->SetTopWindow( $win ) ; $myApp->MainLoop(); SEE ALSO
Wx, <Wx:SplashScreen> AUTHOR
Graciliano M. P. <gm@virtuasites.com.br> Thanks to wxWidgets people and Mattia Barbon for wxPerl! :P COPYRIGHT
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.10.0 2007-06-18 SplashFast(3)
Man Page