:scroll-* simple-pane initargs for each dimension correspond to the six keyword arguments of set-horizontal-scroll-parameters/get-horizontal-scroll-parameters and set-vertical-scroll-parameters/get-vertical-scroll-parameters as follows:
The difference between the max-range and min-range specifies the range of scrolling. When applied to the scrollbar display, all the values are scaled by the ratio between the height/width of the scrollbar and the range, for example
slug-size-in-pixels = slug-size * scrollbar-height-in-pixels / ( max-range - min-range )
slug-position-in-pixels = ( slug-position - min-range ) * scrollbar-height-in-pixels / ( max-range - min-range )
pane-scrolling-position = ( slug-position - min-range ) * pane-dimension / slug-size
is not supplied or is
nil, it is set to track the dimension of the pane, so the scaling factor above is 1, and all the other numbers can be considered as if specified in pixels in the internal coordinates of the pane. If
is supplied, it is in effect creating a scaling factor between the values and the coordinates in the pane.
The min-range initial value defaults to 0, the max-range initial value defaults to either the width/height in pixels of the data in the pane if this is deducible, otherwise to the height of the pane. The latter is not useful, and typically the max-range is the one value that you have to specify. In many cases it is the only value you need to specify.
defines the amount to scroll for a gesture that means step (typically clicking on the arrows at the ends of the scrollbar). It initially defaults to the dimension of a character in the pane in pixels. Note that this is normally useful only if
is not set, otherwise it is scaled by
. If you set the
, you probably want to set the
page-size defines the amount to scroll for page gestures (typically clicking on the scroll bar outside the scroll slug). It initially defaults to slug-size - step-size , which is normally the useful value.
Automatic scrolling of the parent to show the focus pane can be specified by using scroll-if-not-visible-p.
CAPI User Guide and Reference Manual (Macintosh version) - 25 Feb 2015