/* @license Copyright (C) Exontrol. All rights reserved. */ /////////////////////////////////////////////////////////// (exontrol.Gauge) // // The exontrol.Gauge class provides the following fields (public): // // Layers {object}, gives access to the control's layers collection as an object of exontrol.Gauge.Layers type/ // Listeners {object}, holds a reference to exontrol.Lts which defines the events of the control. // Shortcuts {object}, holds a reference to exontrol.Sts which defines the shortcuts of the control. // // The exontrol.Gauge class defines the following functions: // // SetCanvas(canvas, localCanvas), changes the control's canvas where it runs. // GetCanvas(), gets the canvas element, the control is running on. // SetClientRect(client), defines a client area for the control. // GetClientRect(), returns the control's client area. // Options/GetOptions()/SetOptions(value) {object}, specifies the options of the exontrol.Gauge control // Tfi/GetTfi()/SetTfi(value), specifies an object of {bold,italic,...}/exontrol.TFI type that defines font attributes to display the captions within the control. // Locked/GetLocked()/SetLocked(value) {boolean}, specifies whether the control is locked(protected) or unlocked // ReadOnly/GetReadOnly()/SetReadOnly(value) {boolean}, specifies whether the control is read-only // WheelChange/GetWheelChange()/SetWheelChange(value) {number}, defines the amount the control scrolls when the user rolls the mouse wheel. // bU(), locks invalidating the control until the eU() method is called // eU(), invalidates the control // Refresh(), refreshes the entire control. // Update(callback, thisArg), locks the control's update during the callback, and invalidates the control once the method ends. // Smooth(callback, thisArg), performs a smooth-transition from a layout to another. The smooth-transition goes from the current layout to the new layout generated by the callback. // GetSmooth()/SetSmooth(value), defines the time in ms the control goes from one layout to another. // Cursors/GetCursors()/SetCursors(value) {string}, defines the mouse cursor to display when pointing over different parts of the control. // GetLayers(), gets the control's layers into a string representation (the Layers.Save() builds and gets the control's layers into a string representation) // SetLayers(value), defines the control's layers from a string representation. // The Unshuffle(), restores the layers of the control in case they were shuffled. // Shuffle(value), arranges randomly all layers within the control. // GetDebug(), specifies whether the control displays the layers in debug-mode. // SetDebug(value), shows the control in debug-mode. // GetShowLayers(), indicates the only layers to be shown on the control. // SetShowLayers(value), shows or hides layers within the control. // GetLayerDragAny(), specifies the layer to drag (rotate, move or sweep) once the user clicks anywhere on the control. // SetLayerDragAny(value), sets the layer to drag (rotate, move or sweep) once the user clicks anywhere on the control. // // LayerAutoSize/GetLayerAutoSize()/SetLayerAutoSize(value), specifies the index or the key of the layer that determines the size to display all layers. // LayerOfValue/GetLayerOfValue()/SetLayerOfValue(value), specifies the index or the key of the layer whose value determines the control's Value property. // Value/GetValue()/SetValue(value), specifies the control's value // // The exontrol.Gauge class provides the following events (through oLts): // // "onchange", occurs when the layer's value is changed. // // oEvent {object}, indicates an object of exontrol.Gauge.Layer type whose value/offset-x/offset-y/rotation-angle has been changed. // // "onclick", occurs once the user clicks or double-clicks a selectable layer. The onclick's parameter is: // // oEvent {object}, specifies an object of {layer,dblClick,button,modifiers} type, that holds information about the layer being clicked. // // oEvent.layer {object}, specifies null or an object of exontrol.Gauge.Layer type that indicates the layer being clicked // oEvent.dblClick {boolean}, indicates whether the user clicks or double-clicks the layer // oEvent.button {number}, indicates which button is pressed while clicking the layer as 1 (left), 2 (right) or 4 (middle) // oEvent.modifiers {number}, specifies a combination of 1, 2, 4 and 16 according with modifier keys (ALT, CTRL, META and SHIFT), or 0 if no modifier keys // // "onanchorclick", (@since 2.2) occurs once the user clicks an anchor element (the ex-HTML part marks an anchor or hyperlink element). The onanchorclick's parameter is: // // oEvent {object}, specifies an object of {id,options} type, that holds information about the anchor being clicked. // // oEvent.id {string}, specifies null or the identifier of the anchor being clicked // oEvent.options {string}, specifies null or the options of the anchor being clicked // // "ondragstart", notifies that the user starts dragging the layer. The ondragstart's parameter is: // // oEvent {object}, specifies an object of {layer,cancel,event} type, that holds information about the layer that starts dragging and the event that generates the drag-event. // // oEvent.layer {object}, specifies an object of exontrol.Gauge.Layer type that indicates the layer being dragged // oEvent.cancel {boolean}, indicates whether the drag operation should be canceled // oEvent.event {object}, indicates an object of MouseEvent/TouchEvent type that generated the operation // // "ondrag", occurs once the user drags the layer to a new position. The ondrag's parameter is: // // oEvent {object}, specifies an object of {layer,event} type, that holds information about the layer being dragging and the event that generates the drag-event. // // oEvent.layer {object}, specifies an object of exontrol.Gauge.Layer type that indicates the layer being dragged // oEvent.event {object}, indicates an object of MouseEvent/TouchEvent type that generated the operation // // "ondragend", notifies drag operation ends. The ondragend's parameter is: // // oEvent {object}, specifies an object of {layer,event} type, that holds information about the layer being dragging and the event that generates the drag-event. // // oEvent.layer {object}, specifies an object of exontrol.Gauge.Layer type that indicates the layer being dragged // oEvent.event {object}, indicates an object of MouseEvent/TouchEvent type that generated the operation // // "onlayerin", occurs once the cursor enters the layer. // // oEvent {object}, indicates an object of exontrol.Gauge.Layer type. // // "onlayerout", occurs once the cursor leaves the layer. // // oEvent {object}, indicates an object of exontrol.Gauge.Layer type. // /////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////// (exontrol.Gauge.Layers) // // The exontrol.Gauge.Layers object holds a collection of layers for the gauge control. Any layer can display unlimited opaque / transparent graphics, // HTML text, can be visible, selectable, dragable and so on. Any layer can change its position in the layers collection as well. The Layer can // change its brightness, contrast, grayscale or transparency as well. // // The exontrol.Gauge.Layers objects implements the following methods: // // Count/GetCount()/SetCount(value), specifies the number of layers // Item(key), returns a specific Layer of the Layers collection // Add(key), creates and adds/gets a Layer object to the collection and returns a reference to the newly created object // Remove(key), removes a specific member from the Layers collection. // Clear(), removes all objects within the collection // // Load(value), loads the layers from a string-representation // Save(), loads the layers from a string-representation // /////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////// (exontrol.Gauge.Layer) // // The exontrol.Gauge.Layer object holds a layer of the Gauge control. The Layer object holds a collection of pictures // and HTML captions to be displayed on a viewable layer. Any layer can be visible, selectable or dragable. Any layer // can be moved, rotated or clipped. // // The exontrol.Gauge.Layer object implements the following methods: // // Index/GetIndex()/SetKey(value) {number}, retrieves the layer's index // Key/GetKey()/SetKey(value) {any}, gets or sets the layer's key // Position/GetPosition()/SetPosition(value) {number}, gets or sets the layer's position // Visible/GetVisible()/SetVisible(value) {boolean}, specifies whether the layer is visible or hidden // Selectable/GetSelectable()/SetSelectable(value) {boolean}, specifies whether the layer is selectable or un-selectable // Back/GetBack()/SetBack(value) {string}, specifies the layer's background as a name of an HTML picture or a CSS color // Fore/GetFore()/SetFore(value) {string}, specifies the layer's foreground as HTML caption // // OnDrag/GetOnDrag()/SetOnDrag(value) {number}, gets or sets the layer's transformation once the user drags it // Value/GetValue()/SetValue(value) {number}, gets or sets the layer's value // Idem/GetIdem()/SetIdem(value) {any}, ensures that the layer's offset and rotation-angle is equal for all idem layers (separated by comma character). // // The following methods(properties) moves/resizes the layer: // // Left/GetLeft()/SetLeft(value) {string}, specifies the expression relative to the view, to determine the x-position to show the current layer on the control // Top/GetTop()/SetTop(value) {string}, specifies the expression relative to the view, to determine the y-position to show the current layer on the control. // Width/GetWidth()/SetWidth(value) {string}, specifies the expression relative to the view, to determine the width to show the current layer on the control. // Height/GetHeight()/SetHeight(value) {string}, specifies the expression relative to the view, to determine the height to show the current layer on the control. // DefaultOffsetX/GetDefaultOffsetX()/SetDefaultOffsetX(value) {number}, gets or sets a value that indicates the default x-offset of the layer. // DefaultOffsetY/GetDefaultOffsetY()/SetDefaultOffsetY(value) {number}, gets or sets a value that indicates the default y-offset of the layer. // OffsetX/GetOffsetX()/SetOffsetX(value) {number}, gets or sets a value that indicates the x-offset of the layer. // OffsetY/GetOffsetY()/SetOffsetY(value) {number}, gets or sets a value that indicates the y-offset of the layer. // OffsetXValid/GetOffsetXValid()/SetOffsetXValid(value) {string}, validates the x-offset value of the layer. // OffsetYValid/GetOffsetYValid()/SetOffsetYValid(value) {string}, validates the y-offset value of the layer. // ValueToOffsetX/GetValueToOffsetX()/SetValueToOffsetX(value) {string}, specifies the expression to convert the value to x-offset. // ValueToOffsetY/GetValueToOffsetY()/SetValueToOffsetY(value) {string}, specifies the expression to convert the value to y-offset. // OffsetToValue/GetOffsetToValue()/SetOffsetToValue(value) {string}, specifies the expression to convert the offsetx,offsety to value. // // The following methods(properties) rotates the layer: // // DefaultRotateAngle/GetDefaultRotateAngle()/SetDefaultRotateAngle(value) {number}, specifies the default angle to rotate the layer (degree) // RotateAngle/GetRotateAngle()/SetRotateAngle(value) {number}, specifies the angle to rotate the layer (degree) // RotateAngleValid/GetRotateAngleValid()/SetRotateAngleValid(value) {string}, validates the rotation angle of the layer // RotateCenterX/GetRotateCenterX()/SetRotateCenterX(value) {string}, indicates the expression that determines the x-origin of the rotation point relative to the RotateCenterLayer layer. // RotateCenterY/GetRotateCenterY()/SetRotateCenterY(value) {string}, indicates the expression that determines the y-origin of the rotation point relative to the RotateCenterLayer layer. // RotateCenterLayer/GetRotateCenterLayer()/SetRotateCenterLayer(value) {any}, indicates the index/key of the layer the rotation is around. If -1, the rotation is relative to the current layer. // RotateAngleToValue/GetRotateAngleToValue()/SetRotateAngleToValue(value) {string}, specifies the expression to convert the rotating angle to value. // ValueToRotateAngle/GetValueToRotateAngle()/SetValueToRotateAngle(value) {string}, specifies the expression to convert the value to rotating angle. // RotamoveCenterX/GetRotamoveCenterX() {number}, specifies the x-position of the layer's center, while the layer's drag operation is exDoRotamove. // RotamoveCenterY/GetRotamoveCenterY() {number}, specifies the y-position of the layer's center, while the layer's drag operation is exDoRotamove. // RotamoveOffsetX/GetRotamoveOffsetX() {number}, Specifies the x-offset of the layer, while the layer's drag operation is exDoRotamove. // RotamoveOffsetY/GetRotamoveOffsetY() {number}, Specifies the y-offset of the layer, while the layer's drag operation is exDoRotamove. // // The following methods(properties) clips the layer: // // RotateClip/GetRotateClip()/SetRotateClip(value) {boolean}, specifies whether the layer's clipping region is rotated once the layer is rotated. // Clip/GetClip() {object}, gets access to the layer's clip object of exontrol.Gauge.LC type. // // The following methods(properties) changes the visual appearance of the layer: // // Grayscale/GetGrayscale()/SetGrayscale(value) {string}, sets the percent value / expression to convert the layer to grayscale. // Transparency/GetTransparency()/SetTransparency(value) {string}, sets the percent value / expression of the transparency to display the layer. // Brightness/GetBrightness(), gets access to the layer's brightness object // Contrast/GetContrast(), gets access to the layer's contrast object // /////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////// (exontrol.Gauge.LC) (exontrol.Gauge.LayerClip) // // The exontrol.Gauge.LC object defines the clipping the layer can apply to. // // The exontrol.Gauge.LC object implements the following methods: // // Type,GetType(),SetType(value), specifies the type of the clipping the current layer supports. // Value,GetValue(),SetValue(value), specifies the clip's value. // OffsetX/GetOffsetX()/SetOffsetX(value) {string}, specifies the x-offset expression / value of the clip, relative to the layer. // OffsetY/GetOffsetY()/SetOffsetY(value) {string}, specifies the y-offset expression / value of the clip, relative to the layer. // // The exontrol.Gauge.LC object implements the following methods: // // Left/GetLeft()/SetLeft(value) {string}, specifies the left position / expression of the clip, relative to the layer. // Top/GetTop()/SetTop(value) {string}, specifies the top position / expression of the clip, relative to the layer. // Width/GetWidth()/SetWidth(value) {string}, specifies the width value / expression of the clip, relative to the layer. // Height/GetHeight()/SetHeight(value) {string}, specifies the height value / expression of the clip, relative to the layer. // // The exontrol.Gauge.LC object implements the following methods ("RoundRect"): // // RoundRadiusX/GetRoundRadiusX()/SetRoundRadiusX(value) {string}, specifies the x-radius value / expression of the round corner, relative to the layer. // RoundRadiusY/GetRoundRadiusY()/SetRoundRadiusY(value) {string}, specifies the y-radius value / expression of the round corner, relative to the layer. // // The exontrol.Gauge.LC object implements the following methods ("Ellipse", "Pie"): // // RadiusX/GetRadiusX()/SetRadiusX(value) {string}, specifies the x-radius value / expression of the clip, relative to the layer, relative to the layer. // RadiusY/GetRadiusY()/SetRadiusY(value) {string}, specifies the y-radius value / expression of the clip, relative to the layer, relative to the layer. // CenterX/GetCenterX()/SetCenterX(value) {string}, specifies the x-position / expression of the center of the clip, relative to the layer. // CenterY/GetCenterY()/SetCenterY(value) {string}, specifies the y-position / expression of the center of the clip, relative to the layer. // // The exontrol.Gauge.LC object implements the following methods ("Pie"): // // StartAngle/GetStartAngle()/SetStartAngle(value) {string}, specifies the starting angle (degree) relative to the y-axis. // SweepAngle/GetSweepAngle()/SetSweepAngle(value) {string}, specifies sweep angle (degree) relative to the starting angle. // /////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////// (exontrol.Def.Gauge) // // The exontrol.Def.Gauge namespace provides definitions for different objects, primitives, objects of exontrol.Gauge object // // The exontrol.Def.Gauge namespace provides the following fields: // // tfi {(string|object)}, holds the font attributes for captions within the control. The tfi field can be defined using a string representation such as "b monospace 16" or as an object such as {bold: true, fontName: "monospace", fontSize: 16}. // locked {boolean}, indicates whether the control is locked(protected) or unlocked // wheelChange {number}, specifies the amount the control scrolls when the user rolls the mouse wheel. // layers {string}, defines the layers of the control from a string-representation // layerAutoSize {number/string}, specifies the index or the key of the layer that determines the size to display all layers // layerOfValue {number/string}, specifies the index or the key of the layer whose value determines the control's Value property // layerDragAny {number/string}, specifies the layer to drag (rotate, move or sweep) once the user clicks anywhere on the control. // value {number}, indicates the control's value // debug {boolean}, indicates whether the control displays the layers in debug-mode // showLayers {string}, indicates the only layers to be shown on the control. // /////////////////////////////////////////////////////////// /** * @description The exontrol.Def.Gauge namespace provides definitions for different objects, primitives, objects of exontrol.Gauge object */ exontrol.Def.Gauge = { /** * @description The tfi field applies font attributes to captions within the control. The tfi field can be defined using a string representation such as "b monospace 16" or as an object such as {bold: true, fontName: "monospace", fontSize: 16}. * * The tfi field as string supports any of the following keywords (each keyword can be specified using first letters only such as "b" for "bold) separated by space characters: * * bold, displays the text in bold (equivalent of tag) * italic, displays the text in italics (equivalent of tag) * underline, underlines the text (equivalent of tag) * strikeout, specifies whether the text is strike-through (equivalent of tag) * , specifies the font's family (equivalent of tag) * , specifies the size of the font (equivalent of tag) * , specifies the text's foreground color (equivalent of tag) * , specifies the text's background color (equivalent of tag) * , defines the text's shadow (equivalent of tag) * , shows the text with outlined characters (CSScolor) (equivalent of tag) * , defines a gradient text (equivalent of tag) * * Any other word within the tfi field that's not recognized as a keyword is interpreted as: * * name of the font (not a number), specifies the font's family (equivalent of tag) * size of the font (number), specifies the size of the font (equivalent of tag) * * The tfi field as object supports any of the following fields: * * bold {boolean}, displays the text in bold (equivalent of tag) * italic {boolean}, displays the text in italics (equivalent of tag) * underline {boolean}, underlines the text (equivalent of tag) * strikeout {boolean}, specifies whether the text is strike-through (equivalent of tag) * fontName {string}, specifies the font's family (equivalent of tag) * fontSize {number}, specifies the size of the font (equivalent of tag) * fgColor {string}, specifies the text's foreground color (CSScolor) (equivalent of tag) * bgColor {string}, specifies the text's background color (CSScolor) (equivalent of tag) * shaColor {object}, specifies an object of {color, width, offset} type that defines the text's shadow (equivalent of tag), where: * color {string}, defines the color of the text's shadow (CSScolor) * width {number}, defines the size of the text's shadow * offset {number}, defines the offset to show the text's shadow relative to the text * outColor {string}, shows the text with outlined characters (CSScolor) (equivalent of tag) * graColor {object}, specifies an object of {color, mode, blend} type that defines a gradient text (equivalent of tag), where: * color {string}, defines the gradient-color (CSScolor) * mode {number}, defines the gradient mode as a value between 0 and 4 * blend {number}, defines the gradient blend as a value between 0 and 1 * * CSSColor or CSS legal color values can be specified by the following methods: * * Hexadecimal colors, is specified with: #RRGGBB, where the RR (red), GG (green) and BB (blue) hexadecimal integers specify the components of the color. All values must be between 00 and FF. For example, #0000ff value is rendered as blue, because the blue component is set to its highest value (ff) and the others are set to 00. * Hexadecimal colors with transparency, is specified with: #RRGGBBAA, where AA (alpha) value must be between 00 and FF. For example, #0000ff80 defines a semi-transparent blue. * RGB colors, is specified with the RGB(red, green, blue) function. Each parameter (red, green, and blue) defines the intensity of the color and can be an integer between 0 and 255. For example, rgb(0,0,255) defines the blue color. * RGBA colors, are an extension of RGB color values with an alpha channel as RGBA(red, green, blue, alpha) function, where the alpha parameter is a number between 0.0 (fully transparent) and 1.0 (fully opaque). For example, rgba(0,0,255,0.5) defines a semi-transparent blue. * HSL colors, is specified with the HSL(hue, saturation, lightness) function, where hue is a degree on the color wheel (from 0 to 360) - 0 (or 360) is red, 120 is green, 240 is blue. saturation is a percentage value; 0% means a shade of gray and 100% is the full color. lightness is also a percentage; 0% is black, 100% is white. HSL stands for hue, saturation, and lightness - and represents a cylindrical-coordinate representation of colors. For example, hsl(240, 100%, 50%) defines the blue color. * HSLA colors, are an extension of HSL color values with an alpha channel - which specifies the opacity of the object as HSLA(hue, saturation, lightness, alpha) function, where alpha parameter is a number between 0.0 (fully transparent) and 1.0 (fully opaque). For example, hsla(240, 100%, 50%,0.5) defines a semi-transparent blue. * Predefined/Cross-browser color names, 140 color names are predefined in the HTML and CSS color specification. For example, blue defines the blue color. * * @type {(string|object)} * @example * * null {null}, the tfi field is ignored * "bold monospace 16" {string}, defines Monospace font of 16px height, bold * {bold: true, fontName: "monospace", fontSize: 16} {object}, defines Monospace font of 16px height, bold */ tfi: null, /** * @description The formatText field specifies the format to display the layer's caption. * @type {exontrol.DrawTextFormatEnum} A combination of one or more exontrol.DrawTextFormatEnum flags that defines the format to show the layer's caption. * * The exontrol.DrawTextFormatEnum type support the following flags: * * exTextAlignTop (0x00), justifies the text to the top of the rectangle * exTextAlignLeft (0x00), aligns text to the left * exTextAlignCenter (0x01), centers text horizontally in the rectangle * exTextAlignRight (0x02), aligns text to the right * exTextAlignVCenter (0x04), centers text vertically * exTextAlignBottom (0x08), justifies the text to the bottom of the rectangle. * exTextAlignMask (0x0F), specifies the mask for text's alignment. * exTextWordBreak (0x10), breaks words. Lines are automatically broken between words if a word would extend past the edge of the rectangle specified by the lpRect parameter. A carriage return-line feed sequence also breaks the line. If this is not specified, output is on one line. * exTextSingleLine (0x20), displays text on a single line only. Carriage returns and line feeds do not break the line. * exTextExpandTabs (0x40), expands tab characters. The default number of characters per tab is eight. * exPlainText (0x80), treats the text as plain text. * exTextNoClip (0x0100), draws without clipping. * exHTMLTextNoColors (0x0200), ignores the and tags. * exTextCalcRect (0x0400), determines the width and height of the text. * exHTMLTextNoTags (0x0800), ignores all HTML tags. * exTextPathEllipsis (0x4000), for displayed text, replaces characters in the middle of the string with ellipses so that the result fits in the specified rectangle. If the string contains backslash (\) characters, exTextPathEllipsis preserves as much as possible of the text after the last backslash. * exTextEndEllipsis (0x8000), for displayed text, if the end of a string does not fit in the rectangle, it is truncated and ellipses are added. If a word that is not at the end of the string goes beyond the limits of the rectangle, it is truncated without ellipses. * exTextWordEllipsis (0x040000), truncates any word that does not fit in the rectangle and adds ellipses. * * @example * * null {null}, centers the caption * 32 or exontrol.DrawTextFormatEnum.exTextSingleLine {number}, defines a single-line caption * 0x2A or exontrol.DrawTextFormatEnum.exTextSingleLine | exontrol.DrawTextFormatEnum.exTextAlignRight | exontrol.DrawTextFormatEnum.exTextAlignBottom {number}, defines a single-line caption right/bottom-aligned */ formatText: exontrol.DrawTextFormatEnum.exTextAlignCenter | exontrol.DrawTextFormatEnum.exTextAlignVCenter, /** * @description The locked field indicates whether the control is locked(protected) or unlocked * @type {boolean} Specifies whether the control is protected. * @example * * false {boolean}, unlocks the control (can select any layer) * true {boolean}, locks the control (can't select any layer) */ locked: false, /** * @description The readOnly field indicates whether the control is read-only (identichal with locked option) * @type {boolean} * @example * * false {boolean}, unlocks the control (can select any layer) * true {boolean}, locks the control (can't select any layer) */ readOnly: false, /** * @description The wheelChange field specifies the amount the control scrolls when the user rolls the mouse wheel. * @type {number} Specifies the amount the control scrolls when the user rolls the mouse wheel. * @example * * 0 {number}, locks any action the mouse's wheel performs * 5 {number}, increases the control's value by 5 once the user rotates the mouse wheel */ wheelChange: 1, /** * @description The smooth field defines the time in ms the control goes from one layout to another. * @type {number} Indicates the time in ms the control goes from one layout to another. * @example * * 0 {number}, no smooth changes once the control goes from a layout to another * 125 {number}, specifies that a smooth-transition is performed from a layout to another for 125 ms. */ smooth: 125, /** * @description The cursors field specifies the mouse cursor to be displayed when pointing over a part of the control. * @type {string} Specifies the mouse cursor to be displayed when pointing over a part of the control. * * The format of cursors property is: * * "cursor(part),cursor(part),..." * * where: * * "cursor", defines the CSS mouse cursor to display while cursor hovers the part * "part", defines the name of the part the cursor is applied on (as defined bellow) * * The cursors property supports any of the following parts: * * "dable" (selectable and dragable layer), defines the cursor for selectable and dragable layers * "sable" (selectable layer), defines the cursor for selectable layers * "anchor" (hyperlink), defines the mouse-cursor when the mouse pointer hovers the anchor (the ex-HTML part marks an anchor or hyperlink element) (@since 2.2) * * @example * * null {null}, no mouse cursor is provided. * "crosshair(dable)" {string}, indicates that the "crosshair" mouse cursor is shown once the cursor hovers any "dable" (selectable and dragable) layers */ cursors: "pointer(dable,anchor)", /** * @description The layers field defines the layers of the control from a string-representation * @type {string} Defines the control's layers from a string-representation (separated by comma character). * * The layers field defines the control's layers from a string-representation in the following format: * * "back[flag=value]...[flag=value],...,back[flag=value]...[flag=value],..." * * where: * * "back", (Back/GetBack()/SetBack() methods of exontrol.RadialMenu.Layer) could be: * * "" {empty string} (no layer background provided) * "image" {picture's name}, defines the name of a picture previously added using the exontrol.HP.Add(name,...) method. For instance, "pic" indciates that the HTML Picture named "pic" is stretched on the layer's background. * "color" {string}, indicates a CSS color to be displayed on the layer's background. For instance, "red", "rgba(255,0,0,1)", "#FF0000" indicates a layer full-filed with a solid red-color. * * The flag can be any of the following * * [key] {string}, specifies the layer's key (Key/GetKey()/SetKey(value) methods of exontrol.Gauge.Layer). The Layers.Item() method retrieves the control's layer giving its index or key. If the key is not specified, the layer's back is considered its key. For instance [key=background] indicates that the layer's key is "background", so you can always request this layer using the Layers.Item("background") method. * [vis] {0,1}, indicates whether the layer is visible(1) or hidden(0) (Visible/GetVisible()/SetVisible(value) methods of exontrol.Gauge.Layer). By default, all layers are visible(1). For instance [vis=0] specifies that the layer is hidden. * [pos] {number, 0-based}, specifies the layer's position as 0-based (Position/GetPosition()/SetPosition(value) methods of exontrol.Gauge.Layer). By default, the position of the layer on the control's background is 0. For instance [pos=1] specifies that the layer should be shown the second. * [sel] {0,1}, indicates whether the layer is selectable, so the user can drag it (Selectable/GetSelectable()/SetSelectable(value) methods of exontrol.Gauge.Layer). By default, all layers are selectable. For instance [sel=0] indicates that user can not select, drag, rotate or move by drag the layer. * [fore] {string}, specifies the layer's foreground as an HTML caption (can be an expression with "value" keyword which indicates the control's value) (Fore/GetFore()/SetFore(value) methods of exontrol.Gauge.Layer). For instance [fore=caption] displays the caption in bold onto the layer's foreground, or "[fore=`` + value]" displays the control's value with a larger font. * [left] {string}, specifies the expression relative to the view, to determine the x-position to show the layer on the control (Left/GetLeft()/SetLeft(value) methods of exontrol.Gauge.Layer). The [left] flag supports the "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords. For instance [left=128] specifies 128-pixels, while [left=width/2] half of the view or x-center of the control's view. * [top] {string}, specifies the expression relative to the view, to determine the y-position to show the layer on the control (Top/GetTop()/SetTop(value) methods of exontrol.Gauge.Layer). The [top] flag supports the "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords. For instance [top=128] specifies 128-pixels, while [top=height/2] half of the view or y-center of the control's view. * [width] {string}, specifies the expression relative to the view, to determine the width to display the entire-layer on the control (Width/GetWidth()/SetWidth(value) methods of exontrol.Gauge.Layer). The [width] flag supports the "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords. For instance [width=128] specifies 128-pixels wide, while [width=width/4] quarter of the view. * [height] {string}, specifies the expression relative to the view, to determine the height to display the entire-layer on the control (Height/GetHeight()/SetHeight(value) methods of exontrol.Gauge.Layer). The [height] flag supports the "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords. For instance [height=128] specifies 128-pixels wide, while [height=height/4] quarter of the view. * [defX] {number}, indicates the default x-offset of the layer (DefaultOffsetX/GetDefaultOffsetX()/SetDefaultOffsetX(value) methods of exontrol.Gauge.Layer). For instance, [defX=-32] specifies that the layer is displayed left to 32-pixels of its default position. * [defY] {number}, indicates the default y-offset of the layer (DefaultOffsetY/GetDefaultOffsetY()/SetDefaultOffsetY(value) methods of exontrol.Gauge.Layer). For instance, [defY=-32] specifies that the layer is displayed to to 32-pixels of its default position. * [x] {number}, indicates the x-offset of the layer (OffsetX/GetOffsetX()/SetOffsetX(value) methods of exontrol.Gauge.Layer). For instance, [x=-32] specifies that the layer is displayed left to 32-pixels of its default position. * [y] {number}, indicates the y-offset of the layer (OffsetY/GetOffsetY()/SetOffsetY(value) methods of exontrol.Gauge.Layer). For instance, [y=-32] specifies that the layer is displayed to to 32-pixels of its default position. * [drag] {"move","rotate" or "rotamove"}, indicates the transformation ("move","rotate" or "rotamove") of the layer once the user drags it (OnDrag/GetOnDrag()/SetOnDrag(value) methods of exontrol.Gauge.Layer). For instance, [drag=rotate] indicates that the layer is rotated once the user drags it. * [value] {number}, specifies the layer's value (Value/GetValue()/SetValue(value) methods of exontrol.Gauge.Layer). For instance, [value=15] changes the layer's value to 15. The [v2a], [v2x] and [v2y] flags are used to converts the layer's value to rotation-angle/x-offset/y-offset. * [idem] {string}, ensures that the layer's offset and rotation-angle is equal for all idem layers (separated by comma character) (Idem/GetIdem()/SetIdem(value) methods of exontrol.Gauge.Layer). For instance, [idem=o1,o5] indicates that the current layer, o1 and o5 have the same offset and rotation-angle. * [xValid] {string}, validates the x-offset value of the layer using an expression that supports: "value" (specifies the x-offset/y-offset of the layer), "x" (specifies the x-offset of the layer), "y" (specifies the y-offset of the layer), "lwidth" (specifies the width in pixels of the layer's view), "lheight" (specifies the height in pixels of the layer's view), "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords (OffsetXValid/GetOffsetXValid()/SetOffsetXValid(value) methods of exontrol.Gauge.Layer). For instance, [xValid=(value MIN 0 MAX 48)] ensures that the layer's x-offset (OffsetX) is always between 0 and 48. * [yValid] {string}, validates the y-offset value of the layer using an expression that supports: "value" (specifies the x-offset/y-offset of the layer), "x" (specifies the x-offset of the layer), "y" (specifies the y-offset of the layer), "lwidth" (specifies the width in pixels of the layer's view), "lheight" (specifies the height in pixels of the layer's view), "width" (specifies the width in pixels of the control's view) and "height" (specifies the height in pixels of the control's view) keywords (OffsetYValid/GetOffsetYValid()/SetOffsetYValid(value) methods of exontrol.Gauge.Layer). For instance, [yValid=(value MIN -height/2 MAX height/2)] ensures that the layer's y-offset (OffsetY) is always between -height/2 and height/2. * [v2x] {string}, specifies the expression to convert the value to x-offset. The expression supports: "value" (specifies the layer's value) keyword (ValueToOffsetX/GetValueToOffsetX()/SetValueToOffsetX(value) methods of exontrol.Gauge.Layer). For instance, [v2x=(value=0) ? 0 : 48] specifies that the x-offset of the layer is 0, if the layer's value is 0 else it is 48. * [v2y] {string}, specifies the expression to convert the value to y-offset. The expression supports: "value" (specifies the layer's value) keyword (ValueToOffsetY/GetValueToOffsetY()/SetValueToOffsetY(value) methods of exontrol.Gauge.Layer). For instance, [v2y=(value=0) ? 0 : 48] specifies that the y-offset of the layer is 0, if the layer's value is 0 else it is 48. * [o2v] {string}, specifies the expression to convert the x-offset, y-offset to value. The expression supports: "value", "x", "offsetx" indicates the layer's x-offset property, "y", "offsety" indicates the layer's y-offset property keywords (OffsetToValue/GetOffsetToValue()/SetOffsetToValue(value) methods of exontrol.Gauge.Layer). For instance, [o2v=x+y/2] specifies that the layer's value is adding x-offset + y-offset divided by 2 * [defA] {number}, specifies the default angle (degree) to rotate the layer (DefaultRotateAngle/GetDefaultRotateAngle()/SetDefaultRotateAngle(value) methods of exontrol.Gauge.Layer). For instance, [defA=45] specifies that the default rotation-angle for the layer is 45 degree. * [a] {number}, specifies the angle (degree) to rotate the layer (RotateAngle/GetRotateAngle()/SetRotateAngle(value) methods of exontrol.Gauge.Layer). For instance, [a=90] specifies that the layer's rotation-angle is 90 degree. * [aValid] {string}, validates the layer's rotation angle using an expression that supports: "value" (indicates the cumulative rotation angle) keyword (RotateAngleValid/GetRotateAngleValid()/SetRotateAngleValid(value) methods of exontrol.Gauge.Layer). For instance, [aValid=value < 90 ? value : (value < 180 ? 90 : ( value < 270 ? 270 : value ))] ensures that the layer's rotation-angle is between 90 and 270. * [xCenter] {string}, indicates the expression that determines the x-origin of the rotation point relative to the RotateCenterLayer layer. The expression supports: "lwidth" (indicates the width in pixels of the layer), "width" (specifies the width in pixels of the view / control), "lheight" (indicates the height in pixels of the layer) and "height" (specifies the height in pixels of the view / control) keywords (RotateCenterX/GetRotateCenterX()/SetRotateCenterX(value) methods of exontrol.Gauge.Layer). For instance, [xCenter=lwidth/2-3] defines the rotation-center 3-pixels to the left of the center of the view. * [yCenter] {string}, indicates the expression that determines the y-origin of the rotation point relative to the RotateCenterLayer layer. The expression supports: "lwidth" (indicates the width in pixels of the layer), "width" (specifies the width in pixels of the view / control), "lheight" (indicates the height in pixels of the layer) and "height" (specifies the height in pixels of the view / control) keywords (RotateCenterX/GetRotateCenterX()/SetRotateCenterX(value) methods of exontrol.Gauge.Layer). For instance, [yCenter=lheight/2+23] defines the rotation-center 23-pixels lower of the center of the view. * [clayer] {number/string}, indicates the index or key of the layer the rotation is around. If -1, the rotation is relative to the current layer. For instance, [clayer=-1] ensures that the current layer is rotated around itself. * [a2v] {string}, specifies the expression to convert the rotating angle to value. The expression supports: "value" (indicates the layer's rotation-angle) keyword (RotateAngleToValue/GetRotateAngleToValue()/SetRotateAngleToValue(value) methods of exontrol.Gauge.Layer). For instance, [a2v=round(value/360*100)] converts the layer's rotation angle to a value between 0 and 100. * [v2a] {string}, specifies the expression to convert the value to rotating angle. The expression supports: "value" (indicates the layer's value) keyword (ValueToRotateAngle/GetValueToRotateAngle()/SetValueToRotateAngle(value) methods of exontrol.Gauge.Layer). For instance, [v2a=value/100*360] converts the value between 0 and 100 to a rotation angle between 0 and 360 degree. * [grayscale] {any}, sets the percent value / expression to convert the layer to grayscale. The grayscale can be a number beween 0 and 100, or a string to define an expression. The expression supports: "value" (indicates the control's value) keyword (Grayscale/GetGrayscale()/SetGrayscale(value) methods of exontrol.Gauge.Layer). For instance, [grayscale=100] displays the layer in full-grayscale, or [grayscale=value] specifies that the layer's grayscale percent is indicated by the control's value (ex: the control's value is 25, the layer's grayscale will be 25%) * [transparency] {any}, sets the percent value / expression of the transparency to display the layer. The transparency can be a number beween 0 and 100, or a string to define an expression. The expression supports: "value" (indicates the control's value) keyword (Transparency/GetTransparency()/SetTransparency(value) methods of exontrol.Gauge.Layer). For instance, [transparency=50] displays the layer half-transparent, or [transparency=value] specifies that the layer's transparency percent is indicated by the control's value (ex: the control's value is 75, the layer is displayed 75% transparent) * [rotateclip] {0,1}, specifies whether the layer's clipping region is rotated once the layer is rotated (RotateClip/GetRotateClip()/SetRotateClip(value) methods of exontrol.Gauge.Layer). The [rotateclip] has effect only if the [clip] flag is present for the layer. For instance [rotateClip=1] specifies that the layer's clipping region is rotated once the layer itself is rotated. * [brightness.red] {string}, specifies the percent value / expression of the red-chanel. The expression supports: "value" (indicates the layer's value) keyword (Red/GetRed()/SetRed(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [brightness.red=100] adds 100% more red, or [brightness.red=50+value/2] applies more red based on the control's value. * [brightness.green] {string}, specifies the percent value / expression of the green-chanel. The expression supports: "value" (indicates the layer's value) keyword (Green/GetGreen()/SetGreen(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [brightness.green=100] adds 100% more green, or [brightness.green=50+value/2] applies more green based on the control's value. * [brightness.blue] {string}, specifies the percent value / expression of the blue-chanel. The expression supports: "value" (indicates the layer's value) keyword (Blue/GetBlue()/SetBlue(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [brightness.blue=100] adds 100% more blue, or [brightness.blue=50+value/2] applies more blue based on the control's value. * [contrast.red] {string}, specifies the percent value / expression of the red-chanel. The expression supports: "value" (indicates the layer's value) keyword (Red/GetRed()/SetRed(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [contrast.red=100] adds 100% more red, or [contrast.red=50+value/2] applies more red based on the control's value. * [contrast.green] {string}, specifies the percent value / expression of the green-chanel. The expression supports: "value" (indicates the layer's value) keyword (Green/GetGreen()/SetGreen(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [contrast.green=100] adds 100% more green, or [contrast.green=50+value/2] applies more green based on the control's value. * [contrast.blue] {string}, specifies the percent value / expression of the blue-chanel. The expression supports: "value" (indicates the layer's value) keyword (Blue/GetBlue()/SetBlue(value) methods of exontrol.Gauge.LayerColorAdjustment). For instance, [contrast.blue=100] adds 100% more blue, or [contrast.blue=50+value/2] applies more blue based on the control's value. * [clip] {"Rect","RoundRect","Ellipse" or "Pie"}, specifies the type of clipping to apply on the layer (Type/GetType()/SetType(value) method of exontrol.Gauge.LC). For instance, [clip=pie][clip.sweep=45] clips a pie of 45 degree * [clip.value] {number}, indicates the layer clip's value that's the value of "value" keywords within expression-properties such as: [x], [y], [left], [top], [width], [height], [roundX], [roundY], [radiusX], [radiusY], [xCenter], [yCenter], [start] and [sweep] flags of layer's clip. If the [clip.value] is not specified, the control's value is used instead. For instance, [clip.value=50] defines the value of the "value" keyword to 50 for any expression of [x], [y], [left], [top], [width], [height], [roundX], [roundY], [radiusX], [radiusY], [xCenter], [yCenter], [start] and [sweep] flags * [clip.x] {string}, specifies the x-offset expression / value of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (OffsetX/GetOffsetX()/SetOffsetX(value) method of exontrol.Gauge.LC). For instance, [clip.x=120], moves right by 128-pixels the layer's clip, while [clip.x=value] indicates that the entire clip is moved horizontally based on clip/control's value. * [clip.y] {string}, specifies the y-offset expression / value of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (OffsetY/GetOffsetY()/SetOffsetY(value) method of exontrol.Gauge.LC). For instance, [clip.y=-120], moves up by 128-pixels the layer's clip, while [clip.y=value] indicates that the entire clip is moved vertically based on clip/control's value. * [clip.left] {string}, specifies the left position / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (Left/GetLeft()/SetLeft(value) method of exontrol.Gauge.LC). For instance, [clip.left=120], defines the left-margin of the clip at 120 pixels, or [clip.left=32+value] specifies that the clip's left margin is computed based on clip/control's value. * [clip.top] {string}, specifies the top position / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (Top/GetTop()/SetTop(value) method of exontrol.Gauge.LC). For instance, [clip.top=120], defines the top-margin of the clip at 120 pixels, or [clip.top=32+value] specifies that the clip's top margin is computed based on clip/control's value. * [clip.width] {string}, specifies the width / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (Width/GetWidth()/SetWidth(value) method of exontrol.Gauge.LC). For instance, [clip.width=120], defines the clip 120 pixels wide, or [clip.width=value] specifies that the clip's width is computed based on clip/control's value. * [clip.height] {string}, specifies the height / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (Height/GetHeight()/SetHeight(value) method of exontrol.Gauge.LC). For instance, [clip.height=120], defines the clip 120 pixels tall, or [clip.height=value] specifies that the clip's height is computed based on clip/control's value. * [clip.roundX] {string}, indicates the x-radius value / expression of the round corner, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (RoundRadiusX/GetRoundRadiusX()/SetRoundRadiusX(value) method of exontrol.Gauge.LC). For instance, [clip.roundX=16][clip.roundY=16], defines a round-radius of 16 pixels, while [clip.roundX=value][clip.roundY=value] defines the clip's round-radius based on the clip/control's value. The [clip.roundX] and [clip.roundY] flags are valid only for [clip=RoundRect]. * [clip.roundY] {string}, indicates the y-radius value / expression of the round corner, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (RoundRadiusY/GetRoundRadiusY()/SetRoundRadiusY(value) method of exontrol.Gauge.LC). For instance, [clip.roundX=16][clip.roundY=16], defines a round-radius of 16 pixels, while [clip.roundX=value][clip.roundY=value] defines the clip's round-radius based on the clip/control's value. The [clip.roundX] and [clip.roundY] flags are valid only for [clip=RoundRect]. * [clip.radiusX] {string}, specifies the x-radius value / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (RadiusX/GetRadiusX()/SetRadiusX(value) method of exontrol.Gauge.LC). For instance, [clip.radiusX=128], defines clip's x-radius to 128 pixels, while [clip.radiusX=value] specifies that the clip's x-radius is computed based on the clip/control's value. The [clip.radiusX] and [clip.radiusY] flags are valid only for [clip=Ellipse] or [clip=Pie]. * [clip.radiusY] {string}, specifies the y-radius value / expression of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (RadiusY/GetRadiusY()/SetRadiusY(value) method of exontrol.Gauge.LC). For instance, [clip.radiusY=128], defines clip's y-radius to 128 pixels, while [clip.radiusY=value] specifies that the clip's y-radius is computed based on the clip/control's value. The [clip.radiusX] and [clip.radiusY] flags are valid only for [clip=Ellipse] or [clip=Pie]. * [clip.xCenter] {string}, indicates the x-position / expression of the center of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (CenterX/GetCenterX()/SetCenterX(value) method of exontrol.Gauge.LC). For instance, [clip.xCenter=128], defines clip's x-center to 128 pixels, while [clip.xCenter=value] specifies that the clip's x-center is computed based on the clip/control's value. The [clip.xCenter] and [clip.yCenter] flags are valid only for [clip=Ellipse] or [clip=Pie]. * [clip.yCenter] {string}, indicates the y-position / expression of the center of the clip, relative to the layer. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (CenterY/GetCenterY()/SetCenterY(value) method of exontrol.Gauge.LC). For instance, [clip.yCenter=128], defines clip's y-center to 128 pixels, while [clip.yCenter=value] specifies that the clip's y-center is computed based on the clip/control's value. The [clip.xCenter] and [clip.yCenter] flags are valid only for [clip=Ellipse] or [clip=Pie]. * [clip.start] {string}, indicates the pie's starting angle (degree) relative to the y-axis. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (StartAngle/GetStartAngle()/SetStartAngle(value) method of exontrol.Gauge.LC). For instance, [clip.start=90], defines the pie's starting angle to 90 degree, or [clip.start=value] defines the pie's starting angle based on the clip/control's value. The [clip.start] and [clip.sweep] flags are valid only for [clip=Pie]. * [clip.sweep] {string}, indicates the pie's sweep angle (degree) relative to clip's starting angle. The expression supports the following keywords: "value" (specifies the clip's value pointed by the clip/control's Value property), "width" or "lwidth" (indicates the width in pixels of the layer), "height" or "lheight" (indicates the height in pixels of the layer) (SweepAngle/GetSweepAngle()/SetSweepAngle(value) method of exontrol.Gauge.LC). For instance, [clip.sweep=45], defines the pie's sweep angle to 45 degree, or [clip.sweep=value] defines the pie's sweep angle based on the clip/control's value. The [clip.start] and [clip.sweep] flags are valid only for [clip=Pie]. * * @example * * "gauge_back[key=back],gauge_needle[key=needle][drag=rotate]" {string}, defines a gauge control where "gauge_needle" is rotable * "red[drag=rotate],rgba(0,255,0,0.75)[key=green][clip=ellipse][width=width/2][height=height/2][left=width/4][top=height/4][drag=move]" {string}, builds a control using two layers red and 75% green (clipped to an ellispe, which can be moved) */ layers: null, /** * @description The layerAutoSize field specifies the index or the key of the layer that determines the size to display all layers (scaled). * @type {number/string} Indicates the index of the layer or a string that specifies the key of the layer. Shortly, the layerAutoSize resizes all layers based on the picture of the provided layer. The size of the layer is determined by it's background picture (if provided). The layerAutoSize has no effect if the pointed-layer provides no picture/image on its background. * @example * * -1 {number}, specifies that no layer is resized, and they are shown as provided * 0 {number}, specifies that all layers are resized and scaled based on the first-layer's picture/image (the layer with the index 0) * "items" {string}, specifies that all layers are resized and scaled based on image/picture of the layer with the key "items" */ layerAutoSize: 0, /** * @description The layerOfValue field specifies the index or the key of the layer whose value determines the control's Value property * @type {number/string} Indicates the index or the key of the layer whose value determines the control's Value property. Each layer can have its value such as a rotation-angle or an offset, so the layerOfValue property defines the layer whose value defines the control's Value. For instance, using the layerOfValue property you can specify which layer should be rotated when mouse's wheel is rotated. * @example * * -1 {number}, indicates that the control's Value is determined by the last visible layer with [drag] (OnDrag/GetOnDrag()/SetOnDrag(value) methods of exontrol.RadialMenu.Layer) defined. Shortly, the last visible and dragable layer determines the control's Value. * 0 {number}, specifies that the layer with the index 0, defines the control's Value property. * "hour" {string}, specifies that the layer with the key "hour", defines the control's Value property. */ layerOfValue: -1, /** * @description The value field specifies the control's value. * @type {number} Indicates the control's value. The layerOfValue field specifies the index or the key of the layer whose value determines the control's Value property. The value property can represent a rotation-angle or an offset for one or multiple layers. * @example * * 0 {number}, change the control's Value to 0, so it could be a zero-offset or a zero-rotation angle, depending on how the layer interprets the value * (new Date() - Date.Today())/1000/24/60/60 {number}, sets the control's value to current-time as a number between 0 and 1. */ value: null, /** * @description The debug field indicates whether the control displays the layers in debug-mode. * @type {boolean} Specifies whether the control displays the layers in debug-mode. * @example * * false {boolean}, shows the layers in normal-mode * true {boolean}, shows the layers in debug-mode */ debug: false, /** * @description The showLayers field indicates the only layers to be shown on the control. * @type {string} Specifies the layers to display within the control as explained: * * "all" {string}, specifies that all visible layers are shown. The Visible property (of exontrol.RadialMenu.Layer) shows or hides the layer * "" {string}, no layer is shown in the control, no matter of the layer's Visible property * "n1,n2,n3,..." {string}, specifies the list of layers to be shown, no matter of the layer's Visible property, where n1, n2, ... are numbers ( indicating the index of the layer to be shown ) or the layer's key. For instance "0" specifies that just the layer with the index 0 is show, "0,1,4", indicates that just layers with the specified index are displayed. * * @example * * null {null}, specifies that all visible layers are shown (equivalent of "all") * "" {string}, indicates than no layes is shown * "hour,min,sec" {string}, indicates that the control shows just the "hour","min" and "sec" layers only. */ showLayers: "all", /** * @description The layerDragAny field specifies the layer to drag (rotate, move or sweep) once the user clicks anywhere on the control. * @type {number/string} Indicates the index or the key of the layer to drag (rotate, move or sweep) once the user clicks anywhere on the control. In case the cursor hovers a dragable layer, the layerDragAny field is ignored. * @example * * -1 {number}, specifies that layerDragAny has no effect * 0 {number}, specifies that the layer with the index 0 is dragged, once the user clicks anywhere on the control. * "needle" {string}, specifies that the layer with the key "needle" is dragged, once the user clicks anywhere on the control. */ layerDragAny: -1 } /////////////////////////////////////////////////////////// (exontrol.Shapes.Gauge) // // The exontrol.Shapes.Gauge namespace provides support to customize the visual appearance of different parts of the exontrol.Gauge object. // /////////////////////////////////////////////////////////// /** * @description The exontrol.Shapes.Gauge namespace provides support to customize the visual appearance of different parts of the exontrol.Gauge object. */ exontrol.Shapes.Gauge = { }