org.jfree.chart.plot
public abstract class ColorPalette extends Object implements Cloneable, Serializable
Deprecated: This class is no longer supported. If you are creating contour plots, please try to use XYPlot and XYBlockRenderer.
Defines palette used by ContourPlot.Field Summary | |
---|---|
protected int[] | b Blue components. |
protected int[] | g Green components. |
protected boolean | inverse Inverse palette (ie, min and max colors are reversed). |
protected static double | log10 Constant for converting loge to log10. |
protected boolean | logscale Logscale? |
protected double | maxZ The max z-axis value. |
protected double | minZ The min z-axis value. |
protected String | paletteName The palette name. |
protected int[] | r Red components. |
protected boolean | stepped Controls whether palette colors are stepped (not continuous). |
protected double[] | tickValues Tick values are stored for use with stepped palette. |
Constructor Summary | |
---|---|
ColorPalette()
Default contructor. |
Method Summary | |
---|---|
Object | clone()
Returns a clone of the palette.
|
boolean | equals(Object o)
Tests an object for equality with this instance.
|
Paint | getColor(double value)
Returns the color associated with a value.
|
Color | getColor(int izV)
Returns a color.
|
Color | getColorLinear(double value)
Returns Color by mapping a given value to a linear palette.
|
Color | getColorLog(double value)
Returns Color by mapping a given value to a common log palette.
|
double | getMaxZ()
Returns the maximum Z value.
|
double | getMinZ()
Returns the minimum Z value.
|
Paint | getPaint(double value)
Returns Paint by mapping a given value to a either a linear or common
log palette as controlled by the value logscale.
|
String | getPaletteName()
Returns the palette name.
|
double[] | getTickValues()
Returns the tick values.
|
int | hashCode()
Returns a hash code.
|
abstract void | initialize()
Called to initialize the palette's color indexes |
void | invertPalette()
Inverts Palette |
boolean | isInverse()
Returns the inverse flag.
|
boolean | isLogscale()
Returns the log-scale flag.
|
boolean | isStepped()
Returns the 'is-stepped' flag.
|
void | setInverse(boolean inverse)
Sets the inverse flag.
|
void | setLogscale(boolean logscale)
Sets the 'log-scale' flag.
|
void | setMaxZ(double newMaxZ)
Sets the maximum Z value.
|
void | setMinZ(double newMinZ)
Sets the minimum Z value.
|
void | setPaletteName(String paletteName)
Sets the palette name.
|
void | setStepped(boolean stepped)
Sets the stepped flag.
|
void | setTickValues(double[] newTickValues)
Sets the tick values.
|
void | setTickValues(List ticks)
Store ticks. |
Returns: A clone.
Throws: CloneNotSupportedException never.
Parameters: o the object to test.
Returns: A boolean.
Parameters: value the value.
Returns: The color.
Parameters: izV the index into the palette (zero based).
Returns: The color.
Parameters: value the value.
Returns: The color.
Parameters: value the value.
Returns: The color.
Returns: The value.
Returns: The value.
Parameters: value the value.
Returns: The paint.
Returns: The palette name.
Returns: The tick values.
Returns: A hash code.
Returns: The flag.
Returns: The flag.
Returns: The flag.
Parameters: inverse the new value.
Parameters: logscale the new value.
Parameters: newMaxZ the new value.
Parameters: newMinZ the new value.
Parameters: paletteName the name.
Parameters: stepped the flag.
Parameters: newTickValues the tick values.
Parameters: ticks the ticks.