::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".
Default values is a list of all possible types.
-collectorLabel value
Specifies collector label.
Default is "Collector".
-dialog value
Indicates if the separate dialog with X,Y,Z locations will be poped. Valid values are "pop" or "nopop".
Default is "nopop".
-orientation value
Specifies orientation of X,Y,Z entries on the dialog. Valid values are "right" and "bottom".
Default is "bottom".
-location value
Specifies number of coordinates, displayed on the dialog. Valid values are 0,1,2 or 3.
Default is 3 (display X,Y and Z).
-xLabel value
Specifies a label for X location.
Default is "X:".
-yLabel value
Specifies a label for Y location.
Default is "Y:".
-zLabel value
Specifies a label for Z location.
Default is "Z:".
-xState value
Specifies a state of an entry of a X location.
Default is "normal".
-yState value
Specifies a state of an entry of a Y location.
Default is "normal".
-zState value
Specifies a state of an entry of a Z location.
Default is "normal".
-xLabelWidth value
Specifies a width of a label for X location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 7.
-yLabelWidth value
Specifies a width of a label for Y location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 7.
-zLabelWidth value
Specifies a width of a label for Z location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 7.
-xEntryWidth value
Specifies a width of an entry for X location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 11.
-yEntryWidth value
Specifies a width of an entry for Y location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 11.
-zEntryWidth value
Specifies a width of an entry for Z location.
Always takes default for vertical alignment regardless of value you supply (Altair's rules).
Default is 11.
-displayCheckBox value
Indicates if the X,Y,Z loc checkbox should be displayed. Valid values are 0 or 1.
If 0, then do not display, X,Y,Z are global by default; if 1, then display a checkbox for user selection.
Default is 0 (global).
-cbLabel value
Specifies a label for "global/local" checkbox.
Default is "Local X,Y,Z".
-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.
Valid values are 0 and 1(for HWAM).
Default is 0.
-calcFunc value
Specifies user's callback to be called after standard notify callback was called.
Default value is "".

Callbacks

EnableCollector value
Enables collector, corresponding popup button, and X,Y,Z entries if any.
Value – collector pathname (a return value of collector widget call).
DisableCollector value
Disables collector, corresponding popup button, and X,Y,Z entries if any.
Value – collector pathname (a return value of collector widget call).

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.

Example of –variable option:
{ 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.