[英]Distance between x-axis labels and the chart in Highcharts
我正在尝试在Highcharts中创建x轴标签和图表之间的距离。 我尝试使用“距离”和“填充”,但均无效果。
chart: {
type: 'column'
},
title: {
text: 'Data input as column arrays'
},
data: {
columns: [
[null, 'Apples', 'Pears', 'Oranges'], // categories
['Blue', 1, 4, 3], // first series
['Black', 5, 4, 2] // second series
]
},
xAxis: {
categories: [
'First Category',
'Second Category',
'Third Category',
],
labels: {
style: {
fontFamily: 'openSans',
fontSize: '16px',
color: '#000000',
},
}
}
这是jsfiddle: http : //jsfiddle.net/aaq4zww5/2/
谢谢!
选项1:使用xAxis
的offset
:
xAxis: {
...
offset: 10,
},
选项2:在xAxis->labels
下使用y
:
labels: {
...
y: 25,
},
检查jsfiddle 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.