GuidoEntityBrowserField
Overview
A GuidoEntityBrowserField is a special implementation of a GuidoComboBox that is used to select an entity from all available plot entities in the system. The drop down list when selected will contain the names of all defined plot entities on your system. The browser field also has access to the entity previewer (displayed below) to assist with the selection of the entity. The GuidoEntityBrowserField will understand all the switches that can be used for a GuidoComboBox.
Synopsis
GuidoEntityBrowserField Name Body
Description
The GuidoEntityBrowserField command when processed will define a rectangular text entry region on the form with two triangle icons on the right. The down arrow icon allows the drop down list to be displayed when pressed with the mouse and the right arrow icon will popup the entity previewer when pressed with the mouse. It accepts any of the standard Guido switches and switches as described for GuidoComboBox.
Arguments
Name Name is a unique identifier that you assign and is used to differentiate this object from other Guido objects in the form definition. The name you assign will become the name of a variable in the Tcl interpreter that will contain the value as entered into the field on the form.
Body The body of the field may contain a number of switches to modify the default behaviour of the field. The body begins with an opening curly brace and ends with a closing curly brace. If there is no required body the curly braces {} are required as a place holder for this argument.
Switches Any switch that can be used on a GuidoComboBox may be applied to the GuidoEntityBrowserField. See the reference for GuidoComboBox for further information. Common Guido switches reference
Examples
Example 1
The example form below demonstrates using a number of GuidoEntityBrowserFields to set the required entities for various plotting attributes.
# GuidoEntityBrowserField Example 1
# define the form
set formDef {
GuidoForm form {
-label "Using GuidoEntityBrowserField"
-default_buttons
GuidoEntityBrowserField xEntity {
-label "X axis entity"
-width 20
-format none
-null false
}
GuidoEntityBrowserField yEntity {
-label "Y axis entity"
-width 20
-format none
-null false
}
GuidoEntityBrowserField lineEntity {
-label "Line style entity"
-width 20
-format none
-null false
}
}
}
# Create and run the form
SclCreateGuidoForm formHandle $formDef {}
$formHandle SclRun {}
puts "Entity selections is:"
puts " - X axis = $xEntity"
puts " - Y axis = $yEntity"
puts " - Lines = $lineEntity"
|
See Also
Guido
GuidoComboBox
GuidoField
GuidoComboBox
GuidoForm
Common guido switches