Username: Password:

Guage Plug-in Scripting Reference



Overview

The guage plugin implements dials, knobs and guages of various styles.

There are four major parts to a guage: the dial and face, the ticks and ramp, the numbers, and the needle. Each of these parts can be individually styled.

The dial style controls the main shape of the guage. The dial also has a face, which is a round or wedge shaped area where the other parts reside.

The ticks and the ramp occupy an arc-shaped area inside the dial face. The ramp style controls the appearance of the colored area underneath the ticks.

The numbers display the minimum, maximum, and current value of the guage. A number will appear above or below each tick mark depending on the number style.

The needle style controls the shape of the pointer in the center of the guage.

Messages: nodemove, nodechange, nodeactive

Nodemove is sent when the position of the guage changes.

Nodechange is sent when the min, max, or value of the guage changes.

Nodeactive is sent when the active state of the guage changes.

 

Commands and Functions



activeget, activeset

active TF = activeget(node name $)
activeset(node name $, active TF)

Get or set the active attribute. Inactive guages do not respond to mouse input.



anglesqueezeget, anglesqueezeset

angle squeeze # = anglesqueezeget(node name $)
anglesqueezeset(node name $, angle squeeze #)

Get or set the angle squeeze property. This increases the start angle and reduces the stop angle for the numbers, ticks, and ramp.

Use this property to make more room for numbers on the edges of the dial if necessary.



boltgutterget, boltgutterset

bolt gutter # = boltgutterget(node name $)
boltgutterset(node name $, bolt gutter #)

Get or set the bolt gutter. This value controls the extra space around the outside of the bolts.

You need to specify a bolt size for any bolts to be visible.
See: boltsizeget, boltsizeset



boltsizeget, boltsizeset

bolt size # = boltsizeget(node name $)
boltsizeset(node name $, bolt size #)

Get or set the bolt size. This is the diameter of the bolts on the guage. Use a bolt size of zero for no bolts.
See: boltgutterget, boltgutterset



boundsget, boundsset

rectangle $ = boundsget(node name $)
boundsset(node name $, rectangle $)

Get or set the boundary rectangle of the object.



cornersizeget, cornersizeset

cornersize # = cornersizeget(node name $)
cornersizeset(node name $, cornersize #)

Get or set the corner size.

A minimum corner size is automatically calculated based on the current needle size and needle gutter.

Use this property to increase the corner size beyond the minimum value.



dialcolorget, dialcolorset

dialcolor $ = dialcolorget(node name $)
dialcolorset(node name $, dialcolor $)

Get or set the color of the dial.



dialgutterget, dialgutterset

dial gutter # = dialgutterget(node name $)
dialgutterset(node name $, dial gutter #)

Get or set the dial gutter. This value controls the space available inside the dial face.
See: dialsizeget, dialsizeset



dialsizeget, dialsizeset

dial size # = dialsizeget(node name $)
dialsizeset(node name $, dial size #)

This property controls the size of the dial edge. Use a value of zero for a guage with no edge.
See: dialgutterget, dialgutterset



dialstyleget, dialstyleset

dial style name $ = dialstyleget(node name $)
dialstyleset(node name $, dial style name $)

Get or set the dial style.

Dial styles include: round, square, upleft, upright, lowleft, lowright, triangle, and semicircle.



facecolorget, facecolorset

facecolor $ = facecolorget(node name $)
facecolorset(node name $, facecolor $)

Get or set the color of the dial's face.





fullget, fullset, infoget, infoset

full $ = fullget(node name $)
fullset(node name $, full $)
info $ = infoget(node name $)
infoset(node name $, info $)

Get or set XML data that describes all the settings for this node.

The fullget and fullset routines have a header element with appropriate namespaces, infoget and infoset are an XML snippet for access as a property. Example:

mynode.info.value = 42



handlesget, handlesset

handles TF = handlesget(node name $)
handlesset(node name $, handles TF)

Turn on or off dragable handles for reshaping the node.

This routine is used by the system tool palettes for manual positioning.
See: markersget, markersset, partget, partset



hiliteget, hiliteset

hilite TF = hiliteget(node name $)
hiliteset(node name $, hilite TF)

Get or set the hilite of the guage, which inverts the needle.

This is useful to show mouse control of the guage.
See: hittest


hittest

part name $ = hittest(node name $, hor #, ver #)

This function hit tests the guage to see if it has been clicked on.
See: hiliteset, hiliteget



linecolorget, linecolorset

linecolor $ = linecolorget(node name $)
linecolorset(node name $, linecolor $)

Get or set the color of the line around the dial.



markersget, markersset

markers TF = markersget(node name $)
markersset(node name $, markers TF)

Turn on or off the node outline to show selection.

This routine is used by the system tool palettes to show that a node is selected.
See: handlesset, handlesget, partget, partset



maxget, maxset

max # = maxget(node name $)
maxset(node name $, max #)

Get or set the maximum value of the control.



minget, minset

min # = minget(node name $)
minset(node name $, min #)

Get or set the minimum value of the control.







needlecapcolorget, needlecapcolorset, needlecolorget, needlecolorset, needlelinecolorget, needlelinecolorset

needlecapcolor $ = needlecapcolorget(node name $)
needlecapcolorset(node name $, needlecapcolor $)
needlecolor $ = needlecolorget(node name $)
needlecolorset(node name $, needlecolor $)
needlelinecolor $ = needlelinecolorget(node name $)
needlelinecolorset(node name $, needlelinecolor $)

Get or set various colors for the needle, needle cap, and needle line.



needlegutterget, needlegutterset

needle gutter # = needlegutterget(node name $)
needlegutterset(node name $, needle gutter #)

Get or set the needle gutter. This value pushes the needle closer to the center of the dial.
See: needlesizeget, needlesizeset



needlesizeget, needlesizeset

needle size # = needlesizeget(node name $)
needlesizeset(node name $, needle size #)

This property controls the size of the needle.
See: needlegutterget, needlegutterset



needlestyleget, needlestyleset

needle style name $ = needlestyleget(node name $)
needlestyleset(node name $, needle style name $)

Get or set the needle style.

Needle styles include: none, pointer, compas, stick, arrow, spinner, trident, triangle, line, knob, and ball.

The knob and ball styles look best on a round guage with a large needle size.
See: needlesizeset, needlesizeget



numcolorget, numcolorset

numcolor $ = numcolorget(node name $)
numcolorset(node name $, numcolor $)

Get or set the color of the numbers.



numgutterget, numgutterset

num gutter # = numgutterget(node name $)
numgutterset(node name $, num gutter #)

Get or set the numeric gutter. This value controls the space between the numbers and the ticks.
See: numsizeget, numsizeset



numsizeget, numsizeset

num size # = numsizeget(node name $)
numsizeset(node name $, num size #)

This property controls the arc height of the numbers inside the dial face.
See: numgutterget, numgutterset



numstyleget, numstyleset

num style $ = numstyleget(node name $)
numstyleset(node name $, num style $)

Get or set the num style. Numbers can appear either above or below the ticks depending on their style.

Number styles include: lowlevel, lowrotate, highlevel, highrotate, and none.



partget, partset

part # = partget(node name $, hor #, ver #)
partset(node name $, hor #, ver #, part #)

Get or set the points for an individual handle.
See: markersget, markersset, handlesset, handlesget







rampcolor1get, rampcolor1set, rampcolor2get, rampcolor2set, rampcolor3get, rampcolor3set

rampcolor 1 $ = rampcolor1get(node name $)
rampcolor1set(node name $, rampcolor 1 $)
rampcolor 2 $ = rampcolor2get(node name $)
rampcolor2set(node name $, rampcolor 2 $)
rampcolor 3 $ = rampcolor3get(node name $)
rampcolor3set(node name $, rampcolor 3 $)

Get or set various colors for the ramp.

The ramp style "twoareas" uses ramp colors 1 and 2, plus ramp value 1.

The ramp style "threeareas" uses ramp colors 1, 2, and 3, plus ramp values 1 and 2.

The ramp styles "thermometer" and "shaded" use ramp colors 1 and 2.
See: rampvalue1get, rampvalue1set, rampvalue2get, rampvalue2set



rampstyleget, rampstyleset

ramp style name $ = rampstyleget(node name $)
rampstyleset(node name $, ramp style name $)

Get or set the ramp style, the ramp appears under the tick marks.

Use the ramp to indicated zones of interest for the needle, or to provide a decorative background for the ticks.

Ramp styles include: none, solid, shaded, twoareas, threeareas, and thermometer.





rampvalue1get, rampvalue1set, rampvalue2get, rampvalue2set

ramp value # = rampvalue1get(node name $)
rampvalue1set(node name $, ramp value #)
ramp value # = rampvalue2get(node name $)
rampvalue2set(node name $, ramp value #)

Get or set the ramp values. These values control where two and three part ramps start and stop.

For example, a ramp might have three parts that are green, yellow, and red at certain specified values.
See: rampcolor1set, rampcolor1get, rampcolor2set, rampcolor2get, rampcolor3set, rampcolor3get



shadedget, shadedset

shaded TF = shadedget(node name $)
shadedset(node name $, shaded TF)

Get or set the shaded attribute. Shaded guages have a 3D appearance on the dial and a radial shade on the face.



shadowcolorget, shadowcolorset

shadowcolor $ = shadowcolorget(node name $)
shadowcolorset(node name $, shadowcolor $)

Get or set the shadow color.



shadowget, shadowset

shadow # = shadowget(node name $)
shadowset(node name $, shadow #)

Get or set the amount of drop shadow the guage has.

Use a value of zero for no shadow.



shinyget, shinyset

shiny TF = shinyget(node name $)
shinyset(node name $, shiny TF)

Get or set the shiny attribute. Shiny guages have a glass reflection on the dial face.



tickcolorget, tickcolorset

tickcolor $ = tickcolorget(node name $)
tickcolorset(node name $, tickcolor $)

Get or set the color of the ticks.



tickcountget, tickcountset

tick count # = tickcountget(node name $)
tickcountset(node name $, tick count #)

Get or set the number of ticks. This property controls the number of tick marks and numbers on the guage.
See: tickextraget, tickextraset



tickextraget, tickextraset

tick extra # = tickextraget(node name $)
tickextraset(node name $, tick extra #)

Get or set the tick extra. This is the number of extra decorative marks between the actual tick marks and numbers.
See: tickcountset, tickcountget



ticksizeget, ticksizeset

tick size # = ticksizeget(node name $)
ticksizeset(node name $, tick size #)

This property controls the arc height of the ticks and the ramp inside the dial face.
See: tickgutterget, tickgutterset



tickstyleget, tickstyleset

tick style name $ = tickstyleget(node name $)
tickstyleset(node name $, tick style name $)

Get or set the tick style. Ticks are the marks around the guage next to the numbers.

Tick styles include: none, standard, thickstandard, ringed, thickringed, inside, thickinside, outside, thickoutside, outline, thickoutline, line, and thickline.


trackscroll

trackscroll(node name $, hor #, ver #)

Trackscroll automatically adjusts the value of the guage by tracking mouse input in the needle.

See the library script for tracking the mouse in a guage for an example of how to use this command.



valueget, valueset

value # = valueget(node name $)
valueset(node name $, value #)

Get or set the current value of the control.