Topic : TOS - The Operating System Author : Version : tos.hyp (December 19, 2008) Subject : Programmieren/Atari Nodes : 3010 Index Size : 93790 HCP-Version : 5 Compiled on : Atari @charset : atarist @lang : @default : Title @help : @options : +g -i -s +x +zz -t4 @width : 70 View Ref-File8.22.41 SET_ITEM TOS typedef int16_t (cdecl *SET_ITEM)( LIST_BOX *box, OBJECT *tree, struct _lbox_item *item, int16_t obj_index, void *user_data, GRECT *rect, int16_t first ); Parameter Meaning box points to the list box structure tree points to the object tree of the dialog item points to the LBOX_ITEM structure of the entry to be set obj_index is the number of the object to be set user_data is the pointer passed by lbox_create rect is the pointer to the GRECT for the object redraw or 0L first contains the number of the first visible item for Slider B For a list box that only contains text strings, <set> is typically a function that copies a string pointed to by the LBOX_ITEM structure into the object obj_index. rect is 0L when a redraw of the dialog box is executed or when lbox_update has been called. rect is not 0L when the user has selected or deselected an object, and points to the GRECT for the redraw. The return value is the number of the start object for objc_draw/wdlg_redraw. For entries in the list box that consist of several objects it is sometimes sensible to reduce the redraw rectangle when selecting/ deselecting an object, or to alter the start object, to prevent unnecessary drawing operations and/or unnecessary flicker. In most cases the list box routines call the function objc_draw/wdlg_redraw after <set> to display the altered contents. first contains the number of the first visible item for Slider B if the list box has two sliders. For a (vertical) list box with text strings and two sliders, when calling lbox_create, for instance, one enters the number of visible characters in visible_b, the total string length in entries_b and the index of the first visible character in first_b. If the text is scrolled horizontally, <set> is called for all visible strings and the affected parts of the screen are redrawn or moved. If the list box has only one slider, first is always 0. See Also: List boxes lbox_create