Generic FunctionPackage: cgToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 8.2
Moderate update since 8.2 release.
8.1 version

range

Arguments: standard-object

Returns the value of the range property of a dialog-item, which indicates the set of valid values from which the end user may interactively choose. The setf of this function may be used to replace the range of a dialog-item, at which time the dialog-item will be redrawn automatically if needed to display the new range.

A variety of dialog-items (widgets) have a range property, though the meaning varies depending on the type of widget. Among them are single-item-list, multi-item-list, and combo-box. More specific information may be found on the documentation pages for each widget class.

Most widgets that use a range use one of two basic types:

  1. A list of discreet choices, where the value of the widget is one or more of these choices. multi-item-list, single-item-list, outline, and dropping-outline, for example, use this type of range.
  2. A list of two numbers (a minimum value followed by a maximum value) indicating a continuous range of choices, where the value of the widget is a number within this range (including the boundary values). vertical-scroll-bar, horizontal-scroll-bar, and trackbar widgets are among those that use this type of range.

When the range is a list of discreet choices, some widget classes use a list of arbitrary objects that can serve directly as the value of the widget, while other widget classes use a list of more specialized objects that encapsulate the values. The classes single-item-list, multi-item-list, and combo-box are of the first type. On the other hand, an outline uses a range where each member is an outline-item object, a list-view's range contains list-view-items, a multi-picture-button's range contains button-infos, a tab-control's range contains tab-infos, and a header-control's range contains header-infos.

When a range contains specialized objects, then the values of these objects are used for the value of the widget itself, rather than using the range members directly for the widget value. For example, while a single-item-list range would simply be the list of symbols (:one :two :three) to allow the value of the widget to be one of those three symbols, an outline whose value may be one of those symbols would have a range whose members are outline-items, where the value of each outline-item is one of the symbols.

Sometimes the value of a widget that has a range is a single range value, and sometimes it is a list of zero or more range values. For most widget classes this depends on the class; for example, the value of a single-item-list or tab-control is always either a single value from the range or else nil if no choices are selected, while the value of a multi-item-list, list-view , or multi-picture-button is always a list of zero or more range values. For an outline, on the other hand, whether the value is a list depends on whether the multiple-selections property of the widget is turned on.


Copyright (c) 1998-2016, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 8.1 page.
Created 2010.1.21.

ToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 8.2
Moderate update since 8.2 release.
8.1 version