Class ColorPalette

java.lang.Object
org.jfree.chart.plot.ColorPalette
All Implemented Interfaces:
Serializable, Cloneable
Direct Known Subclasses:
GreyPalette, RainbowPalette

public abstract class ColorPalette extends Object implements Cloneable, Serializable
Deprecated.
This class is no longer supported (as of version 1.0.4). If you are creating contour plots, please try to use XYPlot and XYBlockRenderer.
Defines palette used by ContourPlot.
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected int[]
    Deprecated.
    Blue components.
    protected int[]
    Deprecated.
    Green components.
    protected boolean
    Deprecated.
    Inverse palette (ie, min and max colors are reversed).
    protected static final double
    Deprecated.
    Constant for converting loge to log10.
    protected boolean
    Deprecated.
    Logscale?
    protected double
    Deprecated.
    The max z-axis value.
    protected double
    Deprecated.
    The min z-axis value.
    protected String
    Deprecated.
    The palette name.
    protected int[]
    Deprecated.
    Red components.
    private static final long
    Deprecated.
    For serialization.
    protected boolean
    Deprecated.
    Controls whether palette colors are stepped (not continuous).
    protected double[]
    Deprecated.
    Tick values are stored for use with stepped palette.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated.
    Default contructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    Deprecated.
    Returns a clone of the palette.
    boolean
    Deprecated.
    Tests an object for equality with this instance.
    getColor(double value)
    Deprecated.
    Returns the color associated with a value.
    getColor(int izV)
    Deprecated.
    Returns a color.
    getColorLinear(double value)
    Deprecated.
    Returns Color by mapping a given value to a linear palette.
    getColorLog(double value)
    Deprecated.
    Returns Color by mapping a given value to a common log palette.
    double
    Deprecated.
    Returns the maximum Z value.
    double
    Deprecated.
    Returns the minimum Z value.
    getPaint(double value)
    Deprecated.
    Returns Paint by mapping a given value to a either a linear or common log palette as controlled by the value logscale.
    Deprecated.
    Returns the palette name.
    double[]
    Deprecated.
    Returns the tick values.
    int
    Deprecated.
    Returns a hash code.
    abstract void
    Deprecated.
    Called to initialize the palette's color indexes
    void
    Deprecated.
    Inverts Palette
    boolean
    Deprecated.
    Returns the inverse flag.
    boolean
    Deprecated.
    Returns the log-scale flag.
    boolean
    Deprecated.
    Returns the 'is-stepped' flag.
    void
    setInverse(boolean inverse)
    Deprecated.
    Sets the inverse flag.
    void
    setLogscale(boolean logscale)
    Deprecated.
    Sets the 'log-scale' flag.
    void
    setMaxZ(double newMaxZ)
    Deprecated.
    Sets the maximum Z value.
    void
    setMinZ(double newMinZ)
    Deprecated.
    Sets the minimum Z value.
    void
    setPaletteName(String paletteName)
    Deprecated.
    Sets the palette name.
    void
    setStepped(boolean stepped)
    Deprecated.
    Sets the stepped flag.
    void
    setTickValues(double[] newTickValues)
    Deprecated.
    Sets the tick values.
    void
    Deprecated.
    Store ticks.

    Methods inherited from class java.lang.Object

    finalize, getClass, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      Deprecated.
      For serialization.
      See Also:
    • minZ

      protected double minZ
      Deprecated.
      The min z-axis value.
    • maxZ

      protected double maxZ
      Deprecated.
      The max z-axis value.
    • r

      protected int[] r
      Deprecated.
      Red components.
    • g

      protected int[] g
      Deprecated.
      Green components.
    • b

      protected int[] b
      Deprecated.
      Blue components.
    • tickValues

      protected double[] tickValues
      Deprecated.
      Tick values are stored for use with stepped palette.
    • logscale

      protected boolean logscale
      Deprecated.
      Logscale?
    • inverse

      protected boolean inverse
      Deprecated.
      Inverse palette (ie, min and max colors are reversed).
    • paletteName

      protected String paletteName
      Deprecated.
      The palette name.
    • stepped

      protected boolean stepped
      Deprecated.
      Controls whether palette colors are stepped (not continuous).
    • log10

      protected static final double log10
      Deprecated.
      Constant for converting loge to log10.
  • Constructor Details

    • ColorPalette

      public ColorPalette()
      Deprecated.
      Default contructor.
  • Method Details

    • getColor

      public Paint getColor(double value)
      Deprecated.
      Returns the color associated with a value.
      Parameters:
      value - the value.
      Returns:
      The color.
    • getColor

      public Color getColor(int izV)
      Deprecated.
      Returns a color.
      Parameters:
      izV - the index into the palette (zero based).
      Returns:
      The color.
    • getColorLinear

      public Color getColorLinear(double value)
      Deprecated.
      Returns Color by mapping a given value to a linear palette.
      Parameters:
      value - the value.
      Returns:
      The color.
    • getColorLog

      public Color getColorLog(double value)
      Deprecated.
      Returns Color by mapping a given value to a common log palette.
      Parameters:
      value - the value.
      Returns:
      The color.
    • getMaxZ

      public double getMaxZ()
      Deprecated.
      Returns the maximum Z value.
      Returns:
      The value.
    • getMinZ

      public double getMinZ()
      Deprecated.
      Returns the minimum Z value.
      Returns:
      The value.
    • getPaint

      public Paint getPaint(double value)
      Deprecated.
      Returns Paint by mapping a given value to a either a linear or common log palette as controlled by the value logscale.
      Parameters:
      value - the value.
      Returns:
      The paint.
    • getPaletteName

      public String getPaletteName()
      Deprecated.
      Returns the palette name.
      Returns:
      The palette name.
    • getTickValues

      public double[] getTickValues()
      Deprecated.
      Returns the tick values.
      Returns:
      The tick values.
    • initialize

      public abstract void initialize()
      Deprecated.
      Called to initialize the palette's color indexes
    • invertPalette

      public void invertPalette()
      Deprecated.
      Inverts Palette
    • isInverse

      public boolean isInverse()
      Deprecated.
      Returns the inverse flag.
      Returns:
      The flag.
    • isLogscale

      public boolean isLogscale()
      Deprecated.
      Returns the log-scale flag.
      Returns:
      The flag.
    • isStepped

      public boolean isStepped()
      Deprecated.
      Returns the 'is-stepped' flag.
      Returns:
      The flag.
    • setInverse

      public void setInverse(boolean inverse)
      Deprecated.
      Sets the inverse flag.
      Parameters:
      inverse - the new value.
    • setLogscale

      public void setLogscale(boolean logscale)
      Deprecated.
      Sets the 'log-scale' flag.
      Parameters:
      logscale - the new value.
    • setMaxZ

      public void setMaxZ(double newMaxZ)
      Deprecated.
      Sets the maximum Z value.
      Parameters:
      newMaxZ - the new value.
    • setMinZ

      public void setMinZ(double newMinZ)
      Deprecated.
      Sets the minimum Z value.
      Parameters:
      newMinZ - the new value.
    • setPaletteName

      public void setPaletteName(String paletteName)
      Deprecated.
      Sets the palette name.
      Parameters:
      paletteName - the name.
    • setStepped

      public void setStepped(boolean stepped)
      Deprecated.
      Sets the stepped flag.
      Parameters:
      stepped - the flag.
    • setTickValues

      public void setTickValues(double[] newTickValues)
      Deprecated.
      Sets the tick values.
      Parameters:
      newTickValues - the tick values.
    • setTickValues

      public void setTickValues(List ticks)
      Deprecated.
      Store ticks. Required when doing stepped axis
      Parameters:
      ticks - the ticks.
    • equals

      public boolean equals(Object o)
      Deprecated.
      Tests an object for equality with this instance.
      Overrides:
      equals in class Object
      Parameters:
      o - the object to test.
      Returns:
      A boolean.
    • hashCode

      public int hashCode()
      Deprecated.
      Returns a hash code.
      Overrides:
      hashCode in class Object
      Returns:
      A hash code.
    • clone

      public Object clone() throws CloneNotSupportedException
      Deprecated.
      Returns a clone of the palette.
      Overrides:
      clone in class Object
      Returns:
      A clone.
      Throws:
      CloneNotSupportedException - never.