dojox/gauges/GlossyHorizontalGauge (version 1.10)

dojox/gauges/BarGauge

Summary

Represents an horizontal bar gauge with a glossy appearance.

Usage

var foo = new GlossyHorizontalGauge();
dojox/gauges/GlossyHorizontalGauge

See the dojox/gauges/GlossyHorizontalGauge reference documentation for more information.

Examples

Example 1

<div dojoType="dojox.gauges.GlossyHorizontalGauge"
    id="testGauge"
    width="500"
    height="100"
    min="0"
    max="100"
    value="0" 
    majorTicksInterval="10"
    majorTicksColor="#c4c4c4"
    minorTicksInterval="5"
    minorTicksColor="#c4c4c4"
    color="black" 
    markerColor="#c4c4c4"
    font="normal normal normal 10pt sans-serif"
    noChange="true"
    title="title"
    scalePrecision="0"
>
</div>

Property Summary

Method Summary

  • _addScaleTick(indicator,major) Adds a scale ticks, that is an indicator.
  • _applyAttributes() Step during widget creation to copy widget attributes to the DOM according to attributeMap and _setXXXAttr objects, and also to call custom _setXXXAttr() methods.
  • _attrToDom(attr,value,commands) Reflect a widget attribute (title, tabIndex, duration etc.) to the widget DOM, as specified by commands parameter.
  • _changeAttrValue(name,value) Internal helper for directly changing an attribute value.
  • _computeDataRectangle() Computes the rectangle that defines the data area of the gauge.
  • _defaultIndicator()
  • _dragIndicator(widget,e) Handles the dragging of an indicator to the event position, including moving/re-drawing get angle for mouse position
  • _dragIndicatorAt(widget,x,y) Handles the dragging of an indicator, including moving/re-drawing get new value based on mouse position
  • _formatNumber(val)
  • _get(name) Helper function to get value for specified property stored by this._set(), i.e. for properties with custom setters.
  • _getAttrNames(name) Helper function for get() and set().
  • _getBorderWidth() Computes the width of the border surrounding the gauge
  • _getInteractiveIndicator()
  • _getNumberModule() Tests is AMD dojo/number is loaded
  • _getPosition(value) This is a helper function used to determine the position that represents a given value on the bar graph
  • _getTextWidth(s,font)
  • _getValueForPosition(pos) This is a helper function used to determine the value represented by a position on the bar graph
  • _handleDragInteractionMouseMove(e) This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value
  • _handleDragInteractionMouseUp(e) This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value
  • _handleMouseDownIndicator(indicator,e) This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value
  • _handleMouseOutIndicator(indicator,e) This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value
  • _handleMouseOutRange(range,e)
  • _handleMouseOverIndicator(indicator,e) This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value
  • _handleMouseOverRange(range,e)
  • _hideTooltip()
  • _introspect() Collect metadata about this widget (only once per class, not once per instance): - list of attributes with custom setters, storing in this.constructor._setterAttrs - generate this.constructor._onMap, mapping names like "mousedown" to functions like onMouseDown
  • _isScaleCircular() Internal method to check if the scale is fully circular
  • _layoutGauge() Layout the gauge elements depending on the various parameters (size, font, tick length..)
  • _removeScaleTick(indicator) Removes the given scale tick from the gauge by calling it's remove function and removing it from the local cache.
  • _set(name,value) Helper function to set new value for specified property, and call handlers registered with watch() if the value has changed.
  • _setColorAttr(color) Sets the main color of the gauge
  • _setFocusedAttr(val)
  • _setFontAttr(font) Sets the font of the gauge
  • _setMajorTicksColorAttr(color) Sets the color of the major ticks.
  • _setMajorTicksIntervalAttr(interval) Sets the interval between major ticks
  • _setMajorTicksProperty(prop)
  • _setMarkerColorAttr(color) Sets the main color of the marker
  • _setMaxAttr(max)
  • _setMinAttr(min)
  • _setMinorTicksColorAttr(color) Sets the color of the minor ticks.
  • _setMinorTicksIntervalAttr(interval) Sets the interval between minor ticks
  • _setMinorTicksProperty(prop)
  • _setNoChangeAttr(value) Indicates if the value of the gauge can be changed or not
  • _setOwnerDocumentAttr(val)
  • _setScalePrecisionAttr(value) Changes precision of the numbers in the scale of the gauge
  • _setStyleAttr(value) Sets the style attribute of the widget according to value, which is either a hash like {height: "5px", width: "3px"} or a plain string
  • _setTicks(oldTicks,newTicks,major) internal method used to clear existing tick marks, then add new ones
  • _setTitleAttr(value) Sets the title displayed by the needle's tooltip .
  • _setValueAttr(value) Changes the value of the gauge
  • addIndicator(indicator) This method is used to add an indicator to the gauge.
  • addRange(range) This method is used to add a range to the gauge.
  • addRanges(ranges) This method is used to add ranges to the gauge.
  • attr(name,value) This method is deprecated, use get() or set() directly.
  • buildRendering() Overrides _Widget.buildRendering
  • connect(obj,event,method) Deprecated, will be removed in 2.0, use this.own(on(...)) or this.own(aspect.after(...)) instead.
  • create(params,srcNodeRef) Kick off the life-cycle of a widget
  • createSurface() Internal method used by the gauge to create the graphics surface area
  • defer(fcn,delay) Wrapper to setTimeout to avoid deferred functions executing after the originating widget has been destroyed.
  • destroy(preserveDom) Destroy this widget, but not its descendants.
  • destroyDescendants(preserveDom) Recursively destroy the children of this widget and their descendants.
  • destroyRecursive(preserveDom) Destroy this widget and its descendants
  • destroyRendering(preserveDom) Destroys the DOM nodes associated with this widget.
  • disconnect(handle) Deprecated, will be removed in 2.0, use handle.remove() instead.
  • draw() This function is used to draw (or redraw) the gauge.
  • drawBackground(group) Draws the background of the gauge
  • drawForeground(group) This function is used to draw (or redraw) the foreground of the gauge.
  • drawRange(group,range) This function is used to draw (or redraw) a range
  • drawText(group,txt,x,y,align,color,font) This function is used draw text onto the gauge.
  • emit(type,eventObj,callbackArgs) Used by widgets to signal that a synthetic event occurred, ex: myWidget.emit("attrmodified-selectedChildWidget", {}).
  • get(name) Get a property from a widget.
  • getChildren() Returns all direct children of this widget, i.e. all widgets underneath this.containerNode whose parent is this widget.
  • getDescendants() Returns all the widgets contained by this, i.e., all widgets underneath this.containerNode.
  • getMajorTicksLength() Returns the size of the major ticks.
  • getMinorTicksLength() Gets the size of the minor ticks.
  • getParent() Returns the parent widget of this widget.
  • getRangeUnderMouse(e) Determines which range the mouse is currently over
  • handleMouseDown(e) This is an internal handler used by the gauge to support using the mouse to move indicators
  • handleMouseMove(e) This is an internal handler used by the gauge to support using the mouse to show the tooltips
  • handleMouseOut(e) This is an internal handler used by the gauge to support hover text
  • handleMouseOver(e) This is an internal handler used by the gauge to support hover text
  • handleTouchEnd(e) This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value
  • handleTouchMove(e) This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value
  • handleTouchStart(e) This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value
  • handleTouchStartIndicator(indicator,e) This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value
  • hasChildren() Returns true if widget has children, i.e. if this.containerNode contains something.
  • isFocusable() Return true if this widget can currently be focused and false if not
  • isLeftToRight() Return this widget's explicit or implicit orientation (true for LTR, false for RTL)
  • moveIndicatorToFront(indicator) This function is used to move an indicator the the front (top) of the gauge
  • on(type,func)
  • own() Track specified handles and remove/destroy them when this instance is destroyed, unless they were already removed/destroyed manually.
  • placeAt(reference,position) Place this widget somewhere in the DOM based on standard domConstruct.place() conventions.
  • postCreate()
  • postMixInProperties() Called after the parameters to the widget have been read-in, but before the widget template is instantiated.
  • postscript(params,srcNodeRef) Kicks off widget instantiation.
  • removeIndicator(indicator) Removes the given indicator from the gauge by calling it's remove function and removing it from the local cache.
  • removeText(t) Removes a text element from the gauge.
  • set(name,value) Set a property on a widget
  • setAttribute(attr,value) Deprecated.
  • setBackground(background) This method is used to set the background of the gauge after it is created.
  • setMajorTicks(ticks) Creates and draws the major tick marks based on the passed object (expecting the same format as the majorTicks object documented above)
  • setMajorTicksLength(length) Sets the size of the major ticks.
  • setMinorTicks(ticks) Creates and draws the minor tick marks based on the passed object (expecting the same format as the minorTicks object documented above)
  • setMinorTicksLength(length) Sets the size of the minor ticks.
  • startup()
  • subscribe(t,method) Deprecated, will be removed in 2.0, use this.own(topic.subscribe()) instead.
  • toString() Returns a string that represents the widget.
  • uninitialize() Deprecated.
  • unsubscribe(handle) Deprecated, will be removed in 2.0, use handle.remove() instead.
  • updateTooltip(txt,e) Updates the tooltip for the gauge to display the given text.
  • watch(name,callback) Watches a property for changes

Event Summary

  • _onBlur() This is where widgets do processing for when they stop being active, such as changing CSS classes.
  • _onFocus() This is where widgets do processing for when they are active, such as changing CSS classes.
  • _onMap(type) Maps on() type parameter (ex: "mousemove") to method name (ex: "onMouseMove").
  • _onShow() Internal method called when this widget is made visible.
  • onBlur() Called when the widget stops being "active" because focus moved to something outside of it, or the user clicked somewhere outside of it, or the widget was hidden.
  • onClick(event) Connect to this function to receive notifications of mouse click events.
  • onClose() Called when this widget is being displayed as a popup (ex: a Calendar popped up from a DateTextBox), and it is hidden.
  • onDblClick(event) Connect to this function to receive notifications of mouse double click events.
  • onFocus() Called when the widget becomes "active" because it or a widget inside of it either has focus, or has recently been clicked.
  • onHide() Called when another widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.
  • onKeyDown(event) Connect to this function to receive notifications of keys being pressed down.
  • onKeyPress(event) Connect to this function to receive notifications of printable keys being typed.
  • onKeyUp(event) Connect to this function to receive notifications of keys being released.
  • onMouseDown(event) Connect to this function to receive notifications of when the mouse button is pressed down.
  • onMouseEnter(event) Connect to this function to receive notifications of when the mouse moves onto this widget.
  • onMouseLeave(event) Connect to this function to receive notifications of when the mouse moves off of this widget.
  • onMouseMove(event) Connect to this function to receive notifications of when the mouse moves over nodes contained within this widget.
  • onMouseOut(event) Connect to this function to receive notifications of when the mouse moves off of nodes contained within this widget.
  • onMouseOver(event) Connect to this function to receive notifications of when the mouse moves onto nodes contained within this widget.
  • onMouseUp(event) Connect to this function to receive notifications of when the mouse button is released.
  • onShow() Called when this widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.
  • onValueChanged() Callback when the value of the gauge has changed.

Properties

_attrPairNames
Defined by: dijit/_WidgetBase
_backgroundDefault
Defined by: dojox/gauges/_Gauge
_blankGif
Defined by: dijit/_WidgetBase

Path to a blank 1x1 image. Used by <img> nodes in templates that really get their image via CSS background-image.

_designHeight
_drag
Defined by: dojox/gauges/_Gauge
_focusManager
Defined by: dijit/_FocusMixin
_img
Defined by: dojox/gauges/_Gauge
_indicatorData
Defined by: dojox/gauges/_Gauge
_lastHover
Defined by: dojox/gauges/_Gauge
_majorTicksLength

Major tick size, at design

_margin
_maxBorderWidth
_minBorderWidth
_minorTicksLength

Minor tick size, at design

_overOverlay
Defined by: dojox/gauges/_Gauge
_rangeData
Defined by: dojox/gauges/_Gauge
_setClassAttr
Defined by: dijit/_WidgetBase
_setDirAttr
Defined by: dijit/_WidgetBase
_setIdAttr
Defined by: dijit/_WidgetBase
_setLangAttr
Defined by: dijit/_WidgetBase
_setTypeAttr
Defined by: dijit/_WidgetBase
_started
Defined by: dijit/_WidgetBase

startup() has completed.

_tickLabelOffset
attributeMap
Defined by: dijit/_WidgetBase

Deprecated. Instead of attributeMap, widget should have a _setXXXAttr attribute for each XXX attribute to be mapped to the DOM.

attributeMap sets up a "binding" between attributes (aka properties) of the widget and the widget's DOM. Changes to widget attributes listed in attributeMap will be reflected into the DOM.

For example, calling set('title', 'hello') on a TitlePane will automatically cause the TitlePane's DOM to update with the new title.

attributeMap is a hash where the key is an attribute of the widget, and the value reflects a binding to a:

  • DOM node attribute

    focus: {node: "focusNode", type: "attribute"} Maps this.focus to this.focusNode.focus

  • DOM node innerHTML

    title: { node: "titleNode", type: "innerHTML" } Maps this.title to this.titleNode.innerHTML

  • DOM node innerText

    title: { node: "titleNode", type: "innerText" } Maps this.title to this.titleNode.innerText

  • DOM node CSS class

    myClass: { node: "domNode", type: "class" } Maps this.myClass to this.domNode.className

If the value is an array, then each element in the array matches one of the formats of the above list.

There are also some shorthands for backwards compatibility:

  • string --> { node: string, type: "attribute" }, for example:
"focusNode" ---> { node: "focusNode", type: "attribute" }
  • "" --> { node: "domNode", type: "attribute" }
background
Defined by: dojox/gauges/_Gauge

The color of the background. This must be an object of one of two forms: {'color': 'color-name'} OR (for a gradient:) {'type': 'linear', 'x1': 0, 'x2': 0, 'y1': 0, 'y2': 200, 'colors': [{offset: 0, color:'#C0C0C0'}, {offset: 1, color: '#E0E0E0'}] }

baseClass
Defined by: dijit/_WidgetBase

Root CSS class of the widget (ex: dijitTextBox), used to construct CSS classes to indicate widget state.

class
Defined by: dijit/_WidgetBase
color

The main color of the gauge.

containerNode
Defined by: dijit/_WidgetBase

Designates where children of the source DOM node will be placed. "Children" in this case refers to both DOM nodes and widgets. For example, for myWidget:

<div data-dojo-type=myWidget>
    <b> here's a plain DOM node
    <span data-dojo-type=subWidget>and a widget</span>
    <i> and another plain DOM node </i>
</div>

containerNode would point to:

<b> here's a plain DOM node
<span data-dojo-type=subWidget>and a widget</span>
<i> and another plain DOM node </i>

In templated widgets, "containerNode" is set via a data-dojo-attach-point assignment.

containerNode must be defined for any widget that accepts innerHTML (like ContentPane or BorderContainer or even Button), and conversely is null for widgets that don't, like TextBox.

dataHeight
Defined by: dojox/gauges/BarGauge

height of data area (default is bar graph width - 10)

dataWidth
Defined by: dojox/gauges/BarGauge

width of data area (default is bar graph width - 10)

dataX
Defined by: dojox/gauges/BarGauge

x position of data area (default 5)

dataY
Defined by: dojox/gauges/BarGauge

y position of data area (default 5)

defaultColors
Defined by: dojox/gauges/_Gauge

Set of default colors to color ranges with.

dir
Defined by: dijit/_WidgetBase

Bi-directional support, as defined by the HTML DIR attribute. Either left-to-right "ltr" or right-to-left "rtl". If undefined, widgets renders in page's default direction.

domNode
Defined by: dijit/_WidgetBase

This is our visible representation of the widget! Other DOM Nodes may by assigned to other properties, usually through the template system's data-dojo-attach-point syntax, but the domNode property is the canonical "top level" node in widget UI.

focused
Defined by: dijit/_FocusMixin

This widget or a widget it contains has focus, or is "active" because it was recently clicked.

font

The font of the gauge

gaugeContent
Defined by: dojox/gauges/_Gauge
height
Defined by: dojox/gauges/_Gauge

The height of the gauge (default is 200)

hideValues
Defined by: dojox/gauges/_Gauge

Indicates whether the text boxes showing the value of the indicator (as text content) should be hidden or shown. Default is not hidden, aka shown.

id
Defined by: dijit/_WidgetBase

A unique, opaque ID string that can be assigned by users or by the system. If the developer passes an ID which is known not to be unique, the specified ID is ignored and the system-generated ID is used instead.

image
Defined by: dojox/gauges/_Gauge

Background image for gauge (default is no image)

lang
Defined by: dijit/_WidgetBase

Rarely used. Overrides the default Dojo locale used to render this widget, as defined by the HTML LANG attribute. Value must be among the list of locales specified during by the Dojo bootstrap, formatted according to RFC 3066 (like en-us).

majorTicks
Defined by: dojox/gauges/_Gauge

An object representing the tick marks that should be added to the gauge. Major tick marks have a text label indicating the value. The object can have the following attributes (required are marked with a *):

  • offset: the distance from the 'center' of the gauge. Used differently for Analog vs. Bar
  • width: The width of the mark
  • length: The length of the mark
  • interval: The interval the ticks should be added on
  • color: The color of the mark and text
  • font: an object with any/all of the following parameters:

    {family: "Helvetica", style: "italic", variant: 'small-caps', weight: 'bold', size: "18pt"}

majorTicksColor

Color of major tick marks

majorTicksInterval

Interval between major ticks

markerColor
max
Defined by: dojox/gauges/_Gauge

The maximum value of the gauge. Normally not set explicitly, as it will be determined by the ranges that are added.

min
Defined by: dojox/gauges/_Gauge

The minimum value of the gauge. Normally not set explicitly, as it will be determined by the ranges that are added.

minorTicks
Defined by: dojox/gauges/_Gauge

An object of the same format as majorTicks, indicating where the minor (label-less) marks should be placed The font parameter is ignored if provided since minor tick marks have no text label.

minorTicksColor

Color of minor tick marks

minorTicksInterval

Interval between minor ticks

noChange

Indicates if the gauge reacts to touch events

observer
ownerDocument
Defined by: dijit/_WidgetBase

The document this widget belongs to. If not specified to constructor, will default to srcNodeRef.ownerDocument, or if no sourceRef specified, then to the document global

scalePrecision

The precision for the formatting of numbers in the scale (default is 0)

srcNodeRef
Defined by: dijit/_WidgetBase

pointer to original DOM node

style
Defined by: dijit/_WidgetBase

HTML style attributes as cssText string or name/value hash

surface
Defined by: dojox/gauges/_Gauge

The GFX surface that the shapes are drawn on. Can be accessed/used by indicators to draw themselves

title

The title displayed in the needle's tooltip

tooltip
Defined by: dijit/_WidgetBase

When this widget's title attribute is used to for a tab label, accordion pane title, etc., this specifies the tooltip to appear when the mouse is hovered over that text.

useRangeStyles
Defined by: dojox/gauges/_Gauge

Indicates whether to use given css classes (dojoxGaugeRangeXX) to determine the color (and other style attributes?) of the ranges this value should be the number of dojoxGaugeRange classes that are defined, starting at dojoxGaugeRange1 (0 indicates falling to default hardcoded colors)

useTooltip
Defined by: dojox/gauges/_Gauge

Indicates whether tooltips should be displayed for ranges, indicators, etc.

value

The value of the gauge.

width
Defined by: dojox/gauges/_Gauge

The width of the gauge (default is 300)

Methods

_addScaleTick(indicator,major)
Defined by dojox/gauges/_Gauge

Adds a scale ticks, that is an indicator.

This method adds a tick mark to the gauge

Parameter Type Description
indicator dojox/gauges/_Indicator

A dojox.gauges._Indicator or an object with similar parameters (value, color, offset, etc.).

major Boolean
Returns:instance
_applyAttributes()
Defined by dijit/_WidgetBase

Step during widget creation to copy widget attributes to the DOM according to attributeMap and _setXXXAttr objects, and also to call custom _setXXXAttr() methods.

Skips over blank/false attribute values, unless they were explicitly specified as parameters to the widget, since those are the default anyway, and setting tabIndex="" is different than not setting tabIndex at all.

For backwards-compatibility reasons attributeMap overrides _setXXXAttr when _setXXXAttr is a hash/string/array, but _setXXXAttr as a functions override attributeMap.

_attrToDom(attr,value,commands)
Defined by dijit/_WidgetBase

Reflect a widget attribute (title, tabIndex, duration etc.) to the widget DOM, as specified by commands parameter. If commands isn't specified then it's looked up from attributeMap. Note some attributes like "type" cannot be processed this way as they are not mutable.

Parameter Type Description
attr String

Name of member variable (ex: "focusNode" maps to this.focusNode) pointing to DOMNode inside the widget, or alternately pointing to a subwidget

value String
commands Object
Optional
_changeAttrValue(name,value)
Defined by dojo/Stateful

Internal helper for directly changing an attribute value.

Directly change the value of an attribute on an object, bypassing any accessor setter. Also handles the calling of watch and emitting events. It is designed to be used by descendant class when there are two values of attributes that are linked, but calling .set() is not appropriate.

Parameter Type Description
name String

The property to set.

value Mixed

The value to set in the property.

Returns:function

Internal helper for directly changing an attribute value.

_computeDataRectangle()

Computes the rectangle that defines the data area of the gauge.

_defaultIndicator()
_dragIndicator(widget,e)

Handles the dragging of an indicator to the event position, including moving/re-drawing get angle for mouse position

Parameter Type Description
widget Object
e Object
_dragIndicatorAt(widget,x,y)

Handles the dragging of an indicator, including moving/re-drawing get new value based on mouse position

Parameter Type Description
widget Object
x undefined
y undefined
_formatNumber(val)
Parameter Type Description
val undefined
Returns:undefined
_get(name)
Defined by dijit/_WidgetBase

Helper function to get value for specified property stored by this._set(), i.e. for properties with custom setters. Used mainly by custom getters.

For example, CheckBox._getValueAttr() calls this._get("value").

Parameter Type Description
name String
Returns:undefined
_getAttrNames(name)
Defined by dijit/_WidgetBase

Helper function for get() and set(). Caches attribute name values so we don't do the string ops every time.

Parameter Type Description
name undefined
Returns:undefined | object
_getBorderWidth()

Computes the width of the border surrounding the gauge

Returns:undefined
_getInteractiveIndicator()
Defined by dojox/gauges/_Gauge
Returns:undefined | null
_getNumberModule()
Defined by dojox/gauges/_Gauge

Tests is AMD dojo/number is loaded

Returns:null
_getPosition(value)

This is a helper function used to determine the position that represents a given value on the bar graph

Parameter Type Description
value Number

A value to be converted to a position for this bar graph.

Returns:number
_getTextWidth(s,font)
Parameter Type Description
s undefined
font undefined
Returns:number
_getValueForPosition(pos)

This is a helper function used to determine the value represented by a position on the bar graph

Parameter Type Description
pos Number

A position to be converted to a value.

Returns:number
_handleDragInteractionMouseMove(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value

Parameter Type Description
e Object

The event object

_handleDragInteractionMouseUp(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value

Parameter Type Description
e Object

The event object

_handleMouseDownIndicator(indicator,e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value

Parameter Type Description
indicator _Indicator

The indicator object

e Object

The event object

_handleMouseOutIndicator(indicator,e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value

Parameter Type Description
indicator _Indicator

The indicator object

e Object

The event object

_handleMouseOutRange(range,e)
Defined by dojox/gauges/_Gauge
Parameter Type Description
range undefined
e undefined
_handleMouseOverIndicator(indicator,e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to drag an indicator to modify it's value

Parameter Type Description
indicator _Indicator

The indicator object

e Object

The event object

_handleMouseOverRange(range,e)
Defined by dojox/gauges/_Gauge
Parameter Type Description
range undefined
e undefined
_hideTooltip()
Defined by dojox/gauges/_Gauge
_introspect()
Defined by dijit/_WidgetBase

Collect metadata about this widget (only once per class, not once per instance):

- list of attributes with custom setters, storing in this.constructor._setterAttrs
- generate this.constructor._onMap, mapping names like "mousedown" to functions like onMouseDown
_isScaleCircular()
Defined by dojox/gauges/_Gauge

Internal method to check if the scale is fully circular

Returns:boolean
_layoutGauge()

Layout the gauge elements depending on the various parameters (size, font, tick length..)

_removeScaleTick(indicator)
Defined by dojox/gauges/_Gauge

Removes the given scale tick from the gauge by calling it's remove function and removing it from the local cache.

Parameter Type Description
indicator Object
_set(name,value)
Defined by dijit/_WidgetBase

Helper function to set new value for specified property, and call handlers registered with watch() if the value has changed.

Parameter Type Description
name String
value anything
_setColorAttr(color)

Sets the main color of the gauge

Parameter Type Description
color String

The color

_setFocusedAttr(val)
Defined by dijit/_Widget
Parameter Type Description
val undefined
_setFontAttr(font)

Sets the font of the gauge

Parameter Type Description
font String

An string representing the font such as 'normal normal normal 10pt Helvetica,Arial,sans-serif'

_setMajorTicksColorAttr(color)

Sets the color of the major ticks.

Parameter Type Description
color undefined
_setMajorTicksIntervalAttr(interval)

Sets the interval between major ticks

Parameter Type Description
interval undefined
_setMajorTicksProperty(prop)
Parameter Type Description
prop undefined
_setMarkerColorAttr(color)

Sets the main color of the marker

Parameter Type Description
color String

The color

_setMaxAttr(max)
Parameter Type Description
max undefined
_setMinAttr(min)
Parameter Type Description
min undefined
_setMinorTicksColorAttr(color)

Sets the color of the minor ticks.

Parameter Type Description
color undefined
_setMinorTicksIntervalAttr(interval)

Sets the interval between minor ticks

Parameter Type Description
interval undefined
_setMinorTicksProperty(prop)
Parameter Type Description
prop undefined
_setNoChangeAttr(value)

Indicates if the value of the gauge can be changed or not

Parameter Type Description
value boolean

true indicates that the gauge's value cannot be changed

_setOwnerDocumentAttr(val)
Defined by dijit/_WidgetBase
Parameter Type Description
val undefined
_setScalePrecisionAttr(value)

Changes precision of the numbers in the scale of the gauge

Parameter Type Description
value Number

The new value

_setStyleAttr(value)
Defined by dijit/_WidgetBase

Sets the style attribute of the widget according to value, which is either a hash like {height: "5px", width: "3px"} or a plain string

Determines which node to set the style on based on style setting in attributeMap.

Parameter Type Description
value String | Object
_setTicks(oldTicks,newTicks,major)
Defined by dojox/gauges/_Gauge

internal method used to clear existing tick marks, then add new ones

Parameter Type Description
oldTicks Object
newTicks Object
major Boolean
Returns:Object
_setTitleAttr(value)

Sets the title displayed by the needle's tooltip .

Parameter Type Description
value String

the title

_setValueAttr(value)

Changes the value of the gauge

Parameter Type Description
value Number

The new value for the gauge.

addIndicator(indicator)
Defined by dojox/gauges/_Gauge

This method is used to add an indicator to the gauge.

This method adds an indicator, such as a t needle, to the gauge.

Parameter Type Description
indicator dojox/gauges/_Indicator

A dojox.gauges._Indicator or an object with similar parameters (value, color, offset, etc.).

Returns:instance
addRange(range)
Defined by dojox/gauges/_Gauge

This method is used to add a range to the gauge.

Creates a range (colored area on the background of the gauge) based on the given arguments.

Parameter Type Description
range dojox/gauges/Range

A range is either a dojox.gauges.Range object, or a object with similar parameters (low, high, hover, etc.).

addRanges(ranges)
Defined by dojox/gauges/_Gauge

This method is used to add ranges to the gauge.

Creates a range (colored area on the background of the gauge) based on the given arguments.

Parameter Type Description
ranges Array
attr(name,value)
Defined by dijit/_Widget

This method is deprecated, use get() or set() directly.

Parameter Type Description
name String | Object

The property to get or set. If an object is passed here and not a string, its keys are used as names of attributes to be set and the value of the object as values to set in the widget.

value Object
Optional

Optional. If provided, attr() operates as a setter. If omitted, the current value of the named property is returned.

Returns:undefined
buildRendering()
Defined by dojox/gauges/_Gauge

Overrides _Widget.buildRendering

connect(obj,event,method)
Defined by dijit/_WidgetBase

Deprecated, will be removed in 2.0, use this.own(on(...)) or this.own(aspect.after(...)) instead.

Connects specified obj/event to specified method of this object and registers for disconnect() on widget destroy.

Provide widget-specific analog to dojo.connect, except with the implicit use of this widget as the target object. Events connected with this.connect are disconnected upon destruction.

Parameter Type Description
obj Object | null
event String | Function
method String | Function
Returns:any | undefined

A handle that can be passed to disconnect in order to disconnect before the widget is destroyed.

Examples

Example 1

var btn = new Button();
// when foo.bar() is called, call the listener we're going to
// provide in the scope of btn
btn.connect(foo, "bar", function(){
    console.debug(this.toString());
});
create(params,srcNodeRef)
Defined by dijit/_WidgetBase

Kick off the life-cycle of a widget

Create calls a number of widget methods (postMixInProperties, buildRendering, postCreate, etc.), some of which of you'll want to override. See http://dojotoolkit.org/reference-guide/dijit/_WidgetBase.html for a discussion of the widget creation lifecycle.

Of course, adventurous developers could override create entirely, but this should only be done as a last resort.

Parameter Type Description
params Object | null

Hash of initialization parameters for widget, including scalar values (like title, duration etc.) and functions, typically callbacks like onClick. The hash can contain any of the widget's properties, excluding read-only properties.

srcNodeRef DOMNode | String
Optional

If a srcNodeRef (DOM node) is specified:

  • use srcNodeRef.innerHTML as my contents
  • if this is a behavioral widget then apply behavior to that srcNodeRef
  • otherwise, replace srcNodeRef with my generated DOM tree
createSurface()
Defined by dojox/gauges/_Gauge

Internal method used by the gauge to create the graphics surface area

defer(fcn,delay)
Defined by dijit/_WidgetBase

Wrapper to setTimeout to avoid deferred functions executing after the originating widget has been destroyed. Returns an object handle with a remove method (that returns null) (replaces clearTimeout).

Parameter Type Description
fcn Function

Function reference.

delay Number
Optional

Delay, defaults to 0.

Returns:object
destroy(preserveDom)
Defined by dijit/_WidgetBase

Destroy this widget, but not its descendants. Descendants means widgets inside of this.containerNode. Will also destroy any resources (including widgets) registered via this.own().

This method will also destroy internal widgets such as those created from a template, assuming those widgets exist inside of this.domNode but outside of this.containerNode.

For 2.0 it's planned that this method will also destroy descendant widgets, so apps should not depend on the current ability to destroy a widget without destroying its descendants. Generally they should use destroyRecursive() for widgets with children.

Parameter Type Description
preserveDom Boolean

If true, this method will leave the original DOM structure alone. Note: This will not yet work with _TemplatedMixin widgets

destroyDescendants(preserveDom)
Defined by dijit/_WidgetBase

Recursively destroy the children of this widget and their descendants.

Parameter Type Description
preserveDom Boolean
Optional

If true, the preserveDom attribute is passed to all descendant widget's .destroy() method. Not for use with _Templated widgets.

destroyRecursive(preserveDom)
Defined by dijit/_WidgetBase

Destroy this widget and its descendants

This is the generic "destructor" function that all widget users should call to cleanly discard with a widget. Once a widget is destroyed, it is removed from the manager object.

Parameter Type Description
preserveDom Boolean
Optional

If true, this method will leave the original DOM structure alone of descendant Widgets. Note: This will NOT work with dijit._TemplatedMixin widgets.

destroyRendering(preserveDom)
Defined by dijit/_WidgetBase

Destroys the DOM nodes associated with this widget.

Parameter Type Description
preserveDom Boolean
Optional

If true, this method will leave the original DOM structure alone during tear-down. Note: this will not work with _Templated widgets yet.

disconnect(handle)
Defined by dijit/_WidgetBase

Deprecated, will be removed in 2.0, use handle.remove() instead.

Disconnects handle created by connect.

Parameter Type Description
handle undefined
draw()
Defined by dojox/gauges/_Gauge

This function is used to draw (or redraw) the gauge.

Draws the gauge by drawing the surface, the ranges, and the indicators.

drawBackground(group)

Draws the background of the gauge

Parameter Type Description
group Object

The GFX group where the background must be drawn

drawForeground(group)
Defined by dojox/gauges/_Gauge

This function is used to draw (or redraw) the foreground of the gauge.

The method may be used by subclasses to draw (or redraw) the foreground of the gauge.

Parameter Type Description
group undefined
drawRange(group,range)

This function is used to draw (or redraw) a range

Draws a range (colored area on the background of the gauge) based on the given arguments.

Parameter Type Description
group Object

The GFX group where the range must be drawn.

range Object

A range is either a dojox.gauges.Range or an object with similar parameters (low, high, hover, etc.).

drawText(group,txt,x,y,align,color,font)
Defined by dojox/gauges/_Gauge

This function is used draw text onto the gauge. The text object is also returned by the function so that may be removed later by calling removeText

Parameter Type Description
group dojox/gfx/Group

The GFX Group where the text will be added.

txt String

The text to be drawn

x Number

The x coordinate at which to place the text

y Number

The y coordinate at which to place the text

align String
Optional

Indicates how to align the text Valid value is 'right', otherwise text is left-aligned

color String
Optional

Indicates the color of the text

font Object
Optional

A font object, generally of the following format: {family: "Helvetica", style: "italic", variant: 'small-caps', weight: 'bold', size: "18pt"}

Returns:undefined
emit(type,eventObj,callbackArgs)
Defined by dijit/_WidgetBase

Used by widgets to signal that a synthetic event occurred, ex:

myWidget.emit("attrmodified-selectedChildWidget", {}).

Emits an event on this.domNode named type.toLowerCase(), based on eventObj. Also calls onType() method, if present, and returns value from that method. By default passes eventObj to callback, but will pass callbackArgs instead, if specified. Modifies eventObj by adding missing parameters (bubbles, cancelable, widget).

Parameter Type Description
type String
eventObj Object
Optional
callbackArgs Array
Optional
Returns:undefined
get(name)
Defined by dijit/_WidgetBase

Get a property from a widget.

Get a named property from a widget. The property may potentially be retrieved via a getter method. If no getter is defined, this just retrieves the object's property.

For example, if the widget has properties foo and bar and a method named _getFooAttr(), calling: myWidget.get("foo") would be equivalent to calling widget._getFooAttr() and myWidget.get("bar") would be equivalent to the expression widget.bar2

Parameter Type Description
name undefined

The property to get.

Returns:undefined
getChildren()
Defined by dijit/_WidgetBase

Returns all direct children of this widget, i.e. all widgets underneath this.containerNode whose parent is this widget. Note that it does not return all descendants, but rather just direct children. Analogous to Node.childNodes, except containing widgets rather than DOMNodes.

The result intentionally excludes internally created widgets (a.k.a. supporting widgets) outside of this.containerNode.

Note that the array returned is a simple array. Application code should not assume existence of methods like forEach().

Returns:Array
getDescendants()
Defined by dijit/_Widget

Returns all the widgets contained by this, i.e., all widgets underneath this.containerNode. This method should generally be avoided as it returns widgets declared in templates, which are supposed to be internal/hidden, but it's left here for back-compat reasons.

Returns:Array
getMajorTicksLength()

Returns the size of the major ticks.

Returns:undefined
getMinorTicksLength()

Gets the size of the minor ticks.

Returns:undefined
getParent()
Defined by dijit/_WidgetBase

Returns the parent widget of this widget.

Returns:undefined
getRangeUnderMouse(e)

Determines which range the mouse is currently over

Parameter Type Description
e Object

The event object as received by the mouse handling functions below.

Returns:undefined
handleMouseDown(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to move indicators

Parameter Type Description
e Object

The event object

handleMouseMove(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using the mouse to show the tooltips

Parameter Type Description
e Object

The event object

handleMouseOut(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support hover text

Parameter Type Description
e Object

The event object

handleMouseOver(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support hover text

Parameter Type Description
e Object

The event object

handleTouchEnd(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value

Parameter Type Description
e Object

The touch e object

handleTouchMove(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value

Parameter Type Description
e Object

The touch event object

handleTouchStart(e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value

Parameter Type Description
e Object

The touch event object

handleTouchStartIndicator(indicator,e)
Defined by dojox/gauges/_Gauge

This is an internal handler used by the gauge to support using touch events to drag an indicator to modify it's value

Parameter Type Description
indicator _Indicator

The indicator object

e Object

The event object

hasChildren()
Defined by dojox/gauges/_Gauge

Returns true if widget has children, i.e. if this.containerNode contains something.

Returns:boolean
isFocusable()
Defined by dijit/_WidgetBase

Return true if this widget can currently be focused and false if not

Returns:undefined
isLeftToRight()
Defined by dijit/_WidgetBase

Return this widget's explicit or implicit orientation (true for LTR, false for RTL)

Returns:undefined
moveIndicatorToFront(indicator)
Defined by dojox/gauges/_Gauge

This function is used to move an indicator the the front (top) of the gauge

Parameter Type Description
indicator dojox/gauges/_Indicator

A dojox.gauges._Indicator or an object with similar parameters (value, color, offset, etc.).

on(type,func)
Defined by dijit/_Widget
Parameter Type Description
type String | Function

protected

func Function
Returns:undefined
own()
Defined by dijit/Destroyable

Track specified handles and remove/destroy them when this instance is destroyed, unless they were already removed/destroyed manually.

Returns:any | undefined

The array of specified handles, so you can do for example:

var handle = this.own(on(...))[0];
placeAt(reference,position)
Defined by dijit/_WidgetBase

Place this widget somewhere in the DOM based on standard domConstruct.place() conventions.

A convenience function provided in all _Widgets, providing a simple shorthand mechanism to put an existing (or newly created) Widget somewhere in the dom, and allow chaining.

Parameter Type Description
reference String | DomNode | DocumentFragment | dijit/_WidgetBase

Widget, DOMNode, DocumentFragment, or id of widget or DOMNode

position String | Int
Optional

If reference is a widget (or id of widget), and that widget has an ".addChild" method, it will be called passing this widget instance into that method, supplying the optional position index passed. In this case position (if specified) should be an integer.

If reference is a DOMNode (or id matching a DOMNode but not a widget), the position argument can be a numeric index or a string "first", "last", "before", or "after", same as dojo/dom-construct::place().

Returns:dijit/_WidgetBase | function

Provides a useful return of the newly created dijit._Widget instance so you can "chain" this function by instantiating, placing, then saving the return value to a variable.

Examples

Example 1

// create a Button with no srcNodeRef, and place it in the body:
var button = new Button({ label:"click" }).placeAt(win.body());
// now, 'button' is still the widget reference to the newly created button
button.on("click", function(e){ console.log('click'); }));

Example 2

// create a button out of a node with id="src" and append it to id="wrapper":
var button = new Button({},"src").placeAt("wrapper");

Example 3

// place a new button as the first element of some div
var button = new Button({ label:"click" }).placeAt("wrapper","first");

Example 4

// create a contentpane and add it to a TabContainer
var tc = dijit.byId("myTabs");
new ContentPane({ href:"foo.html", title:"Wow!" }).placeAt(tc)
postCreate()
Defined by dojox/gauges/_Gauge
postMixInProperties()
Defined by dijit/_WidgetBase

Called after the parameters to the widget have been read-in, but before the widget template is instantiated. Especially useful to set properties that are referenced in the widget template.

postscript(params,srcNodeRef)
Defined by dijit/_WidgetBase

Kicks off widget instantiation. See create() for details.

Parameter Type Description
params Object
Optional
srcNodeRef DomNode | String
removeIndicator(indicator)
Defined by dojox/gauges/_Gauge

Removes the given indicator from the gauge by calling it's remove function and removing it from the local cache.

Parameter Type Description
indicator dojox/gauges/_Indicator

The indicator to remove.

removeText(t)
Defined by dojox/gauges/_Gauge

Removes a text element from the gauge.

Parameter Type Description
t String

The text to remove.

set(name,value)
Defined by dijit/_WidgetBase

Set a property on a widget

Sets named properties on a widget which may potentially be handled by a setter in the widget.

For example, if the widget has properties foo and bar and a method named _setFooAttr(), calling myWidget.set("foo", "Howdy!") would be equivalent to calling widget._setFooAttr("Howdy!") and myWidget.set("bar", 3) would be equivalent to the statement widget.bar = 3;

set() may also be called with a hash of name/value pairs, ex:

myWidget.set({
    foo: "Howdy",
    bar: 3
});

This is equivalent to calling set(foo, "Howdy") and set(bar, 3)

Parameter Type Description
name undefined

The property to set.

value undefined

The value to set in the property.

Returns:function | string

Set a property on a widget

setAttribute(attr,value)
Defined by dijit/_Widget

Deprecated. Use set() instead.

Parameter Type Description
attr String
value anything
setBackground(background)
Defined by dojox/gauges/_Gauge

This method is used to set the background of the gauge after it is created.

Sets the background using the given object. Must be the same 'type' of object as the original background argument.

Parameter Type Description
background Object

An object in one of the two forms:

{'color': 'color-name'}

OR (for a gradient:)

{'type': 'linear', 'colors': [{offset: 0, color:'#C0C0C0'}, {offset: 1, color: '#E0E0E0'}] }

If background is null or undefined, this will set the fill to this._backgroundDefault

setMajorTicks(ticks)
Defined by dojox/gauges/_Gauge

Creates and draws the major tick marks based on the passed object (expecting the same format as the majorTicks object documented above)

Parameter Type Description
ticks Object
setMajorTicksLength(length)

Sets the size of the major ticks.

Parameter Type Description
length undefined
Returns:function

Sets the size of the major ticks.

setMinorTicks(ticks)
Defined by dojox/gauges/_Gauge

Creates and draws the minor tick marks based on the passed object (expecting the same format as the minorTicks object documented above)

Parameter Type Description
ticks Object
setMinorTicksLength(length)

Sets the size of the minor ticks.

Parameter Type Description
length undefined
Returns:function

Sets the size of the minor ticks.

startup()
subscribe(t,method)
Defined by dijit/_WidgetBase

Deprecated, will be removed in 2.0, use this.own(topic.subscribe()) instead.

Subscribes to the specified topic and calls the specified method of this object and registers for unsubscribe() on widget destroy.

Provide widget-specific analog to dojo.subscribe, except with the implicit use of this widget as the target object.

Parameter Type Description
t String

The topic

method Function

The callback

Returns:undefined

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
toString()
Defined by dijit/_WidgetBase

Returns a string that represents the widget.

When a widget is cast to a string, this method will be used to generate the output. Currently, it does not implement any sort of reversible serialization.

Returns:string
uninitialize()
Defined by dijit/_WidgetBase

Deprecated. Override destroy() instead to implement custom widget tear-down behavior.

Returns:boolean
unsubscribe(handle)
Defined by dijit/_WidgetBase

Deprecated, will be removed in 2.0, use handle.remove() instead.

Unsubscribes handle created by this.subscribe. Also removes handle from this widget's list of subscriptions

Parameter Type Description
handle Object
updateTooltip(txt,e)
Defined by dojox/gauges/_Gauge

Updates the tooltip for the gauge to display the given text.

Parameter Type Description
txt String

The text to put in the tooltip.

e Event
watch(name,callback)
Defined by dojo/Stateful

Watches a property for changes

Parameter Type Description
name String
Optional

Indicates the property to watch. This is optional (the callback may be the only parameter), and if omitted, all the properties will be watched

callback Function

The function to execute when the property changes. This will be called after the property has been changed. The callback will be called with the |this| set to the instance, the first argument as the name of the property, the second argument as the old value and the third argument as the new value.

Returns:any | object

An object handle for the watch. The unwatch method of this object can be used to discontinue watching this property:

var watchHandle = obj.watch("foo", callback);
watchHandle.unwatch(); // callback won't be called now

Events

_onBlur()
Defined by: dijit/_FocusMixin

This is where widgets do processing for when they stop being active, such as changing CSS classes. See onBlur() for more details.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
_onFocus()
Defined by: dijit/_FocusMixin

This is where widgets do processing for when they are active, such as changing CSS classes. See onFocus() for more details.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
_onMap(type)
Defined by: dijit/_WidgetBase

Maps on() type parameter (ex: "mousemove") to method name (ex: "onMouseMove"). If type is a synthetic event like touch.press then returns undefined.

Parameter Type Description
type String | Function
Returns:undefined

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
_onShow()
Defined by: dijit/_Widget

Internal method called when this widget is made visible. See onShow for details.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onBlur()
Defined by: dijit/_FocusMixin

Called when the widget stops being "active" because focus moved to something outside of it, or the user clicked somewhere outside of it, or the widget was hidden.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onClick(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of mouse click events.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onClose()
Defined by: dijit/_Widget

Called when this widget is being displayed as a popup (ex: a Calendar popped up from a DateTextBox), and it is hidden. This is called from the dijit.popup code, and should not be called directly.

Also used as a parameter for children of dijit/layout/StackContainer or subclasses. Callback if a user tries to close the child. Child will be closed if this function returns true.

Returns:boolean

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onDblClick(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of mouse double click events.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onFocus()
Defined by: dijit/_FocusMixin

Called when the widget becomes "active" because it or a widget inside of it either has focus, or has recently been clicked.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onHide()
Defined by: dijit/_Widget

Called when another widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.

Also called to indicate hide of a dijit.Dialog, dijit.TooltipDialog, or dijit.TitlePane.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onKeyDown(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of keys being pressed down.

Parameter Type Description
event undefined

key Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onKeyPress(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of printable keys being typed.

Parameter Type Description
event undefined

key Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onKeyUp(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of keys being released.

Parameter Type Description
event undefined

key Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseDown(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse button is pressed down.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseEnter(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse moves onto this widget.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseLeave(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse moves off of this widget.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseMove(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse moves over nodes contained within this widget.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseOut(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse moves off of nodes contained within this widget.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseOver(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse moves onto nodes contained within this widget.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onMouseUp(event)
Defined by: dijit/_Widget

Connect to this function to receive notifications of when the mouse button is released.

Parameter Type Description
event undefined

mouse Event

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onShow()
Defined by: dijit/_Widget

Called when this widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.

Also called to indicate display of a dijit.Dialog, dijit.TooltipDialog, or dijit.TitlePane.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
onValueChanged()

Callback when the value of the gauge has changed.

Examples

Example 1

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});
Error in the documentation? Can’t find what you are looking for? Let us know!