Next: The WarningDialog
Up: X WINDOWS
Previous: Other MainWindow children
Dialogs are the means in which an application can converse with a user.
- Dialogs put up a box with a message in and may also prompt the user for some
- Three buttons may also be provided:
- Ok and Cancel used to perhaps acknowledge the message and remove
the Dialog box.
- Help some additional information may be provided.
- You have probably seen this in action with a texteditor putting up a
message like ``Cannot open file ....''
Dialogs have many uses. As such many sorts of Dialogs are provided by Motif:
- - Allows customised Dialogs to be created.
- - Alerts User to errors in the program.
- - Selection from a list of options.
- - Specialised Selection Dialog to select
directories and files.
- - Program Information supplied.
- - Allows user to supply data to program.
- - Yes/No type queries.
- - Warns User about a program mishap.
- - Notifies user if program is busy.
To create a Dialog use one of the XmCreate.....Dialog() functions.
To make a Dialog appear in your program you must manage the widget.
To make one disappear you must unmanage it.
The use of many dialogs is very similar. We will look at a few specific Dialogs
in detail. Others are similar (see Exercises).