A List widget is typically a child of a ScrolledWindow, so that the List is displayed with ScrollBars attached to it. The
selection mechanism for the List does not change, so the user can still select items as before, but the user can now use
the ScrollBars to adjust the items in the list that are visible.
The List widget supports four different selection policies:
In single selection mode, selecting an item toggles its selection state and deselects any other selected item.
Single selection Lists should be used when only one of many choices may be selected at a time, although
under this policy there may also be no items selected. Some possible uses for a single selection List include
choosing a font family or style for text input and choosing a color for a bitmap editor.
•
In browse selection mode, selecting a new item deselects any other selected item, but there can never be a
state where no items are selected. From the user's perspective, browse selection is similar to single selection,
except that there is an initial selected item. There are also differences with respect to callback routines. This
issue is addressed in Section #slistcb.
•
In multiple selection mode, any number of items can be selected at one time. When an item is selected, the
selection state of the item is toggled; the selection states of the rest of the items are not changed. The List can
be in a state where none of the items are selected or all of the items are selected. Multiple selection mode is
advantageous in situations ...