如同这个问题 https://stackoverflow.com/questions/18784246/removing-the-white-line-between-slices-in-flot-pie-chart/22227464,但对于 Google 饼图:
如何删除 Google 饼图上切片之间的白线:
在上图中,我想删除绿色箭头突出显示的空白区域。
您可以通过设置来消除该差距pieSliceBorderColor
to "transparent"
。尝试以下操作谷歌代码游乐场 https://code.google.com/apis/ajax/playground/?type=visualization#pie_chart:
function drawVisualization() {
// Create and populate the data table.
var data = google.visualization.arrayToDataTable([
['Task', 'Hours per Day'],
['Work', 11],
['Eat', 2],
['Commute', 2],
['Watch TV', 2],
['Sleep', 7]
]);
// Create and draw the visualization.
new google.visualization.PieChart(document.getElementById('visualization')).
draw(data, {title:"So, how was your day?", pieSliceBorderColor:"transparent"});
}
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)