scale

Specifies a gauge's scale options.

Type: Object

To divide a scale, set its startValue and endValue properties. The scale's major and minor ticks will be calculated automatically, so that the tick labels do not overlap each other. Major ticks will be shown by default. To show minor ticks, set their visible property to true. You can set custom major and minor tick intervals, show custom major and minor ticks, and format tick labels. These and other scale options are available in the scale configuration object.

Show Example:
jQuery

In this example, several options of the gauge scale are changed. The scale is divided using the startValue and endValue options. Both the major and minor scale ticks are colored in black. In addition, the scale labels are displayed in a currency format.


                                    

                                    

endValue

Specifies the end value for the scale of the gauge.

Type: Number
Default Value: 100

Show Example:
jQuery

In this example, the scale is divided using the values assigned to the startValue and endValue fields.


                                    

                                    

hideFirstLabel

Specifies whether or not to hide the first scale label.

Type: Boolean
Default Value: false

Show Example:
jQuery

Switch between the values of the hideFirstLabel option using the check box under the gauge.


                                    

                                    

hideFirstTick

Specifies whether or not to hide the first major tick on the scale.

Type: Boolean
Default Value: false

Show Example:
jQuery

Switch between the values of the hideFirstTick option using the check box under the gauge.


                                    

                                    

hideLastLabel

Specifies whether or not to hide the last scale label.

Type: Boolean
Default Value: false

Show Example:
jQuery

Switch between the values of the hideLastLabel option using the check box under the gauge.


                                    

                                    

hideLastTick

Specifies whether or not to hide the last major tick on the scale.

Type: Boolean
Default Value: false

Show Example:
jQuery

Switch between the values of the hideLastTick option using the check box under the gauge.


                                    

                                    

label

Specifies common options for scale labels.

Type: Object

Scale labels represent textual values for major scale ticks. The label object exposes properties that allow you to specify custom text for scale labels and properties to change the text font.

Show Example:
jQuery

In this example, the text of the scale labels is customized using the customizeText option. In addition, the color and size options of the scale label text are changed.


                                    

                                    

majorTick

Specifies options of the gauge's major ticks.

Type: Object

Major ticks are calculated automatically based on the scale's startValue and endValue property values. They are visible by default. You can set a custom major tick interval or add custom major ticks using the tickInterval and customTickValues properties respectively. To specify the visibility of major ticks, use the visible and showCalculatedTicks properties. You can also specify the length, width and color of the major ticks using corresponding properties.

Show Example:
jQuery

In this example, the scale's major ticks are colored in black and lengthened up to 10 pixels. These ticks are generated with an interval of 50.


                                    

                                    

minorTick

Specifies options of the gauge's minor ticks.

Type: Object

Major and minor ticks are calculated automatically based on the scale's startValue and endValue property values. Major ticks are made visible by default. You can make minor ticks visible as well, using their visible property. In addition, you can set a custom minor tick interval or add custom minor ticks using the tickInterval and customTickValues properties respectively. You can also specify the length, width and color of the minor ticks using corresponding properties.

Show Example:
jQuery

In this example, the scale's minor ticks are colored in black and downscaled to 1 pixel. These ticks are generated with an interval of 5.


                                    

                                    

orientation

Specifies the orientation of scale ticks.

Type: String
Default Value: 'outside'
Accepted Values: 'outside' | 'center' | 'inside'

This property specifies the orientation of scale ticks relative to an invisible scale line.

Show Example:
jQuery

Change the orientation option using the drop-down menu under the gauge.


                                    

                                    

startValue

Specifies the start value for the scale of the gauge.

Type: Number
Default Value: 0

Show Example:
jQuery

In this example, the scale is divided using the values assigned to the startValue and endValue fields.