横向坐标的坐标值文字方向设成竖的或一定角度就好了
生成JFreeChart chart之后利用如下代码 CategoryPlot plot = (CategoryPlot) chart.getPlot();
CategoryAxis categoryAxis = plot.getDomainAxis();
// 横轴上的 Lable 90度倾斜
categoryAxis.setCategoryLabelPositions(CategoryLabelPositions.UP_90);
生成JFreeChart chart之后利用如下代码 CategoryPlot plot = (CategoryPlot) chart.getPlot();
CategoryAxis categoryAxis = plot.getDomainAxis();
// 横轴上的 Lable 90度倾斜
categoryAxis.setCategoryLabelPositions(CategoryLabelPositions.UP_90);
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货