Name
|
Type
|
Default
|
animationDuration
|
Number
|
400
|
Sets or gets jqxGauge's animation duration [ms].
Code examples
Set the animationDuration property.
$('#jqxGauge').jqxGauge({ animationDuration: 300 });
Get the animationDuration property.
var animationDuration = $('#jqxGauge').jqxGauge('animationDuration');
|
border
|
Object
|
{ size: '10%', style: { stroke: '#cccccc'}, visible: true, showGradient: true }
|
Sets or gets the gauge's properties for it's border.
Possible Values:
'size'-specifies the size of the border. Border's size can be set in percentage or in pixels
'visible'-indicates if the border will be visible
'style'-sets border style (color and thickness)
'showGradient' - whether a gradient background will be used
Code examples
Set the border property.
$('#jqxGauge').jqxGauge({ border: { size: '11%', style: { stroke: '#898989'}, visible: true }});
Get the border property.
var border = $('#jqxGauge').jqxGauge('border');
|
caption
|
Object
|
{ value: '', position: 'bottom', offset: [0, 0], visible: true }
|
Sets or gets the gauge's properties for it's caption.
Possible Values:
'value' - specifies the text
'position' - specifies the caption position. There four different positions - top, bottom, left and right. You can customize the position using the offset property described bellow
'offset' - array with two number elements. The first one indicates the left offset and the second one the top offset
'visible' - indicates whether the caption will be visible
Code examples
Set the caption property.
$('#jqxGauge').jqxGauge({ caption: { value: 'jQWidgets', position: 'bottom', offset: [0, 10], visible: true }});
Get the caption property.
var caption = $('#jqxGauge').jqxGauge('caption');
|
cap
|
Object
|
{ size: '4%', style: { fill: 'theme-specific-color', stroke: 'theme-specific-color' } , visible: true }
|
Sets or gets the gauge's properties for it's cap.
Possible Values:
'size' - specifies the gauge's size. This property can be set as percentage or in pixels
'visible' - indicates whether the cap will be visible
'style' - specifies the gauge's cap styles. Here you can set it's fill or stroke colors
Code examples
Set the cap property.
$('#jqxGauge').jqxGauge({ cap: { size: '5%', style: { fill: '#ff0000', stroke: '#00ff00' } , visible: true }});
Get the cap property.
var cap = $('#jqxGauge').jqxGauge('cap');
|
colorScheme
|
String
|
'scheme01'
|
Sets the gauge's color pallete. jqxGauge suppports 11 color schemes from 'scheme01'
to 'scheme11'.
Code examples
Set the colorScheme property.
$('#jqxGauge').jqxGauge({ colorScheme: 10 });
Get the colorScheme property.
var colorScheme = $('#jqxGauge').jqxGauge('colorScheme');
|
disabled
|
Boolean
|
false
|
Sets or gets whether the jqxGauge is disabled.
Code examples
Set the disabled property.
$('#jqxGauge').jqxGauge({ disabled: true });
Get the disabled property.
var disabled = $('#jqxGauge').jqxGauge('disabled');
|
easing
|
String
|
linear
|
Sets or gets jqxGauge's animation easing.
Possible Values:
'linear'
'easeOutBack'
'easeInQuad'
'easeInOutCirc'
'easeInOutSine'
'easeOutCubic'
Code examples
Set the easing property.
$('#jqxGauge').jqxGauge({ easing: 300 });
Get the easing property.
var easing = $('#jqxGauge').jqxGauge('easing');
|
endAngle
|
Number
|
270
|
Sets or gets gauge's endAngle. This property specifies the end of the gauge's scale and is measured in degrees.
Code examples
Set the endAngle property.
$('#jqxGauge').jqxGauge({ endAngle: 70 });
Get the endAngle property.
var endAngle = $('#jqxGauge').jqxGauge('endAngle');
|
height
|
Number
|
350
|
Sets or gets the gauge's height. This property accepts size in pixels and percentage.
Code examples
Set the height property.
$('#jqxGauge').jqxGauge({ height: 400 });
Get the height property.
var height = $('#jqxGauge').jqxGauge('height');
|
int64
|
Boolean
|
false
|
Enables the jqxGauge 64-bit number support.
Note: If this property is set to true, the properties value,
min, max, ranges.startValue,
ranges.endValue, ticksMinor.interval, ticksMajor.interval
and labels.interval should be set to string values.
Code examples
Set the int64 property.
$('#jqxGauge').jqxGauge({ int64: true });
Get the int64 property.
var int64 = $('#jqxGauge').jqxGauge('int64');
|
labels
|
Object
|
{ distance: '38%', position: 'none', interval: 20, offset: [0, -10], visible: true, formatValue: function (value) {
return value;
}}
|
Sets or gets the gauge's properties for it's labels.
Possible Values:
'distance' - specifies the labels distance from the gauge's center. This value could be set in percents ('0%' - '100%') or using pixels. This property is with lower priority than the position property
'position' - specifies the gauge's labels position. Possible values for this property are 'inside', 'outside' and 'none' (if you want to use the distance property). If it's value is inside the labels are going to be shown inside the scale otherwise they will be shown outside. This property is with higher priority than the distance property
'interval' - specifies labels's frequency
'offset' - specifies labels's offset. This property is array with two elements. The first one is the left offset and the second one is the top offset
'style' - specifies the gauge's pointer style. Here you can set it's fill or stroke color
'formatValue' - callback used for formatting the label. This function accepts a single parameter which the user can format and return to the labels renderer
'visible' - indicates whether the labels will be visible
Code examples
Set the labels property.
$('#jqxGauge').jqxGauge({ labels: { distance: '50px', position: 'inside', interval: 20, offset: [0, -10], visible: true, formatValue: function (value) {return value;}}});
Get the labels property.
var labels = $('#jqxGauge').jqxGauge('labels');
|
min
|
Number
|
0
|
Sets or gets gauge's minimum value.
Code examples
Set the min property.
$('#jqxGauge').jqxGauge({ min: 10 });
Get the min property.
var min = $('#jqxGauge').jqxGauge('min');
|
max
|
Number
|
220
|
Sets or gets jqxGauge's max value.
Code examples
Set the max property.
$('#jqxGauge').jqxGauge({ max: 20 });
Get the max property.
var max = $('#jqxGauge').jqxGauge('max');
|
pointer
|
Object
|
{ pointerType: 'default', style: { fill: 'theme-specific-color', stroke: 'theme-specific-color' }, length: '70%', width: '2%', visible: true }
|
Sets or gets the gauge's properties for it's pointer.
Possible Values:
'pointerType' - specifies the pointer type. Possible values for this property are - 'default' and 'rectangle'. If it's value is 'default' the pointer will be arrow otherwise it'll be rectangle
'style' - specifies the gauge's pointer style. Here you can set it's fill or stroke color
'width' - specifies pointer's width. This property can be set in percents ('0%' - '100%') or in pixels
'length' - specifies pointer's length. This property can be set in percents ('0%' - '100%') or in pixels
'visible' - indicates whether the pointer will be visible
Code examples
Set the pointer property.
$('#jqxGauge').jqxGauge({ pointer: { pointerType: 'default', style: { fill: '#ff0000', stroke: '#ff0000' }, length: '80%', width: '3%', visible: true }});
Get the pointer property.
var pointer = $('#jqxGauge').jqxGauge('pointer');
|
radius
|
Number
|
'50%'
|
Sets or gets gauge's radius. This property accepts size in pixels and percentage.
Code examples
Set the radius property.
$('#jqxGauge').jqxGauge({ radius: 200 });
Get the radius property.
var radius = $('#jqxGauge').jqxGauge('radius');
|
ranges
|
Array
|
[]
|
This property is array of objects. Each object is different range. The range is colored area with specified size.
Possible Values:
'startValue'-the value from which the range will start
'endValue'-the value where the current range will end
'startWidth'-the width of the range in it's start
'endWidth'-the end width of the range
'startDistance [optional]'-this property is measured in pixels or percentage. It indicates the distance from the gauge's outer boundary to the start of the range
'endDistance [optional]'-this property is measured in pixels or percentage. It indicates the distance from the gauge's outer boundary to the end of the range
'style'-this property is object containing style information for the range. It accepts properties like 'fill', 'stroke', etc.
Code examples
Set the showRanges property.
var ranges = [{
startValue: 0,
endValue: 35,
startWidth: 1,
endWidth: 5,
startDistance: '5%',
endDistance: '5%',
style: {
fill: '#dddddd',
stroke: '#dddddd'
}
},
{
startValue: 35,
endValue: 55,
startWidth: 5,
endWidth: 10,
startDistance: '5%',
endDistance: '5%',
style: {
fill: '#dddddd',
stroke: '#dddddd'
}
}];
$('#jqxGauge').jqxGauge({ ranges: ranges });
Get the ranges property.
var ranges = $('#jqxGauge').jqxGauge('ranges');
|
startAngle
|
Number
|
30
|
Sets or gets gauge's startAngle. This property specifies the beggining of the gauge's scale and is measured in degrees.
Code examples
Set the startAngle property.
$('#jqxGauge').jqxGauge({ startAngle: 10 });
Get the startAngle property.
var startAngle = $('#jqxGauge').jqxGauge('startAngle');
|
showRanges
|
Boolean
|
true
|
This property indicates whether the gauge's ranges will be visible.
Code examples
Set the showRanges property.
$('#jqxGauge').jqxGauge({ showRanges: false });
Get the showRanges property.
var showRanges = $('#jqxGauge').jqxGauge('showRanges');
|
style
|
Object
|
{ fill: '#ffffff', stroke: '#ffffff' }
|
Sets or gets the gauge's style.
Code examples
Set the style property.
$('#jqxGauge').jqxGauge({ style: { fill: '#cccccc', stroke: '#cccccc' }});
Get the style property.
var style = $('#jqxGauge').jqxGauge('style');
|
ticksMajor
|
Object
|
{ size: '10%', interval: 5, style: { stroke: '#898989'}, visible: true }
|
Sets or gets the gauge's properties for it's major ticks.
Possible Values:
'size'-specifies the length of the tick. This property is measured in pixels or percentage
'interval'-specifies the ticks frequency. With interval equals to 5 each fifth value of the gauge will have a major tick
'visible'-indicates if the major ticks will be visible
'style'-sets ticks style (color and thickness)
Code examples
Set the ticksMajor property.
$('#jqxGauge').jqxGauge({ ticksMajor: { size: '10px', interval: 15, style: { stroke: '#898989'}, visible: true }});
Get the ticksMajor property.
var ticksMajor = $('#jqxGauge').jqxGauge('ticksMajor');
|
ticksMinor
|
Object
|
{ size: '10%', interval: 5, style: { stroke: '#898989'}, visible: true }
|
Sets or gets the gauge's properties for it's minor ticks.
Possible Values:
'size'-specifies the length of the tick. This property can be set in pixels or in percentag
'interval'-specifies the ticks frequency. With interval equals to 5 each fifth value of the gauge will have a minor tick
'visible'-indicates if the minor ticks will be visible
'style'-sets ticks style (color and thickness)
Code examples
Set the ticksMinor property.
$('#jqxGauge').jqxGauge({ ticksMinor: { size: '5%', interval: 15, style: { stroke: '#898989'}, visible: true }});
Get the ticksMinor property.
var ticksMinor = $('#jqxGauge').jqxGauge('ticksMinor');
|
ticksDistance
|
Number
|
'20%"
|
Sets and gets the ticks position. This property can be specified using percents (between '0%' and '100%') or using pixels.
If the ticksRadius is '0%' this will position the ticks in the outer border of the gauge and if it's '100%' ticks will be positioned near the center.
Code examples
Set the ticksDistance property.
$('#jqxGauge').jqxGauge({ ticksDistance: '26' });
Get the ticksDistance property.
var ticksDistance = $('#jqxGauge').jqxGauge('ticksDistance');
|
value
|
Number
|
0
|
Sets or gets gauge's value.
Code examples
Set the value property.
$('#jqxGauge').jqxGauge({ value: 15 });
Get the value property.
var value = $('#jqxGauge').jqxGauge('value');
|
width
|
Number
|
350
|
Sets or gets the gauge's width. This property accepts size in pixels and percentage.
Code examples
Set the width property.
$('#jqxGauge').jqxGauge({ width: 400 });
Get the width property.
var width = $('#jqxGauge').jqxGauge('width');
|