setToolTipGenerator() for XYAnnotations in an XYPlot?

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
Commander Salamander
Posts: 21
Joined: Sat Jan 05, 2008 2:14 am

setToolTipGenerator() for XYAnnotations in an XYPlot?

Post by Commander Salamander » Mon Jan 19, 2009 7:46 pm

I have a heavily customized XYPlot that contains a large number of XYPolygonAnnotations. I'd like to handle tooltip generation in a manner similar to that allowed for the XY data in an XYPlot... but I can't find any mention of such a capability in the developer's guide.

Am I missing something? Or does anyone have any ideas about how I might go about adding this capability?

Thanks!

skunk
Posts: 1087
Joined: Thu Jun 02, 2005 10:14 pm
Location: Brisbane, Australia

Post by skunk » Mon Jan 19, 2009 8:12 pm

Code: Select all

org.jfree.chart.annotations.XYPolygonAnnotation
defines these 2 methods

Code: Select all

public String getToolTipText()
public void setToolTipText(String text)
Remember that all annotations are immutable by design.

Commander Salamander
Posts: 21
Joined: Sat Jan 05, 2008 2:14 am

Post by Commander Salamander » Mon Jan 19, 2009 9:00 pm

Ah... not quite sure how I missed that. :oops:

Thanks.

Locked