Skip to content

GRAPHREP_TOOL

This command shows a dockable window (=tool) which displays one or more GraphReps.

Syntax

leo-grammar
CC "AdoScript" GRAPHREP_TOOL	graphrep:strValue [ title:strValue ] 
								[ interval:intValue ] [ align:strValue ] 
								[ index:intValue ] [ subindex:intValue ]
								[ min-w:intValue ] [ min-h:intValue ]
								[hide-close-button ] [not-movable ]

# --> RESULT ecode:intValue .
CC "AdoScript" GRAPHREP_TOOL	graphrep:strValue [ title:strValue ] 
								[ interval:intValue ] [ align:strValue ] 
								[ index:intValue ] [ subindex:intValue ]
								[ min-w:intValue ] [ min-h:intValue ]
								[hide-close-button ] [not-movable ]

# --> RESULT ecode:intValue .

Parameters

  • graphrep (strValue) - the GraphRep(s) to be displayed. If several are given, each part has again to start with the keyword "GRAPHREP".
  • title (strValue, optional) - the title of the dockable window
  • interval (intValue, optional) - time in milliseconds to switch between several given GraphReps. Default is 10000, i.e. 10 seconds. When the last of several GraphReps was displayed, again the first is shown (endless loop).
  • align (enumValue, optional) - specifies where the window is shown. Possible values are "top", "left", "right" and "bottom". Default is "left".
  • index (intValue, optional) - defines the index of the workpanel (starting with 0, i.e. top/left). Default is 0.
  • subindex (intValue, optional) - gives the index of the tool within the workpanel (starting with 0). Default is 4711.
  • min-w (intValue, optional) - the minimum width of the tool in pixel. Moving/sizing other tool windows should respect that minimum size.
  • min-h (intValue, optional) - the minimum height of the tool in pixel. Moving/sizing other tool windows should respect that minimum size.
  • hide-close-button (modifier, optional) - specifies if close button should be hidden. If so, the tool window can not be closed. It will also remain, if F11 is pressed to enter fullscreen mode.
  • not-movable (modifier, optional) - specifies if the tool window should not be movable. If so, the tool window will only change its position indirectly by moving/sizing other tool windows.

Returns

  • ecode (intValue) - contains the error code or 0 if no error occurred

Details

The dockable window framework in ADOxx allows to have windows on four sides: top, left, right, bottom.
At each side a sequence of "workpanels" can exist. Each workpanel can contain one or several tool panels, which actually contain the single tools.
In the standard ADOxx configuration the tool "Quickaccess" is located at the top, the tools "Explorer" and "Navigator" are located in one workpanel on the left and the modelling bar is also located at the left side, but in a different workpanel.
The query and simulation result as well as the message window is located at the bottom part of the application window.

The default values of the parameters "align", "index" and "subindex" create a tool window in the bottomleft area of the window. As it is aligned left, having something displayed in the bottom part will mean that the tool is moved upwards a little.

Within the graphrep a HOTSPOT element with an associated script can be defined. When the hotspot is clicked, the given script is executed.

Note that while it is possible to set only min-w (or min-h) and not both, the platform actually only supports the cases that both restrictions are given or both are not given!

Note the correct masking of " and \ characters when defining complex GraphReps within the command, see also the example below!

See Also:

Examples

asc
CC "AdoScript" GRAPHREP_TOOL title:"Hello to OMiLAB" 
		min-w:350 min-h:300 
		graphrep:"GRAPHREP
		BITMAP (\"https://www.omilab.org/assets/images/omilab_logo_.png\") 
		x:3cm y:3cm w:3cm h:2cm"
CC "AdoScript" GRAPHREP_TOOL title:"Hello to OMiLAB" 
		min-w:350 min-h:300 
		graphrep:"GRAPHREP
		BITMAP (\"https://www.omilab.org/assets/images/omilab_logo_.png\") 
		x:3cm y:3cm w:3cm h:2cm"

Versions and Changes

Available since ADOxx 1.3