Arguments: scroll-bar
Returns the value of the thumb-length property of scroll-bar controls
(vertical-scroll-bar
and horizontal-scroll-bar
). Its value
is either a positive integer that indicates how large the "thumb"
(also called the elevator or scroll-box) of the scroll-bar should be,
or else nil to use a default size. The thumb will be drawn such that
the length of the thumb compared to the length of the rest of the
interior scroll-bar length is proportional to the thumb-length
property compared to the size (scroll-max - scroll-min) of the scroll-range property.
If a scroll-bar control is being used to scroll a portion of some drawing into a scrollable area (as window scrollbars do), then typically an application would set the thumb-length to the size of the visible area and scroll-range to the size of the portion of the picture that does not fit within the visible area. Otherwise the thumb-length may not be relevant, and the default size (where thumb-length is nil) may be best.
In releases prior to 6.0, this property was called visible-portion. That symbol still names this function (and the :visible-portion initarg is still accepted), but use of visible-portion is deprecated. Further, the meaning has changed somewhat.
In releases prior to 6.0, the range of a standalone scroll-bar control included the thumb-length (then called visible-portion), which made it similar to the whole page of a scrollable window rather than the scrolling range (which is the page minus the visible portion of the page). This was an inconsistent usage of the Common Graphics scroll-range concept. It also meant, for example, if the range of a standalone scroll-bar control was 0 to 100 and the thumb-length was 20, then the possible values of the scrollbar actually ranged from 0 to 80 rather than the alleged range of 0 to 100. Starting in release 6.0, the range no longer includes the thumb-length.
It is no longer possible to disable a scroll-bar dialog-item by setting its thumb-length to be greater than or equal to the range. This no longer works since the scrollable range is independent of the thumb length. In 6.0, you can disable a scroll-bar control by setting the range with the min value equal to the max value, such as (0 0). (Also, as with other controls, scroll-bars may be disabled by setting its available property to nil.)
Common Graphics and IDE documentation is described in About Common Graphics and IDE documentation in cgide.htm.
The documentation is described in introduction.htm and the index is in index.htm.
Copyright (c) 1998-2000, Franz Inc. Berkeley, CA., USA. All rights reserved.
Created 2000.10.5.