2016-08-18 130 views

回答

6

您只需在图表选项中设置“cutoutPercentage”选项即可。圆环图的默认值是50.数字接近100会在中间有更多的空白空间,接近0的数字在圆环中间会有更少的空白空间。

在你的控制器:

$scope.options = {cutoutPercentage: 75}; 
$scope.data = [213, 546]; 
$scope.labels = ['Label 1', 'Label 2']; 

在你HTML:

<canvas class="chart chart-doughnut" chart-data="data" chart-labels="labels" chart-options="options"> </canvas>