This is my process for creating the Gantt chart. I have a class wich is a subclass of another class called GanttRenderer.
setDataset(this.createDataset(s,dropFlag));
setTitle(null);
ChartPanel chartPanel = super.createGantt();
Calendar calendar = Calendar.getInstance();
Date startDate = date(1,Calendar.JANUARY,calendar.get(Calendar.YEAR));
Date endDate = date(31,Calendar.DECEMBER,calendar.get(Calendar.YEAR));
JFreeChart chart = this.getChart();
CategoryPlot plot = chart.getCategoryPlot();
DateAxis axis = (DateAxis) plot.getRangeAxis();
axis.setMinimumDate(startDate);
axis.setMaximumDate(endDate);
DateUnit tick = new DateUnit(Calendar.MONTH,12);
axis.setTickUnit(tick);
Any ideas?
Gantt Tick Units
Re: Gantt Tick Units
Hi John,
In 0.9.4, the DateUnit class is not used, it has been replaced with DateTickUnit.
Regards,
DG
In 0.9.4, the DateUnit class is not used, it has been replaced with DateTickUnit.
Regards,
DG