1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3 %% Purpose: wxWizardPage and wxWizardPageSimple classes documentation
4 %% Author: Vadim Zeitlin
8 %% Copyright: (c) Vadim Zeitlin
9 %% License: wxWindows license
10 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
12 \section{\class{wxWizardPage
}}\label{wxwizardpage
}
14 wxWizardPage is one of the screens in
\helpref{wxWizard
}{wxwizard
}: it must
15 know what are the following and preceding pages (which may be
{\tt NULL
} for the
16 first/last page). Except for this extra knowledge, wxWizardPage is just a
17 panel, so the controls may be placed directly on it in the usual way.
19 This class allows to decide what is the orde fo pages in the wizard
20 dynamically (during run-time) and so providex maximal flexibility. Usually,
21 however, the order of pages is known in advance in which case
22 \helpref{wxWizardPageSimple
}{wxwizardpagesimple
} class is enough and it is simpler
25 \wxheading{Virtual functions to override
}
27 To use this class, you must override
\helpref{GetPrev
}{wxwizardpagegetprev
}
28 and
\helpref{GetNext
}{wxwizardpagegetnext
} pure virtual functions (or you
29 may use
\helpref{wxWizardPageSimple
}{wxwizardpagesimple
} instead).
31 \helpref{GetBitmap
}{wxwizardpagegetbitmap
} can also be overridden, but this
32 should be very rarely needed.
34 \wxheading{Derived from
}
36 \helpref{wxPanel
}{wxpanel
}\\
37 \helpref{wxWindow
}{wxwindow
}\\
38 \helpref{wxEvtHandler
}{wxevthandler
}\\
39 \helpref{wxObject
}{wxobject
}
41 \wxheading{Include files
}
47 \helpref{wxWizard
}{wxwizard
},
\helpref{wxWizard sample
}{samplewizard
}
49 \latexignore{\rtfignore{\wxheading{Members
}}}
51 \membersection{wxWizardPage::wxWizardPage
}\label{wxwizardpagewxwizardpage
}
53 \func{}{wxWizardPage
}{\param{wxWizard*
}{parent
},
\param{const wxBitmap\&
}{bitmap = wxNullBitmap
}}
55 Constructor accepts an optional bitmap which will be used for this page
56 instead of the default one for this wizard (note that all bitmaps used should
57 be of the same size). Notice that no other parameters are needed because the
58 wizard will resize and reposition the page anyhow.
60 \membersection{wxWizardPage::GetPrev
}\label{wxwizardpagegetprev
}
62 \constfunc{wxWizardPage*
}{GetPrev
}{\void}
64 Get the page which should be shown when the user chooses the
{\tt "Back"
}
65 button: if
{\tt NULL
} is returned, this button will be disabled. The first
66 page of the wizard will usually return
{\tt NULL
} from here, but the others
71 \helpref{GetNext
}{wxwizardpagegetnext
}
73 \membersection{wxWizardPage::GetNext
}\label{wxwizardpagegetnext
}
75 \constfunc{wxWizardPage*
}{GetNext
}{\void}
77 Get the page which should be shown when the user chooses the
{\tt "Next"
}
78 button: if
{\tt NULL
} is returned, this button will be disabled. The last
79 page of the wizard will usually return
{\tt NULL
} from here, but the others
84 \helpref{GetPrev
}{wxwizardpagegetprev
}
86 \membersection{wxWizardPage::GetBitmap
}\label{wxwizardpagegetbitmap
}
88 \constfunc{wxBitmap
}{GetBitmap
}{\void}
90 This method is called by wxWizard to get the bitmap to display alongside the
91 page. By default,
{\tt m
\_bitmap} member variable which was set in the
92 \helpref{constructor
}{wxwizardpagewxwizardpage
}.
94 If the bitmap was not explicitly set (i.e. if
{\tt wxNullBitmap
} is returned),
95 the default bitmap for the wizard should be used.
97 The only cases when you would want to override this function is if the page
98 bitmap depends dynamically on the user choices, i.e. almost never.
100 %%%%%%%%%%%%%%%%%%%%%%%%%%%%% wxWizardPageSimple %%%%%%%%%%%%%%%%%%%%%%%%%%%%
102 \section{\class{wxWizardPageSimple
}}\label{wxwizardpagesimple
}
104 wxWizardPageSimple is the simplest possible
105 \helpref{wxWizardPage
}{wxwizardpage
} implementation: it just returns the
106 pointers given to its constructor from GetNext() and GetPrev() functions.
108 This makes it very easy to use the obejcts of this class in the wizards where
109 the pages order is known statically - on the other hand, if this is not the
110 case you must derive your own class from
\helpref{wxWizardPage
}{wxwizardpage
}
113 \wxheading{Derived from
}
115 \helpref{wxWizardPage
}{wxwizardpage
}\\
116 \helpref{wxPanel
}{wxpanel
}\\
117 \helpref{wxWindow
}{wxwindow
}\\
118 \helpref{wxEvtHandler
}{wxevthandler
}\\
119 \helpref{wxObject
}{wxobject
}
121 \wxheading{Include files
}
127 \helpref{wxWizard
}{wxwizard
},
\helpref{wxWizard sample
}{samplewizard
}
129 \latexignore{\rtfignore{\wxheading{Members
}}}
131 \membersection{wxWizardPageSimple::wxWizardPageSimple
}\label{wxwizardpagesimplewxwizardpagesimple
}
133 \func{}{wxWizardPageSimple
}{\param{wxWizard*
}{parent = NULL
},
\param{wxWizardPage*
}{prev = NULL
},
\param{wxWizardPage*
}{next = NULL
}}
135 Constructor takes the previous and next pages. They may be modified later by
136 \helpref{SetPrev()
}{wxwizardpagesimplesetprev
} or
137 \helpref{SetNext()
}{wxwizardpagesimplesetnext
}.
139 \membersection{wxWizardPageSimple::SetPrev
}\label{wxwizardpagesimplesetprev
}
141 \func{void
}{SetPrev
}{\param{wxWizardPage*
}{prev
}}
143 Sets the previous page.
145 \membersection{wxWizardPageSimple::SetNext
}\label{wxwizardpagesimplesetnext
}
147 \func{void
}{SetNext
}{\param{wxWizardPage*
}{next
}}
151 \membersection{wxWizardPageSimple::Chain
}\label{wxwizardpagesimplechain
}
153 \func{static void
}{Chain
}{\param{wxWizardPageSimple*
}{first
},
\param{wxWizardPageSimple*
}{second
}}
155 A convenience function to make the pages follow each other.
159 wxRadioboxPage *page3 = new wxRadioboxPage(wizard);
160 wxValidationPage *page4 = new wxValidationPage(wizard);
162 wxWizardPageSimple::Chain(page3, page4);