在Highcharts / Highstock中导出时如何更改轴标签大小

时间:2013-05-17 14:54:33

标签: highcharts highstock

我想在使用Highcharts / Highstock导出图像时更改轴标签大小。请参阅此fiddle

exporting: {    
    chartOptions: {
        rangeSelector: {
            enabled: false
        },
        yAxis: {
            labels: {
                style: {
                    color: '#000',
                    fontSize: '14px'
                }
            }
        }
    }
},

似乎无法正常工作。有什么建议吗?

2 个答案:

答案 0 :(得分:2)

将其放入图表中:{}

events: {
                    load: function(){

                        if (this.options.chart.forExport) {

                            Highcharts.each(this.series, function (series) {
                                series.yAxis.update({
                                    labels: {
                                        style: {
                                            fontSize: 6
                                        }
                                    }
                                });
                            });
                        }
                    }
}

答案 1 :(得分:1)

不幸的是,已知错误,在此向开发人员报告:https://github.com/highslide-software/highcharts.com/issues/1759