The List Objects: 3.5 GenItemGroups: Scrolling GenItemGroups

Up: GEOS SDK TechDocs | Up | Prev: 3.4 Working with Items | Next: 3.6 GenItemGroup Links
HINT_ITEM_GROUP_SCROLLABLE, MSG_GEN_ITEM_GROUP_MAKE_ITEM_VISIBLE

A scrolling list is a special version of a GenItemGroup that allows the user to scroll through a list of items which are not all visible at one time. Scrolling lists usually provide scrollbars or some other means to quickly scan through a list. You may make a GenItemGroup scrollable if the specific UI allows by including the hint HINT_ITEM_GROUP_SCROLLABLE in the list's object declaration.

The list will come up in a standard size determined by the specific UI. You may override this by adding a size hint to the object ( HINT_FIXED_SIZE , HINT_INITIAL_SIZE , etc.). Notification of changes for a scrolling list, as well as setting and getting the selections, works the same for a scrolling list as for a normal GenItemGroup. If an item is selected, the scrolling list will almost always scroll automatically to the selected item.

To force a GenItemGroup to scroll to an item, send MSG_GEN_ITEM_GROUP_MAKE_ITEM_VISIBLE . Pass this message the identifier of the item to be made visible in the scrolling list. This message has no effect on a non-scrolling list.

You may wish in some cases for a scrolling list to be for display only. If so, set the scrollable GenItemGroup's GI_ attrs instance data to include the flag GA_READ_ONLY. The user will be unable to interact with a display-only scrolling list (although, of course, the user will still be able to scroll through the list).

If your scrolling list will have many settings or will often be dynamically updated, you should consider using a GenDynamicList instead.

MSG_GEN_ITEM_GROUP_MAKE_ITEM_VISIBLE

void	MSG_GEN_ITEM_GROUP_MAKE_ITEM_VISIBLE(
        word	identifier);

This message ensures that an item within a scrolling GenItemGroup is visible, by scrolling the list if necessary. This message has no effect if the GenItemGroup is not scrollable or is not usable.

Source: Unrestricted.

Destination: Any scrollable, usable GenItemGroup object.

Parameters: identifier The identifier of the item to be made visible.

Return: Nothing.

Interception: Generally not intercepted.


Up: GEOS SDK TechDocs | Up | Prev: 3.4 Working with Items | Next: 3.6 GenItemGroup Links