::hwat::widgets::collector::Collector
Allows you to create a collector widget and place it in the GUI.
Syntax
::hwat::widgets::collector::Collector pathname collectorID type ?options?
Arguments
- str_pathName
- Collector pathname.
- n_collID
- Unique collector ID.
- type
- Collector type (supports HmMarkCol and HmEntSelCol only).
Widget-Specific Options
- -variable value
- A variable comprised of interlaced list of collector ID and X,Y, and Z variables. See example below.
- -type value
- Specifies collector type. Valid input is a string of valid type(s) separated with space, like "Nodes Elements Components".
- -collectorLabel value
- Specifies collector label.
- -dialog value
- Indicates if the separate dialog with X,Y,Z locations will be poped. Valid values are "pop" or "nopop".
- -orientation value
- Specifies orientation of X,Y,Z entries on the dialog. Valid values are "right" and "bottom".
- -location value
- Specifies number of coordinates, displayed on the dialog. Valid values are 0,1,2 or 3.
- -xLabel value
- Specifies a label for X location.
- -yLabel value
- Specifies a label for Y location.
- -zLabel value
- Specifies a label for Z location.
- -xState value
- Specifies a state of an entry of a X location.
- -yState value
- Specifies a state of an entry of a Y location.
- -zState value
- Specifies a state of an entry of a Z location.
- -xLabelWidth value
- Specifies a width of a label for X location.
- -yLabelWidth value
- Specifies a width of a label for Y location.
- -zLabelWidth value
- Specifies a width of a label for Z location.
- -xEntryWidth value
- Specifies a width of an entry for X location.
- -yEntryWidth value
- Specifies a width of an entry for Y location.
- -zEntryWidth value
- Specifies a width of an entry for Z location.
- -displayCheckBox value
- Indicates if the X,Y,Z loc checkbox should be displayed. Valid values are 0 or 1.
- -cbLabel value
- Specifies a label for "global/local" checkbox.
- -panelMessage value
- Specifies HyperMesh panel message if collector is being used in Macro mode. Default messages is "Select " plus first value of the collector type list.
- -panel value
- Indicates if the collector will be displayed in the separate panel. It is a specific HWAM feature.
- -calcFunc value
- Specifies user's callback to be called after standard notify callback was called.
Callbacks
- EnableCollector value
- Enables collector, corresponding popup button, and X,Y,Z entries if any.
- DisableCollector value
- Disables collector, corresponding popup button, and X,Y,Z entries if any.
Returns
Collector pathname (frame) for external packing.
Example
set coll_frame [ ::hwat::widgets::collector::Collector .coll.nodecoll \
10 HmEntSelCol \
-variable { nodeid ::hwat::nodeid gx ::hwat::gxloc gy ::hwat::gyloc gz ::hwat::gzloc } \
-collectorLabel "Node" \
-dialog nopop \
-orientation bottom \
-location 3 \
-xLabel "Xloc:" \
-yLabel "Yloc:" \
-zLabel "Zloc:" \
-xState normal \
-yState disabled \
-zState normal \
]
# disable a collector
::hwat::widgets::collector::DisableCollector $coll_frame;
# enable a collector
::hwat::widgets::collector::EnableCollector $coll_frame;
or
set coll_frame [::hwat::widgets::collector::Collector \
1 HmMarkCol\
-variable { nodeid ::hwat::compid } \
-dialog nopop \
-location 0 \
-panelMessage "Select a Component:" \
]
Comments
The function call is usually followed by the "pack" command to place the collector frame into a parent frame. Be sure that "n_collID" is a unique ID.
{ nodeid ::nid gx ::xglob gy ::yglob gz ::zglob lx ::lxvar ly ::lyvar lz ::lzvar }
where ::nid, ::xglob
etc. are global variables, defined by the
caller.