]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/splash.h
Correctly document the library the classes belong to.
[wxWidgets.git] / interface / wx / splash.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: splash.h
e54c96f1 3// Purpose: interface of wxSplashScreen
23324ae1
FM
4// Author: wxWidgets team
5// RCS-ID: $Id$
526954c5 6// Licence: wxWindows licence
23324ae1
FM
7/////////////////////////////////////////////////////////////////////////////
8
c9db153a
RD
9#define wxSPLASH_CENTRE_ON_PARENT 0x01
10#define wxSPLASH_CENTRE_ON_SCREEN 0x02
11#define wxSPLASH_NO_CENTRE 0x00
12#define wxSPLASH_TIMEOUT 0x04
13#define wxSPLASH_NO_TIMEOUT 0x00
14
15
23324ae1
FM
16/**
17 @class wxSplashScreen
7c913512 18
23324ae1 19 wxSplashScreen shows a window with a thin border, displaying a bitmap
e725ba4f
FM
20 describing your application.
21
22 Show it in application initialisation, and then either explicitly destroy
23324ae1 23 it or let it time-out.
7c913512 24
23324ae1 25 Example usage:
7c913512 26
23324ae1 27 @code
e725ba4f 28 wxBitmap bitmap;
23324ae1
FM
29 if (bitmap.LoadFile("splash16.png", wxBITMAP_TYPE_PNG))
30 {
31 wxSplashScreen* splash = new wxSplashScreen(bitmap,
32 wxSPLASH_CENTRE_ON_SCREEN|wxSPLASH_TIMEOUT,
6bfc18d0 33 6000, NULL, -1, wxDefaultPosition, wxDefaultSize,
23324ae1
FM
34 wxBORDER_SIMPLE|wxSTAY_ON_TOP);
35 }
36 wxYield();
37 @endcode
7c913512 38
23324ae1
FM
39 @library{wxadv}
40 @category{managedwnd}
41*/
42class wxSplashScreen : public wxFrame
43{
44public:
45 /**
46 Construct the splash screen passing a bitmap, a style, a timeout, a window id,
e725ba4f
FM
47 optional position and size, and a window style.
48
4cc4bfaf 49 @a splashStyle is a bitlist of some of the following:
e725ba4f
FM
50 - wxSPLASH_CENTRE_ON_PARENT
51 - wxSPLASH_CENTRE_ON_SCREEN
52 - wxSPLASH_NO_CENTRE
53 - wxSPLASH_TIMEOUT
54 - wxSPLASH_NO_TIMEOUT
55
4cc4bfaf 56 @a milliseconds is the timeout in milliseconds.
23324ae1
FM
57 */
58 wxSplashScreen(const wxBitmap& bitmap, long splashStyle,
59 int milliseconds,
60 wxWindow* parent,
61 wxWindowID id,
62 const wxPoint& pos = wxDefaultPosition,
63 const wxSize& size = wxDefaultSize,
64 long style = wxBORDER_SIMPLE|wxFRAME_NO_TASKBAR|wxSTAY_ON_TOP);
65
66 /**
67 Destroys the splash screen.
68 */
adaaa686 69 virtual ~wxSplashScreen();
23324ae1
FM
70
71 /**
e725ba4f 72 Returns the splash style (see wxSplashScreen() for details).
23324ae1 73 */
328f5751 74 long GetSplashStyle() const;
23324ae1
FM
75
76 /**
77 Returns the window used to display the bitmap.
78 */
328f5751 79 wxSplashScreenWindow* GetSplashWindow() const;
23324ae1
FM
80
81 /**
82 Returns the timeout in milliseconds.
83 */
328f5751 84 int GetTimeout() const;
23324ae1
FM
85
86 /**
87 Reimplement this event handler if you want to set an application variable on
88 window destruction, for example.
89 */
90 void OnCloseWindow(wxCloseEvent& event);
91};
e54c96f1 92