|
Name
|
Type
|
Default
|
|
title
|
String
|
''
|
Sets the title of the chart.
Example:
// select the chart element and change the title to 'New Title'
$('#jqxChart').jqxChart({title: 'New Title'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
description
|
String
|
''
|
Sets the description text of the chart.
Example:
// select the chart element and change the description to 'New description'
$('#jqxChart').jqxChart({description: 'New description'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
showBorderLine
|
Boolean
|
true
|
Determines whether to display the chart's border line
Example:
// hide the border line
$('#jqxChart').jqxChart({showBorderLine: 'false'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
borderLineColor
|
String
|
#888888
|
Sets the chart's border color.
Example:
// select the chart element and change the default border color.
$('#jqxChart').jqxChart({borderLineColor: 'Blue'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
borderLineWidth
|
Number
|
1
|
Sets the chart's border line width
Example:
$('#jqxChart').jqxChart({borderLineWidth: 1});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
backgroundColor
|
String
|
White
|
Sets the chart's background color.
Example:
// select the chart element and change the default background color.
$('#jqxChart').jqxChart({backgroundColor: 'Gray'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
backgroundImage
|
String
|
''
|
Sets the chart's background image.
Example:
// select the chart element and set background image.
$('#jqxChart').jqxChart({backgroundImage: '../images/chart_background.jpg'});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
showLegend
|
Boolean
|
false
|
Determines whether to show or hide the chart series legend.
Example:
// select the chart element and hides the legend
$('#jqxChart').jqxChart({showLegend: false});
// refresh the chart element
$('#jqxChart').jqxChart('refresh');
|
|
padding
|
Padding
|
{ left: 5, top: 5, right: 5, bottom: 5 }
|
Sets the left,top, right & bottom padding of the Chart.
Example:
$('#jqxChart').jqxChart({padding: { left: 10, top: 10, right: 10, bottom: 10 }});
$('#jqxChart').jqxChart('refresh');
|
|
titlePadding
|
Padding
|
{ left: 2, top: 2, right: 2, bottom: 2 }
|
Sets the padding of the chart's title.
Example:
$('#jqxChart').jqxChart({titlePadding: { left: 10, top: 10, right: 10, bottom: 10 }});
$('#jqxChart').jqxChart('refresh');
|
|
colorScheme
|
String
|
'scheme01'
|
Sets the chart's color pallete. jqxChart suppports 11 color schemes from 'scheme01'
to 'scheme11'.
Example:
$('#jqxChart').jqxChart({colorScheme: 'scheme06'});
$('#jqxChart').jqxChart('refresh');
|
|
greyScale
|
Boolean
|
false
|
Determines whether to display the chart using grey scale colors.
Example:
$('#jqxChart').jqxChart({greyScale: true});
|
|
showToolTips
|
Boolean
|
true
|
Enables or disables the chart tooltips.
Example:
$('#jqxChart').jqxChart({showToolTips: false});
$('#jqxChart').jqxChart('refresh');
|
|
toolTipShowDelay
|
Number
|
500
|
Determines the tooltips show delay in milliseconds. Values may range from 0 to 10000 [ms]
Example:
$('#jqxChart').jqxChart({toolTipShowDelay: 2000});
$('#jqxChart').jqxChart('refresh');
|
|
toolTipHideDelay
|
Number
|
4000
|
Determines the tooltips hide delay in milliseconds.
Example:
$('#jqxChart').jqxChart({toolTipHideDelay: 5000});
$('#jqxChart').jqxChart('refresh');
|
|
enabled
|
Boolean
|
true
|
Sets the chart widget in enabled or disabled state.
Example:
$('#jqxChart').jqxChart({enabled: false});
$('#jqxChart').jqxChart('refresh');
|
|
source
|
Object
|
null
|
Sets the chart's data source.
Example:
var source =
{
datatype: "tab",
datafields: [
{ name: 'Date'},
{ name: 'Referral'},
{ name: 'SearchPaid'},
{ name: 'SearchNonPaid'}
],
url: '../sampledata/website_analytics.txt'
};
var dataAdapter = new $.jqx.dataAdapter(source,
{
async: false,
autoBind: true,
});
// prepare jqxChart settings
var settings = {
title: "Visual Web Traffic Analysis",
description: "Unique site visitors in 2011",
source: dataAdapter,
categoryAxis:
{
dataField: 'Date',
unitInterval: Math.round(dataAdapter.records.length / 12),
showGridLines: false
},
colorScheme: 'scheme06',
seriesGroups:
[
{
type: 'stackedarea100',
valueAxis:
{
unitInterval: 500,
description: 'Daily visitors'
},
series: [
{ dataField: 'SearchNonPaid', displayText: 'Non-Paid Search Traffic' },
{ dataField: 'SearchPaid', displayText: 'Paid Search Traffic' },
{ dataField: 'Referral', displayText: 'Referral Traffic' }
]
}
]
};
// setup the chart
$('#jqxChart').jqxChart(settings);
|
|
categoryAxis
|
Object
|
null
|
Sets the Chart's categoryAxis.
Example:
categoryAxis:
{
dataField: 'Date',
formatFunction: function (value) {
var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
return months[value.getMonth()];
},
type: 'date',
baseUnit: 'month',
flip: false,
showTickMarks: true,
tickMarksInterval: 1,
tickMarksColor: '#888888',
unitInterval: 2,
showGridLines: true,
gridLinesInterval: 3,
gridLinesColor: '#888888'
}
- textRotationAngle - sets the rotation angle of the text.
- dataField - points to a data field in the data source.
- type - the type of the axis. Values can be 'default' or 'date' when displaying dates.
- baseUnit - the base unit when used with 'date' axis. Values can be 'year', 'month' or 'date'.
- valuesOnTicks - specifies whether the axis values are aligned with the tick marks.
- flip - specifies whether the axis values area displayed in reverse order.
- showTickMarks - when this property is true, the ticks are displayed in the categoryAxis.
- tickMarksInterval - sets the interval between each tick mark.
- tickMarksColor - sets the color of the tick marks.
- unitInterval - sets the interval between the units.
- showGridLines - displays the grid lines.
- gridLinesColor - set the grid lines color.
- gridLinesInterval - sets the interval between the grid lines.
- axisSize - sets the size of the categoryAxis.
- formatSettings - settings used to format the displayed values.
- formatFunction - custom function to format the displayed values.
- toolTipFormatSettings - settings used to format category axis values in tooltips.
- toolTipFormatFunction - custom function to format category axis values in tooltips.
|
|
seriesGroups
|
Object
|
null
|
The seriesGroups property is used to describe all series displayed on the chart. jqxChart supports multiple
series of different types and series grouping. Each series group may have its own Value Axis (Y-axis) which
allows you to have values with different scales displayed on the same chart at the same time. It also allows
you to display multiple series types together on the same chart. For example, you can display all series in
one group as lines and the series in a second group as columns.
seriesGroups:
[
{
type: 'stackedarea100',
orientation: 'vertical',
valueAxis:
{
unitInterval: 500,
flip: false,
minValue: 0,
maxValue: 3000,
displayValueAxis: true,
description: 'Daily visitors',
axisSize: 'auto',
tickMarksColor: '#888888'
},
series: [
{ dataField: 'SearchNonPaid', displayText: 'Non-Paid Search Traffic' },
{ dataField: 'SearchPaid', displayText: 'Paid Search Traffic' },
{ dataField: 'Referral', displayText: 'Referral Traffic' }
]
}
]
|
|
enableAnimations
|
Boolean
|
false
|
Determines if the animations are enabled. When you set this property it will turn on or off the animations
for all series in all seriesGroups in the chart. You can override this property for individual seriesGroups and series.
|
|
animationDuration
|
Number
|
1000
|
Determines the animations duration in milliseconds. The value must be between 0 and 5000.
If it is outside of this range jqxChart will reset it to the default value of 1000.
|
|
renderEngine
|
String
|
''
|
Determines the rendering engine used to display the chart. Possible values are 'SVG', 'VML' and 'HTML5'.
When the property is not set jqxChart will automatically select an optimal rendering engine depending on the browser capabilities.
Example:
$('#jqxChart').jqxChart({renderEngine: 'HTML5'});
$('#jqxChart').jqxChart('refresh');
|