Hi All,
Version 0.7.0 is now available. The major change is the addition of combination charts, which have been implemented by Bill Kelemen.
This version of JFreeChart is dependent on version 0.5.2 of the JCommon class library, which you can also download from here (the runtime file is included in the JFreeChart download, but not the source code).
Regards,
DG.
Version 0.7.0 released...
RE: Version 0.7.0 released...
Hi David,
Good to see that you released JFreeChart 0.7.0. Here are some comments:
1. Somehow the HorizontalDateAxis is not showing grid lines anymore. I tried to add timeAxis.setShowGridLines(true) after creating the axis, but the following exception is then thrown when drawing the chart:
com.jrefinery.chart.demo.JFreeChartDemo
Exception occurred during event dispatching:
java.lang.IllegalArgumentException: null Stroke
at sun.java2d.SunGraphics2D.setStroke(SunGraphics2D.java:782)
at com.jrefinery.chart.HorizontalDateAxis.draw(HorizontalDateAxis.java:356)
at com.jrefinery.chart.XYPlot.draw(XYPlot.java:239)
at com.jrefinery.chart.JFreeChart.draw(JFreeChart.java:514)
at com.jrefinery.chart.JFreeChartPanel.paintComponent(JFreeChartPanel.java:261)
at javax.swing.JComponent.paint(JComponent.java:739)
at javax.swing.JComponent.paintChildren(JComponent.java:523)
at javax.swing.JComponent.paint(JComponent.java:748)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:546)
at javax.swing.JComponent.paintChildren(JComponent.java:523)
at javax.swing.JComponent.paint(JComponent.java:719)
at java.awt.GraphicsCallback$PaintCallback.run(GraphicsCallback.java:23)
at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:54)
at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:91)
at java.awt.Container.paint(Container.java:963)
at sun.awt.RepaintArea.paint(RepaintArea.java:298)
at sun.awt.windows.WComponentPeer.handleEvent(WComponentPeer.java:199)
at java.awt.Component.dispatchEventImpl(Component.java:2665)
at java.awt.Container.dispatchEventImpl(Container.java:1216)
at java.awt.Window.dispatchEventImpl(Window.java:918)
at java.awt.Component.dispatchEvent(Component.java:2499)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:336)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:134)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:96)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:88)
I'm not sure where to fix this bug.
2. The new CandleSticksPlot was not working (using HighLowDataset) as it was using the old XYDataset format to retrieve the high/low/open/close data. I modified it to use the current HighLowDataset. Additionally it was getting a reference to the JFreePanel that contained the Plot through "getChart().listeners.get(1)" which didn't work for CombinedPlots. Therefore I added setPanel()/getPanel() methods to JFreeChart and Plot and modified JFreeChartPanel to call "chart.setPanel(this)" inside its constructor. After this, CandleSticksPlot can simply get the panel with "chart.getPanel()".
3. There was a bug in VerticalNumberAxis that was displaying the axis vertically drawn label on top of the tick labels.
4. I modified JFreeChartDemo and added a CandleSticksPlot demo as well as CandleSticksPlot inside a CombinedPlot.
I'll sent you an email with these fixes.
Regards,
Bill
Good to see that you released JFreeChart 0.7.0. Here are some comments:
1. Somehow the HorizontalDateAxis is not showing grid lines anymore. I tried to add timeAxis.setShowGridLines(true) after creating the axis, but the following exception is then thrown when drawing the chart:
com.jrefinery.chart.demo.JFreeChartDemo
Exception occurred during event dispatching:
java.lang.IllegalArgumentException: null Stroke
at sun.java2d.SunGraphics2D.setStroke(SunGraphics2D.java:782)
at com.jrefinery.chart.HorizontalDateAxis.draw(HorizontalDateAxis.java:356)
at com.jrefinery.chart.XYPlot.draw(XYPlot.java:239)
at com.jrefinery.chart.JFreeChart.draw(JFreeChart.java:514)
at com.jrefinery.chart.JFreeChartPanel.paintComponent(JFreeChartPanel.java:261)
at javax.swing.JComponent.paint(JComponent.java:739)
at javax.swing.JComponent.paintChildren(JComponent.java:523)
at javax.swing.JComponent.paint(JComponent.java:748)
at javax.swing.JLayeredPane.paint(JLayeredPane.java:546)
at javax.swing.JComponent.paintChildren(JComponent.java:523)
at javax.swing.JComponent.paint(JComponent.java:719)
at java.awt.GraphicsCallback$PaintCallback.run(GraphicsCallback.java:23)
at sun.awt.SunGraphicsCallback.runOneComponent(SunGraphicsCallback.java:54)
at sun.awt.SunGraphicsCallback.runComponents(SunGraphicsCallback.java:91)
at java.awt.Container.paint(Container.java:963)
at sun.awt.RepaintArea.paint(RepaintArea.java:298)
at sun.awt.windows.WComponentPeer.handleEvent(WComponentPeer.java:199)
at java.awt.Component.dispatchEventImpl(Component.java:2665)
at java.awt.Container.dispatchEventImpl(Container.java:1216)
at java.awt.Window.dispatchEventImpl(Window.java:918)
at java.awt.Component.dispatchEvent(Component.java:2499)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:336)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:134)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:96)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:88)
I'm not sure where to fix this bug.
2. The new CandleSticksPlot was not working (using HighLowDataset) as it was using the old XYDataset format to retrieve the high/low/open/close data. I modified it to use the current HighLowDataset. Additionally it was getting a reference to the JFreePanel that contained the Plot through "getChart().listeners.get(1)" which didn't work for CombinedPlots. Therefore I added setPanel()/getPanel() methods to JFreeChart and Plot and modified JFreeChartPanel to call "chart.setPanel(this)" inside its constructor. After this, CandleSticksPlot can simply get the panel with "chart.getPanel()".
3. There was a bug in VerticalNumberAxis that was displaying the axis vertically drawn label on top of the tick labels.
4. I modified JFreeChartDemo and added a CandleSticksPlot demo as well as CandleSticksPlot inside a CombinedPlot.
I'll sent you an email with these fixes.
Regards,
Bill
RE: Version 0.7.0 released...
Hi Bill,
Thanks for the bug reports! I'll take a look at them as soon as I can.
Number 3 I have seen, but I'm not sure about the fix yet. It seems to happen with the JDK that ships with Borland JBuilder 5, but not the IBM JDK that ships with SuSE Linux 7.3 (sorry I don't have the version numbers to hand). I'll do some more digging around and see what I can find out...
Regards,
DG.
Thanks for the bug reports! I'll take a look at them as soon as I can.
Number 3 I have seen, but I'm not sure about the fix yet. It seems to happen with the JDK that ships with Borland JBuilder 5, but not the IBM JDK that ships with SuSE Linux 7.3 (sorry I don't have the version numbers to hand). I'll do some more digging around and see what I can find out...
Regards,
DG.
RE: Version 0.7.0 released...
Hi David,
For Number 3, I am using JBuilder so that could be the problem. I did a code change that fixed for me, but maybe causes other problems on other JDK's.
Regards,
Bill
For Number 3, I am using JBuilder so that could be the problem. I did a code change that fixed for me, but maybe causes other problems on other JDK's.
Regards,
Bill