SaListShowSelectedItem(TCL_ADM)
SaListShowSelectedItem, SaDrawnListShowSelectedItem --
SCO Visual Tcl interface for bringing selected list items into view
Syntax
SaListShowSelectedItem list [forcetop] [drawn]
SaDrawnListShowSelectedItem list [forcetop]
Description
In SCO Visual Tcl, selecting a list item and scrolling a list item into view
are two different operations and are not functionally or logically connected.
These procedures conveniently relate them, providing a simple interface to
scroll selected items into view without knowing their position etc.
These are especially useful with form dialogs containing lists that
appear initially with pre-selected default items which are not necessarily
the first items in the list.
Both procedures will scroll the minimal amount to bring the first of
one or more selected items into view in the list widget window. If this
selected item is already in view, no scrolling occurs. The list may
scroll backwards if the selected item is above the current view, in which
case the item appears at the top. A forward scroll to an item below the
current view leaves the item at the bottom. The selected item (possibly the
first of many) may be scrolled unconditionally to the first visible list item
by using ``forcetop''.
The caller must distinguish between ``regular'' and ``drawn'' lists since
SCO Visual Tcl uses two different interfaces and because there is no
way to determine this automatically.
Arguments
list-
SCO Visual Tcl list widget.
forcetop-
force the selected item to appear at the top of the
list regardless of forward scroll direction (boolean).
drawn-
SaListShowSelectedItem will automatically use the drawn list
interface if this argument is set to anything nonzero. By default, it is 0.
See also
SCO Visual Tcl Programmer's Guide and Reference in SCO Visual Tcl Programmer's Guide and Reference.
16 September 2002
© 2003 Caldera International, Inc. All rights reserved.
SCO OpenServer Release 5.0.7 -- 11 February 2003