Sage-ST ä

Ctrllist

Documentation

ClearAllMarks ClearMark ClearSearch ControlCommand
CurrentControlID CurrentDialogID DisableControl EnableControl
GetListInfo GetSearchValue HideControl IsEnabled
IsMarked ItemIndex MarkItem MarkedCount
NextMarked RedrawControl Reset STRGetSearchValue
STRSetItemValue SelectedItemIndex SetFocus SetItemColors
SetItemValue SetRange SetSearchResult SetTabs
ShowControl




  function ControlCommand
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer) : ControlMessage; stdcall;

  exports ControlCommand name 'CtrlList_ControlCommand';

  //*
  //  ControlCommand - Retrieves command which has been sent from control.
  //
  //
  //  This routine will retrieve a command which has been sent from the
  //  control to the ActionProc.
  //
  //  CALLING SEQUENCE -
  //
  //    command := ControlCommand (msgType, msgData)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    command : ControlMessage
  //      The command which has been sent.  Must be one of the Control
  //      Messages defined for the control receiving the command.  The
  //      command Unknown indicates an undefined command has been sent.
  //




  function CurrentDialogID
             (const msgData : pointer) : cardinal; stdcall;

  exports CurrentDialogID name 'CtrlList_CurrentDialogID';

  //*
  //  CurrentDialogID - Retrieves ID of dialog to which a message was sent.
  //
  //
  //  This routine will retrieve a the ID of a dialog to which a message
  //  has been sent.
  //
  //  CALLING SEQUENCE -
  //
  //    dialogID := CurrentDialogID (msgData)
  //
  //  ENTRY -
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    dialogID : cardinal
  //      The ID of the dialog receiving a message.
  //




  function CurrentControlID
             (const msgData : pointer) : cardinal; stdcall;

  exports CurrentControlID name 'CtrlList_CurrentControlID';

  //*
  //  CurrentControlID - Retrieves ID of control for which a message is intended.
  //
  //
  //  This routine will retrieve the ID of a control for which a message
  //  is intended.
  //
  //  CALLING SEQUENCE -
  //
  //    controlID := CurrentControlID (msgData)
  //
  //  ENTRY -
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    controlID : cardinal
  //      The ID of the control.
  //




  function IsEnabled
             (const dialogID  : cardinal;
              const controlID : cardinal) : boolean; stdcall;

  exports IsEnabled name 'CtrlList_IsEnabled';

  //*
  //  IsEnabled - Checks to see if a control is enabled.
  //
  //
  //  This routine will determine whether a control is enabled or
  //  disabled (grayed).
  //
  //  CALLING SEQUENCE -
  //
  //    status := IsEnabled (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //  EXIT -
  //
  //    status : boolean
  //      True if the control is enabled.
  //




  procedure EnableControl
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports EnableControl name 'CtrlList_EnableControl';

  //*
  //  EnableControl - Enables a control.
  //
  //
  //  This routine will enable the specified control.
  //
  //  CALLING SEQUENCE -
  //
  //    EnableControl (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure DisableControl
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports DisableControl name 'CtrlList_DisableControl';

  //*
  //  DisableControl - Disables a control.
  //
  //
  //  This routine will disable (gray) the specified control.
  //
  //  CALLING SEQUENCE -
  //
  //    DisableControl (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure HideControl
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports HideControl name 'CtrlList_HideControl';

  //*
  //  HideControl - Hides a control.
  //
  //
  //  This routine will hide the specified control.
  //
  //  CALLING SEQUENCE -
  //
  //    HideControl (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure SetItemColors
             (const msgType    : DWSpec.DisplayMessageType;
              const msgData    : pointer;
              const textColor  : ListColorType;
              const bkGndColor : ListColorType); stdcall;

  exports SetItemColors name 'CtrlList_SetItemColors';

  //*
  //  SetItemColors - Sets text and background colors of an item.
  //
  //
  //  The SagesList sends a FindItem message in order to populate the SageList.
  //  The programmer should use this routine to set text and background
  //  colors for the item being requested.
  //
  //  CALLING SEQUENCE -
  //
  //    SetItemValue (msgType, msgData, textColor, bkGndColor)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //    textColor : ListColorType
  //      The color in which to display the text. Must be one of the
  //      colors defined in ListColorType.
  //
  //    bkGndColor : ListColorType
  //      The color in which to display the background. Must be one of the
  //      colors defined in ListColorType.
  //




  procedure ShowControl
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports ShowControl name 'CtrlList_ShowControl';

  //*
  //  ShowControl - Shows a control.
  //
  //
  //  This routine will show the specified control.
  //
  //  CALLING SEQUENCE -
  //
  //    ShowControl (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure SetFocus
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports SetFocus name 'CtrlList_SetFocus';

  //*
  //  SetFocus - Sets to focus to a control.
  //
  //
  //  This routine will give the specified control focus.
  //
  //  CALLING SEQUENCE -
  //
  //    SetFocus (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure RedrawControl
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports RedrawControl name 'CtrlList_RedrawControl';

  //*
  //  RedrawControl - Redraws a control.
  //
  //
  //  This routine will redraw the specified control.
  //
  //  CALLING SEQUENCE -
  //
  //    RedrawControl (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure ClearAllMarks
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports ClearAllMarks name 'CtrlList_ClearAllMarks';

  //*
  //  ClearAllMarks - Unmarks all items in a SageList.
  //
  //
  //  This routine will unmark all items in a SageList.
  //
  //  CALLING SEQUENCE -
  //
  //    ClearAllMarks (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure ClearMark
             (const dialogID  : cardinal;
              const controlID : cardinal;
              const index     : cardinal); stdcall;

  exports ClearMark name 'CtrlList_ClearMark';

  //*
  //  ClearMark - Unmarks an item in a SageList.
  //
  //
  //  This routine will unmark an item in a SageList.  The programmer may
  //  specify whether or not the SageList is immediately redrawn to
  //  reflect the change.
  //
  //  CALLING SEQUENCE -
  //
  //    ClearMark (dialogID, controlID, index, redraw)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //    index : cardinal
  //      The position (1 .. n) of the item in the SageList to unmark.
  //      If the SageList is single select, then the marked item will
  //      be unmarked regardless of this value.
  //




  procedure ClearSearch
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports ClearSearch name 'CtrlList_ClearSearch';

  //*
  //  ClearSearch - Clears the current SageList search string.
  //
  //
  //  This routine will clear the internal search string for the
  //  SageList and cause a SearchClear message to be sent to the
  //  ActionProc.  It is the programmers responsiblity to reposition
  //  the selected SageList item if desired.
  //
  //  CALLING SEQUENCE -
  //
  //    ClearSearch (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  procedure GetListInfo
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              var   index   : cardinal;
              var   lines   : cardinal); stdcall;

  exports GetListInfo name 'CtrlList_GetListInfo';

  //*
  //  GetListInfo - Gets the # of items which can be displayed in the visible part.
  //
  //
  //  The SageList sends a ListDone message when it is finished
  //  responding to a user request to display data (i.e. the user
  //  has moved the thumb position).  This routine can be used
  //  in response to a ListDone message to retrieve the # of items
  //  displayed in the list and the index position of the item at
  //  the top of the list.
  //
  //  CALLING SEQUENCE -
  //
  //    GetListInfo (msgType, msgData, index, lines)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    index : cardinal
  //      The position of the top item displayed in the list with respect
  //      to the entire list.  The first position is 1.
  //
  //    lines : cardinal
  //      The number of items which can be displayed in the visible part of
  //      the list.
  //




  procedure GetSearchValue
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              var   Value   : array of char); overload; stdcall;

  exports GetSearchValue (const msgType : DWSpec.DisplayMessageType;
                          const msgData : pointer;
                          var   Value   : array of char) name 'CtrlList_GetSearchValue';

  //*
  //  GetSearchValue - Retrieves current search string from the SageList.
  //
  //
  //  The SageList sends a SearchChange message when the search string
  //  has changed.  The programmer may use this routine to get the
  //  current search string.  The programmer can then use this value to
  //  perform a search to find a new index to position the list at.
  //  The SetSearchResult routine can then be used to tell the SageList
  //  what the new position will be.
  //
  //  CALLING SEQUENCE -
  //
  //    GetSearchValue (msgType, msgData, value)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //    value : array of char
  //      The search string.
  //




  procedure GetSearchValue
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              var   Value   : string); overload; stdcall;

  exports GetSearchValue (const msgType : DWSpec.DisplayMessageType;
                          const msgData : pointer;
                          var   Value   : string) name 'CtrlList_STRGetSearchValue';

  //*
  //  STRGetSearchValue - See documentation of GetSearchValue.
  //




  function IsMarked
             (const dialogID  : cardinal;
              const controlID : cardinal;
              const index     : cardinal) : boolean; stdcall;

  exports IsMarked name 'CtrlList_IsMarked';

  //*
  //  IsMarked - Checks the marked/unmarked status of an item.
  //
  //
  //  This routine will check the marked/unmarked status of an item
  //  in a SageList.
  //
  //  CALLING SEQUENCE -
  //
  //    status := IsMarked (dialogID, controlID, index)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //    index : cardinal
  //      The position (1 .. n) of the item in the SageList to check.
  //
  //  EXIT -
  //
  //    status : boolean
  //      True if the item is marked.  False if the item is not marked.
  //




  function ItemIndex
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer) : cardinal; stdcall;

  exports ItemIndex name 'CtrlList_ItemIndex';

  //*
  //  ItemIndex - Gets index number of item that FindItem message is requesting.
  //
  //
  //  The SagesList sends a FindItem message in order to determine
  //  the value of an item in a SageList.  The programmer should
  //  use this routine to determine the index number (1 .. n) of the
  //  item which is being requested by the FindItem message.
  //
  //  CALLING SEQUENCE -
  //
  //    index := ItemIndex (msgType, msgData)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    index : cardinal
  //      The index number (1 .. n) of the item which was requested by the
  //      FindItem message.
  //




  function MarkedCount
             (const dialogID  : cardinal;
              const controlID : cardinal) : cardinal; stdcall;

  exports MarkedCount name 'CtrlList_MarkedCount';

  //*
  //  MarkedCount - Gets number of items in SageList which have been marked.
  //
  //
  //  This routine will return the number of items in the SageList
  //  which are marked.
  //
  //  CALLING SEQUENCE -
  //
  //    count := MarkedCount (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //  EXIT -
  //
  //    couht : cardinal
  //      The number of marked items in the list.  If no items are marked,
  //      then count will be 0.
  //




  procedure MarkItem
             (const dialogID  : cardinal;
              const controlID : cardinal;
              const index     : cardinal;
              const Redraw    : boolean); stdcall;

  exports MarkItem name 'CtrlList_MarkItem';

  //*
  //  MarkItem - Marks an item in a SageList.
  //
  //
  //  This routine will mark an item in a SageList.  The list will be
  //  scrolled to make the marked item visible.  The programmer may
  //  specify whether or not the SageList is immediately redrawn to
  //  reflect the change.
  //
  //  CALLING SEQUENCE -
  //
  //    MarkItem (dialogID, controlID, index, redraw)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //    index : cardinal
  //      The position (1 .. n) of the item in the SageList to mark.
  //      If the SageList is multiple select, then any list items
  //      which are already selected will remain selected.
  //
  //    redraw : boolean
  //      Set to True to have the SageList immediately reflect the change.
  //      If set to False, the change will happen only after a redraw of
  //      the SageList has occurred.
  //




  function NextMarked
             (const dialogID  : cardinal;
              const controlID : cardinal;
              const startPos  : cardinal) : cardinal; stdcall;

  exports NextMarked name 'CtrlList_NextMarked';

  //*
  //  NextMarked - Gets index of the next marked item in a SageList.
  //
  //
  //  This routine will get the index number (1 .. n) of the next marked
  //  item in the SageList with respect to the value passed in for index.
  //
  //  CALLING SEQUENCE -
  //
  //    index := MarkedCount (dialogID, controlID, startPos)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //    startPos : cardinal
  //      The position (1 .. n) in the SageList (inclusive of this
  //      position) from which the search for the next marked item
  //      will start.  If set to 1 the first marked item will be found.
  //
  //  EXIT -
  //
  //    index : cardinal
  //      The position (1 .. n) in the SageList of the next marked item.
  //      This value will be 0 if no more items in the SageList
  //      are marked.
  //




  procedure Reset
             (const dialogID  : cardinal;
              const controlID : cardinal); stdcall;

  exports Reset name 'CtrlList_Reset';

  //*
  //  Reset - Resets the control.
  //
  //
  //  This routine will cause the control to be reset.  This will result
  //  in the list being cleared and a new Range message being sent.
  //
  //  CALLING SEQUENCE -
  //
  //    Reset (dialogID, controlID)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //




  function SelectedItemIndex
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer) : cardinal; stdcall;

  exports SelectedItemIndex name 'CtrlList_SelectedItemIndex';

  //*
  //  SelectedItemIndex - Gets index (1 .. n) of the item which has been selected.
  //
  //
  //  The SageList sends a DoubleClick, SelectedChange, or
  //  SelectedCancel message when an item in the list has been selected.
  //  The programmer can use this routine to get the index position of
  //  the selected item.
  //
  //  CALLING SEQUENCE -
  //
  //    index := SelectedItemIndex (msgType, msgData)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //  EXIT -
  //
  //    index : cardinal
  //      The position in the list of the item which has been selected.
  //      The first position is 1.
  //




  procedure SetItemValue
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              const Value   : array of char;
              const Status  : integer); overload; stdcall;

  exports SetItemValue (const msgType : DWSpec.DisplayMessageType;
                        const msgData : pointer;
                        const Value   : array of char;
                        const Status  : integer) name 'CtrlList_SetItemValue';

  //*
  //  SetItemValue - Sets value of item that FindItem message is requesting.
  //
  //
  //  The SagesList sends a FindItem message in order to determine
  //  the value of an item in a SageList.  The programmer should
  //  use this routine to set that value.
  //
  //  CALLING SEQUENCE -
  //
  //    SetItemValue (msgType, msgData, value, status)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //    value : array of char
  //      The text string which will appear in the SageList.
  //
  //    status : integer
  //      Return one of the following values -
  //          SLB_OK         If able to obtain the value
  //          SLB_ENDOFFILE  If no more data is available (this will cause
  //                         the FindItem messages to stop)
  //          SLB_ERR        If there was a problem obtaining the data.
  //




  procedure SetItemValue
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              const Value   : string;
              const Status  : integer); overload; stdcall;

  exports SetItemValue (const msgType : DWSpec.DisplayMessageType;
                        const msgData : pointer;
                        const Value   : string;
                        const Status  : integer) name 'CtrlList_STRSetItemValue';

  //*
  //  STRSetItemValue - See documentation of SetItemValue.
  //




  procedure SetRange
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              const index   : cardinal;
              const Status  : integer); stdcall;

  exports SetRange name 'CtrlList_SetRange';

  //*
  //  SetRange - Sets the number of items to be in the SageList.
  //
  //
  //  The SagesList sends a Range message in order to determine
  //  the total number of items that will be in the list.  The
  //  programmer should use this routine to respond to the Range
  //  message.
  //
  //  CALLING SEQUENCE -
  //
  //    SetRange (msgType, msgData, index, status)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //    index : cardinal
  //      The total number of items to be placed in the list.
  //
  //    status : integer
  //      Return one of the following
  //          SLB_OK   If able to obtain the range
  //          SLB_ERR  If the range cannot be determined
  //




  procedure SetSearchResult
             (const msgType : DWSpec.DisplayMessageType;
              const msgData : pointer;
              const index   : cardinal;
              const Status  : integer); stdcall;

  exports SetSearchResult name 'CtrlList_SetSearchResult';

  //*
  //  SetSearchResult - Instructs SageList to reposition itself as result of search.
  //
  //
  //  The SageList sends a SearchChange message when the search string
  //  has changed.  The programmer uses the GetSearchValue routines
  //  to get the current search string.  The programmer uses the
  //  search string to determine if the list needs to be repositioned.
  //  If so, the programmer can use this routines to reposition the
  //  list to a new index.
  //
  //  CALLING SEQUENCE -
  //
  //    SetSearchResult (msgType, msgData, index, status)
  //
  //  ENTRY -
  //
  //    msgType : DWSpec.DisplayMessageType
  //      The msgType parameter which was passed into the ActionProc.
  //
  //    msgData : pointer
  //      The msgData parameter which was passed into the ActionProc.
  //
  //    index : cardinal
  //      The index number (1 .. n) of the item which matched the search
  //      conditions.
  //
  //    status : integer
  //      Return one of the following
  //          SLB_OK    To reposition the list to the new index.
  //          SLB_ERR   If there was a problem with the search.
  //




  procedure SetTabs
             (const dialogID  : cardinal;
              const controlID : cardinal;
              const numTabs   : cardinal;
              const tabs      : array of cardinal); stdcall;

  exports SetTabs name 'CtrlList_SetTabs';

  //*
  //  SetTabs - Sets the tabs for a SageList.
  //
  //
  //  This procecure allows the application programmer to set the
  //  tab stops in a SageList for formatting the data.
  //
  //  CALLING SEQUENCE -
  //
  //    SetTabs (dialogID, controlID, numTabs, tabs)
  //
  //  ENTRY -
  //
  //    dialogID : cardinal
  //      The number of the dialog box or window containing the
  //      control.
  //
  //    controlID : cardinal
  //      The control resource identifier.
  //
  //    numTabs : cardinal
  //      The number of tabs being set (maximum is 20).
  //
  //    tabs : array of cardinal
  //      Array containing up to 20 tab stop positions.  Tab stop
  //      positions are in units of pixels.
  //




Send mail to   warren.merrill@inl.gov with questions or comments about this web site.
Copyright © 1989-2006 Battelle Energy Alliance