Different color for item label of a series

A discussion forum for JFreeChart (a 2D chart library for the Java platform).
Locked
chiewboon
Posts: 3
Joined: Thu Jan 04, 2007 5:13 am

Different color for item label of a series

Post by chiewboon » Thu Jan 18, 2007 7:53 am

Hi,

I have a series that shows label on each data item.

Is there any way to have a different color label for the series such that item with values less that XX is white and more than XX is red.

Thank you very much.

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 » Thu Jan 18, 2007 6:09 pm

You could do this by subclassing the renderer and overriding the getItemLabelPaint(int, int) method.
David Gilbert
JFreeChart Project Leader

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

Locked