Table XYSlider

XYSlider: a component to pick a couple of x,y values within bounds, that accept keyboard and mouse wheel inputs.

XY slider. Parameters: MinX=-50, MaxX=50, MinY=-30, MaxY=30, OrientationY=ORIENTATION_SOUTH

See
SMDialog:addXYSlider

Summary

FieldTypeSummary
BackgroundColorstringBackground color
CurveColorstringColor of the curve (triangle from 0:0, x:y, 0:x) in RRGGBB format.
DefaultXnumberDefault (factory) value for X.
DefaultYnumberDefault (factory) value for Y.
DisplayValuesMaskstringMask for displaying values, by default "%x, %y"
IsVisibleMinMaxbooleanAre min and max visibles?
IsVisibleValuesbooleanAre x,y values displayed on left top corner?
MaxXnumberMaximum X
MaxYnumberMaximum Y
MinXnumberMinimum X
MinYnumberMinimum Y
OrientationXstringOrientation of X axis, East or West.
OrientationYstringOrientation of Y axis, North or South.
StepXnumberStep between two possible values of X
StepYnumberStep between two possible values of Y
TextColorstringColor of texts (min, max, value) in RRGGBB format.
ValueXnumberX value of the slider
ValueYnumberY value of the slider
axisColorstringColor of x and y axis
Return typeFunction and summary
 OnChange(Dialog dlg, XYSlider xySlider, number valueX, number valueY)
Function fired when values are modified.

Fields

number XYSlider.MinX

Minimum X

number XYSlider.MaxX

Maximum X

number XYSlider.MinY

Minimum Y

number XYSlider.MaxY

Maximum Y

boolean XYSlider.IsVisibleMinMax

Are min and max visibles?

boolean XYSlider.IsVisibleValues

Are x,y values displayed on left top corner?

number XYSlider.StepX

Step between two possible values of X

number XYSlider.StepY

Step between two possible values of Y

number XYSlider.DefaultX

Default (factory) value for X.

A dual click on the slider reset value to this one.

number XYSlider.DefaultY

Default (factory) value for Y.

A dual click on the slider reset value to this one.

number XYSlider.ValueX

X value of the slider

number XYSlider.ValueY

Y value of the slider

string XYSlider.DisplayValuesMask

Mask for displaying values, by default "%x, %y"

string XYSlider.OrientationX

Orientation of X axis, East or West.

Orientation from negative to positive X values. Accepted values are constants in SMGraph.mys, these are ORIENTATION_WEST and ORIENTATION_EAST (default).

string XYSlider.OrientationY

Orientation of Y axis, North or South.

Orientation from negative to positive Y values. Accepted values are constants in SMGraph.mys, these are ORIENTATION_SOUTH and ORIENTATION_NORTH (default).

string XYSlider.CurveColor

Color of the curve (triangle from 0:0, x:y, 0:x) in RRGGBB format.

Default is "2299BB"

string XYSlider.TextColor

Color of texts (min, max, value) in RRGGBB format.

Default is "000000"

string XYSlider.BackgroundColor

Background color

string XYSlider.axisColor

Color of x and y axis

Function

XYSlider.OnChange(Dialog dlg, XYSlider xySlider, number valueX, number valueY)

Function fired when values are modified.

ParameterTypeDefaultDescription
dlgDialog The MyrScript Dialog object
xySliderXYSlider The 2D slider
valueXnumber The new X value of the slider
valueYnumber The new Y value of the slider