Code: Select all
for(int i=0; i<alCharts.size(); i++){
subPlot = (CategoryPlot)alCharts.get(i).getPlot();
BarRenderer bRenderer = (BarRenderer)subPlot.getRenderer();
bRenderer = new BarRenderer3D(12.0, 8.0 );
bRenderer.setMaximumBarWidth(0.05);
bRenderer.setItemMargin(0.0);
bRenderer.setBaseToolTipGenerator(new StandardCategoryToolTipGenerator());
plot.add(subPlot, 1);
}
My charts are type JFreeChartWithData which is a subclass of JFreeChart that includes an arraylist of strings that holds the same data that is in the dataset that is used to build the chart. Here is the code for it, but it shouldn't be related to the problem:
Any idea what could be causing this?
Code: Select all
public class JFreeChartWithData extends JFreeChart {
/**
*
*/
private static final long serialVersionUID = 1L;
private ArrayList alData = new ArrayList();
private JFreeChart chart;
public JFreeChartWithData(String arg0, Font arg1, Plot arg2, boolean arg3) {
super(arg0, arg1, arg2, arg3);
// TODO Auto-generated constructor stub
}
public JFreeChartWithData(String arg0, Font arg1, Plot arg2, boolean arg3, ArrayList alListData) {
super(arg0, arg1, arg2, arg3);
this.alData = alListData;
}
public JFreeChartWithData(CategoryPlot plot, JFreeChart chart, ArrayList alListData){
super(plot);
this.chart=chart;
this.alData = alListData;
}
public boolean SetChartData(ArrayList alListData){
this.alData = alListData;
return true;
}
public ArrayList GetChartData(){
return this.alData;
}
public boolean SetChart(JFreeChart chart){
this.chart=chart;
return true;
}
public JFreeChart GetChart(){
return chart;
}
}