small bug in StackedVerticalBarRenderer3D

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
jim

small bug in StackedVerticalBarRenderer3D

Post by jim » Wed Jun 19, 2002 7:43 pm

just discovered that the StackedVerticalBarRenderer3D craps out if this.info is null.

You made this fix in VerticalBarRenderer3D. From the change log:

* 11-Jun-2002 : Added check for (permitted) null info object, bug and fix reported by David
* Basten. Also updated Javadocs. (DG);


Basically the same fix needs to be made to StackedVerticalBarRenderer3D. At the bottom of drawCategoryItem need to wrap info dependent code with if statement:

if (this.info!=null) {
EntityCollection entities = this.info.getEntityCollection();
if (entities!=null) {
String tip="";
if (this.toolTipGenerator!=null) {
tip = this.toolTipGenerator.generateToolTip(data, series, category);
}
CategoryItemEntity entity = new CategoryItemEntity(bar, tip, series, category);
entities.addEntity(entity);
}
}


--jim

David Gilbert

Re: small bug in StackedVerticalBarRenderer3D

Post by David Gilbert » Wed Jun 19, 2002 10:23 pm

Hi Jim,

Thanks for reporting this. Someone else also mentioned it and the fix was committed to CVS earlier today.

Regards,

DG.

Locked