Code: Select all
function drawXAxisBackground() {
var chart = this,
xAxis = chart.xAxis[0],
height = 155,
position = {
x: chart.plotLeft,
y: chart.plotTop - height - 20,
width: xAxis.len,
height: height
};
if (!xAxis.background) {
xAxis.background = chart.renderer.rect().attr({
fill: 'grey',
}).attr(position).add();
} else {
xAxis.background.animate(position);
};
};
See the following image: