]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/splash.tex
Patches-1851591 ] dataview sample is crashing (under MSW)
[wxWidgets.git] / docs / latex / wx / splash.tex
CommitLineData
e3c10211
JS
1\section{\class{wxSplashScreen}}\label{wxsplashscreen}
2
3wxSplashScreen shows a window with a thin border, displaying a bitmap describing your
4application. Show it in application initialisation, and then either explicitly destroy
5it or let it time-out.
6
7Example usage:
8
9\begin{verbatim}
10 wxBitmap bitmap;
11 if (bitmap.LoadFile("splash16.png", wxBITMAP_TYPE_PNG))
12 {
13 wxSplashScreen* splash = new wxSplashScreen(bitmap,
14 wxSPLASH_CENTRE_ON_SCREEN|wxSPLASH_TIMEOUT,
15 6000, NULL, -1, wxDefaultPosition, wxDefaultSize,
0a42e3b6 16 wxBORDER_SIMPLE|wxSTAY_ON_TOP);
e3c10211
JS
17 }
18 wxYield();
19\end{verbatim}
479101ca 20
e3c10211
JS
21\wxheading{Derived from}
22
23\helpref{wxFrame}{wxframe}\\
7376079d 24\helpref{wxTopLevelWindow}{wxtoplevelwindow}\\
e3c10211
JS
25\helpref{wxWindow}{wxwindow}\\
26\helpref{wxEvtHandler}{wxevthandler}\\
27\helpref{wxObject}{wxobject}
28
29\wxheading{Include files}
30
31<wx/splash.h>
32
a7af285d
VZ
33\wxheading{Library}
34
35\helpref{wxAdv}{librarieslist}
36
e3c10211
JS
37\latexignore{\rtfignore{\wxheading{Members}}}
38
39\membersection{wxSplashScreen::wxSplashScreen}\label{wxsplashscreenwxsplashscreen}
40
0a42e3b6 41\func{}{wxSplashScreen}{\param{const wxBitmap\& }{bitmap}, \param{long }{splashStyle}, \param{int }{milliseconds}, \param{wxWindow* }{parent}, \param{wxWindowID }{id}, \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize}, \param{long }{style = wxBORDER\_SIMPLE|wxFRAME\_NO\_TASKBAR|wxSTAY\_ON\_TOP}}
e3c10211
JS
42
43Construct the splash screen passing a bitmap, a style, a timeout, a window id, optional position
44and size, and a window style.
45
46{\it splashStyle} is a bitlist of some of the following:
47
48\begin{itemize}\itemsep=0pt
49\item wxSPLASH\_CENTRE\_ON\_PARENT
50\item wxSPLASH\_CENTRE\_ON\_SCREEN
51\item wxSPLASH\_NO\_CENTRE
52\item wxSPLASH\_TIMEOUT
53\item wxSPLASH\_NO\_TIMEOUT
54\end{itemize}
55
56{\it milliseconds} is the timeout in milliseconds.
57
58\membersection{wxSplashScreen::\destruct{wxSplashScreen}}\label{wxsplashscreendtor}
59
60\func{}{\destruct{wxSplashScreen}}{\void}
61
62Destroys the splash screen.
63
64\membersection{wxSplashScreen::OnCloseWindow}\label{wxsplashscreenonclosewindow}
65
66\func{void}{OnCloseWindow}{\param{wxCloseEvent\& }{event}}
67
68Reimplement this event handler if you want to set an application variable on window destruction, for example.
69
70\membersection{wxSplashScreen::GetSplashStyle}\label{wxsplashscreengetsplashstyle}
71
72\constfunc{long}{GetSplashStyle}{\void}
73
74Returns the splash style (see \helpref{wxSplashScreen::wxSplashScreen}{wxsplashscreenwxsplashscreen} for
75details).
76
77\membersection{wxSplashScreen::GetSplashWindow}\label{wxsplashscreengetsplashwindow}
78
79\constfunc{wxSplashScreenWindow*}{GetSplashWindow}{\void}
80
81Returns the window used to display the bitmap.
82
83\membersection{wxSplashScreen::GetTimeout}\label{wxsplashscreengettimeout}
84
85\constfunc{int}{GetTimeout}{\void}
86
87Returns the timeout in milliseconds.
88