The interaction style of the choice.
The indexes of the choice's selected items.
inherits most of its behavior from collection, and then provides the selection facilities itself. The classes list-panel, button-panel, option-pane, menu-component and graph-pane inherit from it, and so it plays a key role in CAPI applications.
The choice behaves just as a collection.
, the choice can have any number of items selected, and selecting an item toggles its selection status. The
is called when an item becomes selected, and the
is called when an item is deselected.
is not supported on Mac OS X.
, the choice can have any number of items selected as with
interaction, but the usual selection gesture removes the old selection. However, there is a window system-specific means of extending the selection. When an item is selected the
is called, when the selection is extended the
is called, and when an item is deselected the
On Mac OS X, the selection gesture is mouse (left button) click. De-selection and discontinuous selections are made by
, and a continuous selection is made by
, regardless of whether if
The choice's selection stores the indices of the currently selected item, and is a single number for single selection choices and a list for all other interactions. The functions choice-selected-item and choice-selected-items treat the selection in terms of the items themselves as opposed to their indices.
(setf (capi:choice-selection choice) 1)