Next: Toggle Basics Up: X WINDOWS Previous: ScrollBar Widgets

Toggle Widgets

A Toggle Widget basically provides a simple switch type of selction.

The Toggle is either a square or diamond shape indicator which if pressed can be turned on and if pressed again turned off.

Text and pictorial items, pixmaps, can be used to label a Toggle.

We may wish to have several Toggles grouped together to allow greater control. Motif provides two methods of grouping Toggles together.

RadioBox Widget
- only one of the group can be on at any given time. Toggles are diamond shape in this widget.
CheckBox Widget
- More than one Toggle can be on at any time. Togles are square. (Fig. 22).

Fig. 22 Output of toggle.c



Dave.Marshall@cm.cf.ac.uk
Tue May 24 16:52:56 BST 1994