答案 0 :(得分:1)
使用pointWidth属性,一个像素值,指定每个列或条的固定宽度:
plotOptions: {
series: {
stacking: 'percent',
pointWidth: 5
}
},
<强> JSFiddle 强>
答案 1 :(得分:1)
要在highcharts.js中增加两个条之间的宽度,可以使用groupPadding,
API:http://api.highcharts.com/highcharts#plotOptions.bar.groupPadding
示例:http://jsfiddle.net/6j3y54na/2/
groupPadding: 0.2
如果你想增加同一组中栏之间的差距,那么你可以使用pointPadding
API:http://api.highcharts.com/highcharts#plotOptions.bar.pointPadding
答案 2 :(得分:0)
pointWidth是设置条宽宽度的参数。请参阅此jsFiddle
$(function () {
$('#container').highcharts({
chart: {
type: 'bar',
marginLeft: 50,
marginBottom: 90
},
xAxis: {
categories: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']
},
plotOptions: {
series: {
stacking: 'percent', pointWidth: 4
}
},
series: [{
data: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4]
}, {
data: [144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4, 29.9, 71.5, 106.4, 129.2]
}]
});
});