Specifications
Athena Widget Set libXaw 1.0.7
Chapter 3
Simple Widgets
Each of these widgets performs a specific user interface function. Theyare simple because they
cannot have widget children—theymay only be used as leavesofthe widget tree. These widgets
display information or takeuser input.
Command Apush button that, when selected, may cause a specific action to takeplace.
This widget can display a multi-line string or a bitmap or pixmap image.
Grip Arectangle that, when selected, will cause an action to takeplace.
Label Arectangle that can display a multi-line string or a bitmap or pixmap image.
List Alist of text strings presented in rowcolumn format that may be individually
selected. When an element is selected an action may takeplace.
Panner Arectangular area containing a slider that may be movedintwo dimensions.
Notification of movement may be continuous or discrete.
Repeater Apush button that triggers an action at an increasing rate when selected. This
widget can display a multi-line string or a bitmap or pixmap image.
Scrollbar Arectangular area containing a thumb that when slid along one dimension may
cause a specific action to takeplace. The Scrollbar may be oriented horizontally
or vertically.
Simple The base class for most of the simple widgets. Provides a rectangular area with a
settable mouse cursor and special border.
StripChart Areal time data graph that will automatically update and scroll.
Toggle Apush button that contains state information. Toggles may also be used as
‘‘radio buttons’’toimplement a ‘‘one of many’’or‘‘zero or one of many’’group
of buttons. This widget can display a multi-line string or a bitmap or pixmap
image.
3.1. Command Widget
Application header file <X11/Xaw/Command.h>
Class header file <X11/Xaw/CommandP.h>
Class commandWidgetClass
Class Name Command
Superclass Label
The Command widget is an area, often rectangular,that contains text or a graphical image. Com-
mand widgets are often referred to as ‘‘push buttons.’’ When the pointer is overaCommand wid-
get, the widget becomes highlighted by drawing a rectangle around its perimeter.This highlight-
ing indicates that the widget is ready for selection. When mouse button 1 is pressed, the Com-
mand widget indicates that it has been selected by reversing its foreground and background col-
ors. When the mouse button is released, the Command widget’s notify action is invoked, calling
all functions on its callback list. If the pointer is movedoff ofthe widget before the pointer but-
ton is released, the widget reverts to its normal foreground and background colors, and releasing
the pointer button has no effect. This behavior allows the user to cancel an action.
18