Purpose |
To insert an editable combo box. |
Syntax |
winio@('%n.mel[option]',items,num_items,cur_item) |
Modifiers |
Caret (^) - call-back function is called when the user selects an item. Question mark (?) - a help string is supplied. Tilde (~) - adds a variable that controls the grey (enable/disable) state. %co (Options for Edit)[check_on_focus_loss] can be used with %el. |
Description |
This control is similar to %`ls but cur_item is a string for the current text rather than the index of the selected item. If a call-back is supplied, option can be set to [extended]. The result is that the call-back is called when the list drops down or closes up. These events must be detected from the call-back by calling CLEARWIN_STRING@ with the argument 'CALLBACK_REASON' which returns 'DROPDOWN' or 'CLOSEUP'. Using CLEARWIN_INFO@ with the argument 'EDITABLE_LISTBOX_INDEX' provides the index of the list-box item that has been selected by the user. If this value is obtained within the %el callback function then you may need to add the option %el[extended] in order to ensure that the callback function is called every time an item is selected. The option [height=n] sets the pixel height of individual items to 'n' pixels. The default value is 16. An asterisk can be used and the value passed in the argument list. See %ls (List Box (or Combo Box)) for further details. |
See also |
%ls (List Box (or Combo Box)), %ms (Multi-select Box), %lv (List View), %pb (Parameter Box), %ps (Property Sheet Container) |