I am using Jfreechart to create pie charts. Values are displayed outside pie chart as labels. I want to display the values within the pie sectors only. How can i achieve this. Please can any one help me.
Thanks in advance
Use setSimpleLabels()
, as shown below; org.jfree.chart.demo.PieChartDemo1
is a good starting point.
PiePlot plot = (PiePlot) chart.getPlot();
plot.setSimpleLabels(true);
时间: 2024-10-13 11:40:29