Match Legend Colors to Series Color in the Dataset

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

Match Legend Colors to Series Color in the Dataset

Post by yc » Thu Apr 18, 2002 3:39 pm

I am having trouble in matching legend colors to the series colors in xyDataSet. I've changed the series colors using Plot.setSeriesPaint(..) method, but the legend colors are still defaulting to the standard color set.

Thanks.

David Gilbert

Re: Match Legend Colors to Series Color in the Dataset

Post by David Gilbert » Thu Apr 18, 2002 4:34 pm

I'm not sure how that could happen, since the legend calls the getSeriesPaint(...) method in the plot class to find the series color. Unless you have somehow added one legend to two different charts. Do you have any more details?

Regards,

DG.

Locked