-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi.
I would like to paint each column of my bar chart with a different color, is it possible ?
I created a JFreeChartEngine and I know how to color a serie but not a column :(
private class Engine extends JFreeChartEngine { public boolean prepareJFreeChart(JFreeChart jfchart, Chart chart) { CategoryPlot plot = (CategoryPlot) jfchart.getPlot(); BarRenderer3D renderer = (BarRenderer3D) plot.getRenderer(); Color[] colors = App.getDefaultChartColors(); renderer.setSeriesPaint(0, colors[0]); return false; } }
Asked: 2011-11-02 13:49:37 +0800
Seen: 276 times
Last updated: Nov 02 '11