net.sf.statcvs.charts
Class ChartUtils
Utility class for chart related stuff.
$Id: ChartUtils.java,v 1.3 2008/04/02 11:22:15 benoitx Exp $static Color | getStringColor(String s) - Returns a distinct
Color for a String argument.
|
getStringColor
public static Color getStringColor(String s)
Returns a distinct Color
for a String
argument.
The algorithm tries to provide different colors for similar strings, and
will return equal colors for equal strings. The colors will all have
similar brightness and maximum intensity. Useful for chart coloring.
s
- a String
to get a color for
- a distinct
Color
for a String
argument.
The algorithm tries to provide different colors for similar strings, and
will return equal colors for equal strings. The colors will all have
similar brightness and maximum intensity. Useful for chart coloring.