drawing line in ChartingHighLowRenderer.drawItem()

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
jim_athome
Posts: 4
Joined: Mon May 26, 2008 9:24 pm

drawing line in ChartingHighLowRenderer.drawItem()

Post by jim_athome » Sun Apr 18, 2010 1:41 am

Hello,

I've added an annotation in the drawItem() method and it shows when the chart finally displays.

I've also drawn a vertical line over the annotation that shows immediately and then I see it disappear. For the line I create a Shape object and added it to the EntityCollection:

Shape entityArea = new Rectangle2D.Double(xx - 1.0, Math.min(topLeftY, lowerRightY),
2.0, Math.abs(topLeftY - lowerRightY));

EntityCollection entities = info.getOwner().getEntityCollection();

addEntity(entities, entityArea, dataset, series, item, 0.0, 0.0);

I'm uncertain about why the line flickers to off.

The other issue that I'm having is understanding the coordinate system that is being used -- especially the dataArea. I did purchase the jfreechart-1.0.13-US.pdf file and it has helped a lot.

Thanks,
Jim

Locked