Hierarchy
Ext.chart.axis.AbstractExt.chart.axis.Axis
Defines axis for charts. The axis position, type, style can be configured. The axes are defined in an axes array of configuration objects where the type, field, grid and other configuration options can be set. To know more about how to create a Chart please check the Chart class documentation. Here's an example for the axes part: An example of axis for a series (in this case for an area chart that has multiple layers of yFields) could be:
axes: [{
type: 'Numeric',
grid: true,
position: 'left',
fields: ['data1', 'data2', 'data3'],
title: 'Number of Hits',
grid: {
odd: {
opacity: 1,
fill: '#ddd',
stroke: '#bbb',
'stroke-width': 1
}
},
minimum: 0
}, {
type: 'Category',
position: 'bottom',
fields: ['name'],
title: 'Month of the Year',
grid: true,
label: {
rotate: {
degrees: 315
}
}
}]
In this case we use a Numeric
axis for displaying the values of the Area series and a Category
axis for displaying the names of
the store elements. The numeric axis is placed on the left of the screen, while the category axis is placed at the bottom of the chart.
Both the category and numeric axes have grid
set, which means that horizontal and vertical lines will cover the chart background. In the
category axis the labels will be rotated so they can fit the space better.
If minimum
and maximum
are specified it forces the number of major ticks to the specified value.
If minimum
and maximum
are specified it forces the number of major ticks to the specified value.
The number of small ticks between two major ticks. Default is zero.
The number of small ticks between two major ticks. Default is zero.
Renders the axis into the screen and updates it's position.
Renders the axis into the screen and updates it's position.