开发者

How do you vertically center legends using Google Charts API?

开发者 https://www.devze.com 2023-02-03 10:29 出处:网络
I\'m开发者_开发技巧 having trouble vertically centering the legends in Google Charts Pie Graph.Anyone have previously experience?Or is the best bet to code my own pie graph?

I'm开发者_开发技巧 having trouble vertically centering the legends in Google Charts Pie Graph. Anyone have previously experience? Or is the best bet to code my own pie graph?

Thanks in advance, Walker


Use the following in the charts option:

 var options = {
      title: 'My Daily Activities',
      legend: {'position':'top','alignment':'center'},
    };

The "legend.alignment" can be found in this documentation:

https://developers.google.com/chart/interactive/docs/gallery/piechart?csw=1


Are you using the chdlp and chma parameters?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号