Main Page   Modules   Alphabetical List   Compound List   File List   Compound Members   File Members  

FXWizard Class Reference

Adds support for Windows like wizard dialogs. More...

#include <FXWizard.h>

List of all members.

Public Types

enum  {
  ID_WIZARD_PREV = FXDialogBox::ID_LAST, ID_WIZARD_NEXT, ID_WIZARD_CANCEL, ID_WIZARD_HELP,
  ID_LAST
}

Public Methods

 FXWizard (FXApp *app, const FXString &name, FXImage *image, FXPoint position=FXPlacementScreen, FXint padding=5)
 FXWizard (FXWindow *owner, const FXString &name, FXImage *image, FXPoint position=FXPlacementScreen, FXint padding=5)
long onPrevOrNext (FXObject *, FXSelector, void *ptr)
long onCancel (FXObject *, FXSelector, void *ptr)
long onHelp (FXObject *, FXSelector, void *ptr)
void create ()
int run (FXWizardPage *startPage)
void move (FXuint x, FXuint y)
void move (FXPoint pos)

Static Public Methods

void chain (FXWizardPage *first,...)

Public Attributes

FXArray< FXWizardPage *> pageArray

Protected Methods

 FXWizard ()


Detailed Description

Adds support for Windows like wizard dialogs.

FXWizard is the central class for implementing 'wizard-like' dialogs. These dialogs are mostly familiar to Windows users and are nothing else but a sequence of 'pages' each of them displayed inside a dialog which has the buttons to pass to the next (and previous) pages.

The wizards are typically used to decompose a complex dialog into several simple steps and are mainly useful to the novice users, hence it is important to keep them as simple as possible.

To show a wizard dialog, you must first create an object of FXWizard class. Then you should add all pages you want the wizard to show and then call FXWizard::run.


Member Enumeration Documentation

anonymous enum
 

FXWizard specifice selector types.

Enumeration values:
ID_WIZARD_PREV  This message is sent to the wizard when the <PREV> button is selected.
ID_WIZARD_NEXT  This message is sent to the wizard when the <NEXT> button is selected.
ID_WIZARD_CANCEL  This message is sent to the wizard when the <CANCEL> button is selected, and, if the wizard contains a title bar, when the user selects [X].
ID_WIZARD_HELP  This message is sent to the wizard when the <HELP> button is selected.
ID_LAST 


Constructor & Destructor Documentation

FXWizard::FXWizard   [inline, protected]
 

FXWizard::FXWizard FXApp *    app,
const FXString &    name,
FXImage *    image,
FXPoint    position = FXPlacementScreen,
FXint    padding = 5
 

Construct a free-floating FXWizard dialog. This is the construtor to use if creating a dialog-based FXWizard application.

Parameters:
app  The application object.
name  The name of the wizard which will be display on the title bar
image  The default image to display on the left of the pages. This should be a user image or one the default image types.
position  A FXPoint location on the display where the wizard will will be displayed. The value can be an explicit FXPoint or one of the default placement types.
padding  The padding between the different components in the FXWizard.

FXWizard::FXWizard FXWindow *    owner,
const FXString &    name,
FXImage *    image,
FXPoint    position = FXPlacementScreen,
FXint    padding = 5
 

Construct a model FXWizard dialog which will always float over the owner window.

Parameters:
owner  The parent window to which the wizard is owned by.
name  The name of the wizard which will be display on the title bar
image  The default image to display on the left of the pages. This should be a user image or one the default image types.
position  A FXPoint location on the display where the wizard will will be displayed. The value can be an explicit FXPoint or one of the default placement types.
padding  The padding between the different components in the FXWizard.


Member Function Documentation

void FXWizard::chain FXWizardPage   first,
...   
[static]
 

A convenience function to make the pages follow each other. A NULL value should terminate the list.

void FXWizard::create  
 

Create the server side resources for the wizard.

void FXWizard::move FXPoint    pos
 

Moves the wizard window to a specific location. This can be called anytime before FXWizard::run()

void FXWizard::move FXuint    x,
FXuint    y
 

Moves the wizard window to a specific location. This can be called anytime before FXWizard::run()

long FXWizard::onCancel FXObject *   ,
FXSelector   ,
void *    ptr
 

Called when the <CANCEL> or [X](if toolbar is active) is pressed.

long FXWizard::onHelp FXObject *   ,
FXSelector   ,
void *    ptr
 

Called when the <HELP> button is pressed.

long FXWizard::onPrevOrNext FXObject *   ,
FXSelector   ,
void *    ptr
 

Called when the <NEXT>, <PREV>, and <FINISH>(last page only) is pressed.

int FXWizard::run FXWizardPage   startPage
 

Executes the wizard starting from the given page, returns TRUE if it was successfully finished or FALSE if user cancelled it. The first Page can not be NULL.


Member Data Documentation

FXArray<FXWizardPage*> FXWizard::pageArray
 

Holds an array of FXWizard pages. This is the only thing that effects portablility(it uses template classes). Therefore future versions may replace this with a more portable method. But for now it works :) This should also be made private and accessed through member functions but i'll save that for later.


The documentation for this class was generated from the following file:
Generated on Fri Mar 8 09:33:38 2002 by doxygen1.2.13 written by Dimitri van Heesch, © 1997-2001