1QWizard(3qt)                                                      QWizard(3qt)
2
3
4

NAME

6       QWizard - Framework for wizard dialogs
7

SYNOPSIS

9       #include <qwizard.h>
10
11       Inherits QDialog.
12
13   Public Members
14       QWizard ( QWidget * parent = 0, const char * name = 0, bool modal =
15           FALSE, WFlags f = 0 )
16       ~QWizard ()
17       virtual void addPage ( QWidget * page, const QString & title )
18       virtual void insertPage ( QWidget * page, const QString & title, int
19           index )
20       virtual void removePage ( QWidget * page )
21       QString title ( QWidget * page ) const
22       void setTitle ( QWidget * page, const QString & title )
23       QFont titleFont () const
24       void setTitleFont ( const QFont & )
25       virtual void showPage ( QWidget * page )
26       QWidget * currentPage () const
27       QWidget * page ( int index ) const
28       int pageCount () const
29       int indexOf ( QWidget * page ) const
30       virtual bool appropriate ( QWidget * page ) const
31       virtual void setAppropriate ( QWidget * page, bool appropriate )
32       QPushButton * backButton () const
33       QPushButton * nextButton () const
34       QPushButton * finishButton () const
35       QPushButton * cancelButton () const
36       QPushButton * helpButton () const
37
38   Public Slots
39       virtual void setBackEnabled ( QWidget * page, bool enable )
40       virtual void setNextEnabled ( QWidget * page, bool enable )
41       virtual void setFinishEnabled ( QWidget * page, bool enable )
42       virtual void setHelpEnabled ( QWidget * page, bool enable )
43       virtual void setFinish ( QWidget *, bool )  (obsolete)
44
45   Signals
46       void helpClicked ()
47       void selected ( const QString & )
48
49   Properties
50       QFont titleFont - the font used for page titles
51
52   Protected Members
53       virtual void layOutButtonRow ( QHBoxLayout * layout )
54       virtual void layOutTitleRow ( QHBoxLayout * layout, const QString &
55           title )
56
57   Protected Slots
58       virtual void back ()
59       virtual void next ()
60       virtual void help ()
61

DESCRIPTION

63       The QWizard class provides a framework for wizard dialogs.
64
65       A wizard is a special type of input dialog that consists of a sequence
66       of dialog pages. A wizard's purpose is to walk the user through a
67       process step by step. Wizards are useful for complex or infrequently
68       occurring tasks that people may find difficult to learn or do.
69
70       QWizard provides page titles and displays Next, Back, Finish, Cancel,
71       and Help push buttons, as appropriate to the current position in the
72       page sequence. These buttons can be enabled/disabled using
73       setBackEnabled(), setNextEnabled(), setFinishEnabled() and
74       setHelpEnabled().
75
76       Create and populate dialog pages that inherit from QWidget and add them
77       to the wizard using addPage(). Use insertPage() to add a dialog page at
78       a certain position in the page sequence. Use removePage() to remove a
79       page from the page sequence.
80
81       Use currentPage() to retrieve a pointer to the currently displayed
82       page. page() returns a pointer to the page at a certain position in the
83       page sequence.
84
85       Use pageCount() to retrieve the total number of pages in the page
86       sequence. indexOf() will return the index of a page in the page
87       sequence.
88
89       QWizard provides functionality to mark pages as appropriate (or not) in
90       the current context with setAppropriate(). The idea is that a page may
91       be irrelevant and should be skipped depending on the data entered by
92       the user on a preceding page.
93
94       It is generally considered good design to provide a greater number of
95       simple pages with fewer choices rather than a smaller number of complex
96       pages.
97
98       Example code is available here: wizard/wizard.cpp wizard/wizard.h
99
100       <center>
101                                   [Image Omitted]
102
103       </center> <blockquote><p align="center"> A QWizard page </p>
104       </blockquote>
105
106       See also Abstract Widget Classes, Dialog Classes, and Organizers.
107

MEMBER FUNCTION DOCUMENTATION

QWizard::QWizard ( QWidget * parent = 0, const char * name = 0, bool modal =

110       FALSE, WFlags f = 0 )
111       Constructs an empty wizard dialog. The parent, name, modal and f
112       arguments are passed to the QDialog constructor.
113

QWizard::~QWizard ()

115       Destroys the object and frees any allocated resources, including all
116       pages and controllers.
117

void QWizard::addPage ( QWidget * page, const QString & title ) [virtual]

119       Adds page to the end of the page sequence, with the title, title.
120

bool QWizard::appropriate ( QWidget * page ) const [virtual]

122       Called when the Next button is clicked; this virtual function returns
123       TRUE if page is relevant for display in the current context; otherwise
124       it is ignored by QWizard and returns FALSE. The default implementation
125       returns the value set using setAppropriate(). The ultimate default is
126       TRUE.
127
128       Warning: The last page of the wizard will be displayed if no page is
129       relevant in the current context.
130

void QWizard::back () [virtual protected slot]

132       Called when the user clicks the Back button; this function shows the
133       preceding relevant page in the sequence.
134
135       See also appropriate().
136

QPushButton * QWizard::backButton () const

138       Returns a pointer to the dialog's Back button
139
140       By default, this button is connected to the back() slot, which is
141       virtual so you can reimplement it in a QWizard subclass. Use
142       setBackEnabled() to enable/disable this button.
143

QPushButton * QWizard::cancelButton () const

145       Returns a pointer to the dialog's Cancel button
146
147       By default, this button is connected to the QDialog::reject() slot,
148       which is virtual so you can reimplement it in a QWizard subclass.
149

QWidget * QWizard::currentPage () const

151       Returns a pointer to the current page in the sequence. Although the
152       wizard does its best to make sure that this value is never 0, it can be
153       if you try hard enough.
154

QPushButton * QWizard::finishButton () const

156       Returns a pointer to the dialog's Finish button
157
158       By default, this button is connected to the QDialog::accept() slot,
159       which is virtual so you can reimplement it in a QWizard subclass. Use
160       setFinishEnabled() to enable/disable this button.
161

void QWizard::help () [virtual protected slot]

163       Called when the user clicks the Help button, this function emits the
164       helpClicked() signal.
165

QPushButton * QWizard::helpButton () const

167       Returns a pointer to the dialog's Help button
168
169       By default, this button is connected to the help() slot, which is
170       virtual so you can reimplement it in a QWizard subclass. Use
171       setHelpEnabled() to enable/disable this button.
172

void QWizard::helpClicked () [signal]

174       This signal is emitted when the user clicks on the Help button.
175

int QWizard::indexOf ( QWidget * page ) const

177       Returns the position of page page. If the page is not part of the
178       wizard -1 is returned.
179

void QWizard::insertPage ( QWidget * page, const QString & title, int index )

181       [virtual]
182       Inserts page at position index into the page sequence, with title
183       title. If index is -1, the page will be appended to the end of the
184       wizard's page sequence.
185

void QWizard::layOutButtonRow ( QHBoxLayout * layout ) [virtual protected]

187       This virtual function is responsible for adding the buttons below the
188       bottom divider.
189
190       layout is the horizontal layout of the entire wizard.
191

void QWizard::layOutTitleRow ( QHBoxLayout * layout, const QString & title )

193       [virtual protected]
194       This virtual function is responsible for laying out the title row.
195
196       layout is the horizontal layout for the wizard, and title is the title
197       for this page. This function is called every time title changes.
198

void QWizard::next () [virtual protected slot]

200       Called when the user clicks the Next button, this function shows the
201       next relevant page in the sequence.
202
203       See also appropriate().
204

QPushButton * QWizard::nextButton () const

206       Returns a pointer to the dialog's Next button
207
208       By default, this button is connected to the next() slot, which is
209       virtual so you can reimplement it in a QWizard subclass. Use
210       setNextEnabled() to enable/disable this button.
211

QWidget * QWizard::page ( int index ) const

213       Returns a pointer to the page at position index in the sequence, or 0
214       if index is out of range. The first page has index 0.
215

int QWizard::pageCount () const

217       Returns the number of pages in the wizard.
218

void QWizard::removePage ( QWidget * page ) [virtual]

220       Removes page from the page sequence but does not delete the page. If
221       page is currently being displayed, QWizard will display the page that
222       precedes it, or the first page if this was the first page.
223

void QWizard::selected ( const QString & ) [signal]

225       This signal is emitted when the current page changes. The parameter
226       contains the title of the selected page.
227

void QWizard::setAppropriate ( QWidget * page, bool appropriate ) [virtual]

229       If appropriate is TRUE then page page is considered relevant in the
230       current context and should be displayed in the page sequence; otherwise
231       page should not be displayed in the page sequence.
232
233       See also appropriate().
234

void QWizard::setBackEnabled ( QWidget * page, bool enable ) [virtual slot]

236       If enable is TRUE, page page has a Back button; otherwise page has no
237       Back button. By default all pages have this button.
238

void QWizard::setFinish ( QWidget *, bool ) [virtual slot]

240       This function is obsolete. It is provided to keep old source working.
241       We strongly advise against using it in new code.
242
243       Use setFinishEnabled instead
244

void QWizard::setFinishEnabled ( QWidget * page, bool enable ) [virtual slot]

246       If enable is TRUE, page page has a Finish button; otherwise page has no
247       Finish button. By default no page has this button.
248

void QWizard::setHelpEnabled ( QWidget * page, bool enable ) [virtual slot]

250       If enable is TRUE, page page has a Help button; otherwise page has no
251       Help button. By default all pages have this button.
252

void QWizard::setNextEnabled ( QWidget * page, bool enable ) [virtual slot]

254       If enable is TRUE, page page has a Next button; otherwise the Next
255       button on page is disabled. By default all pages have this button.
256

void QWizard::setTitle ( QWidget * page, const QString & title )

258       Sets the title for page page to title.
259

void QWizard::setTitleFont ( const QFont & )

261       Sets the font used for page titles. See the "titleFont" property for
262       details.
263

void QWizard::showPage ( QWidget * page ) [virtual]

265       Makes page the current page and emits the selected() signal.
266
267       This virtual function is called whenever a different page is to be
268       shown, including the first time the QWizard is shown. By reimplementing
269       it (and calling QWizard::showPage()), you can prepare each page prior
270       to it being shown.
271
272       Examples:
273

QString QWizard::title ( QWidget * page ) const

275       Returns the title of page page.
276

QFont QWizard::titleFont () const

278       Returns the font used for page titles. See the "titleFont" property for
279       details.
280
281   Property Documentation

QFont titleFont

283       This property holds the font used for page titles.
284
285       The default is QApplication::font().
286
287       Set this property's value with setTitleFont() and get this property's
288       value with titleFont().
289
290

SEE ALSO

292       http://doc.trolltech.com/qwizard.html
293       http://www.trolltech.com/faq/tech.html
294
296       Copyright 1992-2007 Trolltech ASA, http://www.trolltech.com.  See the
297       license file included in the distribution for a complete license
298       statement.
299

AUTHOR

301       Generated automatically from the source code.
302

BUGS

304       If you find a bug in Qt, please report it as described in
305       http://doc.trolltech.com/bughowto.html.  Good bug reports help us to
306       help you. Thank you.
307
308       The definitive Qt documentation is provided in HTML format; it is
309       located at $QTDIR/doc/html and can be read using Qt Assistant or with a
310       web browser. This man page is provided as a convenience for those users
311       who prefer man pages, although this format is not officially supported
312       by Trolltech.
313
314       If you find errors in this manual page, please report them to qt-
315       bugs@trolltech.com.  Please include the name of the manual page
316       (qwizard.3qt) and the Qt version (3.3.8).
317
318
319
320Trolltech AS                    2 February 2007                   QWizard(3qt)
Impressum