HowTo Annotate Stacked Bars?

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
rcdjbp
Posts: 6
Joined: Thu Jul 26, 2007 4:43 pm

HowTo Annotate Stacked Bars?

Post by rcdjbp » Tue Aug 14, 2007 4:08 pm

I would like to be able to annotate (or maybe label) the individual bars of a stacked bar chart. Is this possible?

Thanks
Thanks, Jabe
rcdjbp@yahoo.com

david.gilbert
JFreeChart Project Leader
Posts: 11734
Joined: Fri Mar 14, 2003 10:29 am
antibot: No, of course not.
Contact:

Post by david.gilbert » Wed Aug 15, 2007 11:21 am

You can assign an item label generator to the renderer. Annotations are possible too, but since they are usually positioned using absolute data coordinates, your code would need to take into account the fact that the renderer stacks the bars, to calculate where to place the annotation.
David Gilbert
JFreeChart Project Leader

:idea: Read my blog
:idea: Support JFree via the Github sponsorship program

Locked