0

How to set tooltip for pie chart in older highcharts version like 2.0.2? The api reference is for the new 3.0 version, and tooltip formatter seems not work in older version.

I tried this:

chart_spec.tooltip.Formatter = function(){
return this.point.name + ': <b>' + Highcharts.numberFormat(this.percentage, 1) + '%</b>';

};

and this:

chart_spec.tooltip.pointFormat = '<span style="color:{series.color}">{series.name}</span>: <b>{point.percentage}</b><br/>';

Then pass chart_spec to build chart:

this.current_chart = new Highcharts.Chart(chart_spec);

But not work.. Tooltip formatter works for other chart type like column etc..

4

0 回答 0