.\" Automatically generated by Pod::Man 4.07 (Pod::Simple 3.32) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .if !\nF .nr F 0 .if \nF>0 \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} .\} .\" ======================================================================== .\" .IX Title "SplashFast 3pm" .TH SplashFast 3pm "2017-05-20" "perl v5.24.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Wx::Perl::SplashFast \- Fast splash screen for the Wx module. .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 2 \& use Wx::Perl::SplashFast (\*(Aq/path/to/logo.jpg\*(Aq,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(); .Ve .SH "DESCRIPTION" .IX Header "DESCRIPTION" Using Wx::SplashScreen from Wx::App::OnInit may cause a high delay before the splash screen is shown on low end machines. .PP This module works around this limitation; you just need to follow the example. .SH "USAGE" .IX Header "USAGE" Just put the code inside the '\s-1BEGIN\s0 {}' of your main app, like: .PP .Vb 4 \& sub BEGIN { \& use Wx::Perl::SplashFast ; \& Wx::Perl::SplashFast\->new("./logo.jpg",5000); \& } .Ve .PP or load the module before any other: .PP .Vb 3 \& use Wx::Perl::SplashFast ("./logo.jpg",5000) ; \& use Wx ; \& ... .Ve .SS "import ( \s-1IMG_FILE, SPLASH_TIMEOUT \s0)" .IX Subsection "import ( IMG_FILE, SPLASH_TIMEOUT )" .IP "\s-1IMG_FILE\s0" 10 .IX Item "IMG_FILE" Path of the image file to show. .IP "\s-1SPLASH_TIMEOUT\s0" 10 .IX Item "SPLASH_TIMEOUT" Timeout of the splash screen in milliseconds. .PP If you \f(CW\*(C`use Wx::Perl::SplashFast \*(Aq./logo.jpg\*(Aq, 1000;\*(C'\fR this has the same affetc as. .PP .Vb 4 \& BEGIN { \& require Wx::Perl::SplashFast; \& Wx::Perl::SplashFast\->new( \*(Aq./logo.jpg\*(Aq, 1000 ); \& } .Ve .SS "new ( \s-1IMG_FILE , SPLASH_TIMEOUT \s0)" .IX Subsection "new ( IMG_FILE , SPLASH_TIMEOUT )" Show the splash screen. .IP "\s-1IMG_FILE\s0" 10 .IX Item "IMG_FILE" Path of the image file to show. .IP "\s-1SPLASH_TIMEOUT\s0" 10 .IX Item "SPLASH_TIMEOUT" Timeout of the splash screen in milliseconds. .SH "EXAMPLE" .IX Header "EXAMPLE" .Vb 2 \& use Wx::Perl::SplashFast ("./logo.jpg",5000) ; \& # Don\*(Aqt forget to put your own image in the same path. Duh \& \& package myApp ; \& use base \*(AqWx::App\*(Aq; \& sub OnInit { return(@_[0]) ;} \& \& package myFrame ; \& use base \*(AqWx::Frame\*(Aq; \& use Wx qw( wxDEFAULT_FRAME_STYLE ); \& \& sub new { \& my $app = shift ; \& my( $frame ) = $app\->SUPER::new( @_[0] , \-1, \*(AqwxPerl Test\*(Aq , \& [0,0] , [400,300] ) ; \& return( $frame ) ; \& } \& \& package main ; \& use Wx ; \& \& my $myApp = myApp\->new() ; \& \& print "window\en" ; \& my $win = myFrame\->new() ; \& $win\->Show(1) ; \& \& $myApp\->SetTopWindow( $win ) ; \& $myApp\->MainLoop(); .Ve .SH "SEE ALSO" .IX Header "SEE ALSO" Wx, .SH "AUTHOR" .IX Header "AUTHOR" Graciliano M. P. Thanks to wxWidgets people and Mattia Barbon for wxPerl! :P .SH "COPYRIGHT" .IX Header "COPYRIGHT" This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.