]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/panel.tex
wxProcess fixes (Detach() added), cleared/corrected wxExecute() documentation
[wxWidgets.git] / docs / latex / wx / panel.tex
CommitLineData
a660d684
KB
1\section{\class{wxPanel}}\label{wxpanel}
2
3A panel is a window on which controls are placed. It is usually placed within a frame.
4It contains minimal extra functionality over and above its parent class wxWindow; its main
5purpose is to be similar in appearance and functionality to a dialog, but with the flexibility of
6having any window as a parent.
7
8\wxheading{Derived from}
9
10\helpref{wxWindow}{wxwindow}\\
11\helpref{wxEvtHandler}{wxevthandler}\\
12\helpref{wxObject}{wxobject}
13
954b8ae6
JS
14\wxheading{Include files}
15
16<wx/panel.h>
17
a660d684
KB
18\wxheading{Window styles}
19
20There are no specific styles for this window.
21
22See also \helpref{window styles overview}{windowstyles}.
23
24\wxheading{Remarks}
25
26By default, a panel has the same colouring as a dialog.
27
28A panel may be loaded from a wxWindows resource file (extension {\tt wxr}).
29
30\wxheading{See also}
31
32\helpref{wxDialog}{wxdialog}
33
34\latexignore{\rtfignore{\wxheading{Members}}}
35
36\membersection{wxPanel::wxPanel}\label{wxpanelconstr}
37
38\func{}{wxPanel}{\void}
39
40Default constructor.
41
eaaa6a06 42\func{}{wxPanel}{\param{wxWindow* }{parent}, \param{wxWindowID }{id},\rtfsp
a660d684
KB
43\param{const wxPoint\& }{pos = wxDefaultPosition},\rtfsp
44\param{const wxSize\& }{size = wxDefaultSize},\rtfsp
eaaa6a06 45\param{long}{ style = wxTAB\_TRAVERSAL},\rtfsp
a660d684
KB
46\param{const wxString\& }{name = ``panel"}}
47
48Constructor.
49
50\wxheading{Parameters}
51
52\docparam{parent}{The parent window.}
53
54\docparam{id}{An identifier for the panel. A value of -1 is taken to mean a default.}
55
56\docparam{pos}{The panel position. A value of (-1, -1) indicates a default position, chosen by
57either the windowing system or wxWindows, depending on platform.}
58
59\docparam{size}{The panel size. A value of (-1, -1) indicates a default size, chosen by
60either the windowing system or wxWindows, depending on platform.}
61
62\docparam{style}{The window style. See \helpref{wxPanel}{wxpanel}.}
63
64\docparam{name}{Used to associate a name with the window,
65allowing the application user to set Motif resource values for
66individual dialog boxes.}
67
68\wxheading{See also}
69
70\helpref{wxPanel::Create}{wxpanelcreate}
71
72\membersection{wxPanel::\destruct{wxPanel}}
73
74\func{}{\destruct{wxPanel}}{\void}
75
76Destructor. Deletes any child windows before deleting the physical window.
77
78\membersection{wxPanel::Create}\label{wxpanelcreate}
79
eaaa6a06 80\func{bool}{Create}{\param{wxWindow* }{parent}, \param{wxWindowID }{id},\rtfsp
a660d684
KB
81\param{const wxPoint\& }{pos = wxDefaultPosition},\rtfsp
82\param{const wxSize\& }{size = wxDefaultSize},\rtfsp
eaaa6a06 83\param{long}{ style = wxTAB\_TRAVERSAL},\rtfsp
a660d684
KB
84\param{const wxString\& }{name = ``panel"}}
85
86Used for two-step panel construction. See \helpref{wxPanel::wxPanel}{wxpanelconstr}\rtfsp
87for details.
88
89\membersection{wxPanel::InitDialog}\label{wxpanelinitdialog}
90
91\func{void}{InitDialog}{\void}
92
93Sends an \helpref{wxWindow::OnInitDialog}{wxwindowoninitdialog} event, which
94in turn transfers data to the dialog via validators.
95
96\wxheading{See also}
97
98\helpref{wxWindow::OnInitDialog}{wxwindowoninitdialog}
99
100\membersection{wxPanel::OnSysColourChanged}\label{wxpanelonsyscolourchanged}
101
102\func{void}{OnSysColourChanged}{\param{wxSysColourChangedEvent\& }{event}}
103
104The default handler for wxEVT\_SYS\_COLOUR\_CHANGED.
105
106\wxheading{Parameters}
107
108\docparam{event}{The colour change event.}
109
110\wxheading{Remarks}
111
112Changes the panel's colour to conform to the current settings (Windows only).
113Add an event table entry for your panel class if you wish the behaviour
114to be different (such as keeping a user-defined
115background colour). If you do override this function, call \helpref{wxWindow::OnSysColourChanged}{wxwindowonsyscolourchanged} to
116propagate the notification to child windows and controls.
117
118\wxheading{See also}
119
120\helpref{wxSysColourChangedEvent}{wxsyscolourchangedevent}
121
122