首页 > 技术文章 > 关于highcharts中3d饼图指示文字带白边问题

menxiaojin 2020-07-15 14:44 原文

展示:

 

去掉白边,在

plotOptions.pie.dateLabels加入style:
plotOptions: {
                        pie: {
                            allowPointSelect: true,//每个扇块能否选中
                            cursor: 'pointer',//鼠标指针
                            depth: 50,//饼图的厚度
                            dataLabels: {
                                enabled: true,//是否显示饼图的线形tip
                                formatter: function() {     //设置字体与引导线和饼图颜色一致
                                    return  '<p style="color:'+ this.color+'">'+ this.point.name +'</p><br><p style="color:'+ this.color+'">'+ (this.percentage).toFixed(1)+'%</p>';
                                },
                                style: {
                                    textOutline: 'none'        //去掉文字白边
                                }
                            }
                        }
                    },

 

 

推荐阅读