octave: GUI Utility Functions

 
 35.4 GUI Utility Functions
 ==========================
 
 These functions do not implement a GUI element but are useful when
 developing programs that do.  The functions ‘uiwait’, ‘uiresume’, and
 ‘waitfor’ are only available with the ‘qt’ or ‘fltk’ toolkits.
 
  -- : USED = desktop ("-inuse")
      Return true if the desktop (GUI) is currently in use.
 
      See also: Seeisguirunning XREFisguirunning.
 
  -- : DATA = guidata (H)
  -- : guidata (H, DATA)
      Query or set user-custom GUI data.
 
      The GUI data is stored in the figure handle H.  If H is not a
      figure handle then it’s parent figure will be used for storage.
 
      DATA must be a single object which means it is usually preferable
      for it to be a data container such as a cell array or struct so
      that additional data items can be added easily.
 
DONTPRINTYET       See also: Seegetappdata XREFgetappdata, *notesetappdata:
DONTPRINTYET DONTPRINTYET       See also: Seegetappdata XREFgetappdata, Seesetappdata

      XREFsetappdata, Seeget XREFget, Seeset XREFset, *noteDONTPRINTYET DONTPRINTYET       See also: Seegetappdata XREFgetappdata, Seesetappdata

      XREFsetappdata, Seeget XREFget, Seeset XREFset, See
      getpref XREFgetpref, Seesetpref XREFsetpref.
 
  -- : HDATA = guihandles (H)
  -- : HDATA = guihandles
      Return a structure of object handles for the figure associated with
      handle H.
 
      If no handle is specified the current figure returned by ‘gcf’ is
      used.
 
      The fieldname for each entry of HDATA is taken from the "tag"
      property of the graphic object.  If the tag is empty then the
      handle is not returned.  If there are multiple graphic objects with
      the same tag then the entry in HDATA will be a vector of handles.
      ‘guihandles’ includes all possible handles, including those for
      which "HandleVisibility" is "off".
 
      See also: Seeguidata XREFguidata, Seefindobj XREFfindobj,
      Seefindall XREFfindall, Seeallchild XREFallchild.
 
  -- : have_window_system ()
      Return true if a window system is available (X11, Windows, or Apple
      OS X) and false otherwise.
 
      See also: Seeisguirunning XREFisguirunning.
 
  -- : isguirunning ()
      Return true if Octave is running in GUI mode and false otherwise.
 
      See also: Seehave_window_system XREFhave_window_system.
 
  -- : uiwait
  -- : uiwait (H)
  -- : uiwait (H, TIMEOUT)
      Suspend program execution until the figure with handle H is deleted
      or ‘uiresume’ is called.
 
      When no figure handle is specified this function uses the current
      figure.  If the figure handle is invalid or there is no current
      figure, this functions returns immediately.
 
      When specified, TIMEOUT defines the number of seconds to wait for
      the figure deletion or the ‘uiresume’ call.  The timeout value must
      be at least 1.  If a smaller value is specified, a warning is
      issued and a timeout value of 1 is used instead.  If a non-integer
      value is specified, it is truncated towards 0.  If TIMEOUT is not
      specified, the program execution is suspended indefinitely.
 
      See also: Seeuiresume XREFuiresume, Seewaitfor XREFwaitfor.
 
  -- : uiresume (H)
      Resume program execution suspended with ‘uiwait’.
 
      The handle H must be the same as the on specified in ‘uiwait’.  If
      the handle is invalid or there is no ‘uiwait’ call pending for the
      figure with handle H, this function does nothing.
 
      See also: Seeuiwait XREFuiwait.
 
  -- : waitfor (H)
  -- : waitfor (H, PROP)
  -- : waitfor (H, PROP, VALUE)
  -- : waitfor (..., "timeout", TIMEOUT)
      Suspend the execution of the current program until a condition is
      satisfied on the graphics handle H.
 
      While the program is suspended graphics events are still processed
      normally, allowing callbacks to modify the state of graphics
      objects.  This function is reentrant and can be called from a
      callback, while another ‘waitfor’ call is pending at the top-level.
 
      In the first form, program execution is suspended until the
      graphics object H is destroyed.  If the graphics handle is invalid,
      the function returns immediately.
 
      In the second form, execution is suspended until the graphics
      object is destroyed or the property named PROP is modified.  If the
      graphics handle is invalid or the property does not exist, the
      function returns immediately.
 
      In the third form, execution is suspended until the graphics object
      is destroyed or the property named PROP is set to VALUE.  The
      function ‘isequal’ is used to compare property values.  If the
      graphics handle is invalid, the property does not exist or the
      property is already set to VALUE, the function returns immediately.
 
      An optional timeout can be specified using the property ‘timeout’.
      This timeout value is the number of seconds to wait for the
      condition to be true.  TIMEOUT must be at least 1.  If a smaller
      value is specified, a warning is issued and a value of 1 is used
      instead.  If the timeout value is not an integer, it is truncated
      towards 0.
 
      To define a condition on a property named ‘timeout’, use the string
      ‘\timeout’ instead.
 
      In all cases, typing CTRL-C stops program execution immediately.
 
DONTPRINTYET       See also: Seewaitforbuttonpress XREFwaitforbuttonpress, *noteDONTPRINTYET       See also: Seewaitforbuttonpress XREFwaitforbuttonpress, See
      isequal XREFisequal.