Class ColorPalette

Direct Known Subclasses:
ColorPalette.GrayRamp, ColorPalette.LinearRamp, ColorPalette.MonochromeRamp

public abstract class ColorPalette extends Object
This class provides a defined set of colors. Within each defined set colors may be retrieved as discrete values, or as a continuous ramp.

The ColorPalette class is abstract, but sub-classes are provided that implement linear and monochromatics ramps.

A number of predefined color palettes are defined as static fields.

  • Field Details

    • redMonochromatic

      public static final ColorPalette redMonochromatic
      Red monochromatic
    • orangeMonochromatic

      public static final ColorPalette orangeMonochromatic
      Orange monochromatic
    • yellowMonochromatic

      public static final ColorPalette yellowMonochromatic
      Yellow monochromatic
    • limeMonochromatic

      public static final ColorPalette limeMonochromatic
      Lime monochromatic
    • greenMonochromatic

      public static final ColorPalette greenMonochromatic
      Green monochromatic
    • bluegreenMonochromatic

      public static final ColorPalette bluegreenMonochromatic
      Blue green monochromatic
    • cyanMonochromatic

      public static final ColorPalette cyanMonochromatic
      Cyan monochromatic
    • blueMonochromatic

      public static final ColorPalette blueMonochromatic
      Blue monochromatic
    • purpleMonochromatic

      public static final ColorPalette purpleMonochromatic
      Purple monochromatic
    • magentaMonochromatic

      public static final ColorPalette magentaMonochromatic
      Magenta monochromatic
    • grayMonochromatic

      public static final ColorPalette grayMonochromatic
      Gray monochromatic
    • monochromatic

      public static final ColorPalette[] monochromatic
      Monochromatic gradient palettes
    • blueRedDichromatic

      public static final ColorPalette blueRedDichromatic
      Blues to Reds dichromatic
    • grayRedDichromatic

      public static final ColorPalette grayRedDichromatic
      Grays to Reds dichromatic
    • blueOrangeDichromatic

      public static final ColorPalette blueOrangeDichromatic
      Blues to Orange dichromatic
    • redOrangeDichromatic

      public static final ColorPalette redOrangeDichromatic
      Reds to Orange dichromatic
    • greenRedDichromatic

      public static final ColorPalette greenRedDichromatic
      Greens to Reds dichromatic
    • greenOrangeDichromatic

      public static final ColorPalette greenOrangeDichromatic
      Greens to Oranges dichromatic
    • yellowBrownDichromatic

      public static final ColorPalette yellowBrownDichromatic
    • yellowGreennDichromatic

      public static final ColorPalette yellowGreennDichromatic
    • coniferDeciduous

      public static final ColorPalette coniferDeciduous
    • dichromatic

      public static final ColorPalette[] dichromatic
      Dichromatic diverging gradient palettes
    • dichromaticSeq

      public static final ColorPalette[] dichromaticSeq
      Dichromatic sequential gradient palettes
    • redYellowGreen

      public static final ColorPalette redYellowGreen
      Reds to Yellows to Greens polychromatic
    • polychromaticGradientPalettes

      public static final ColorPalette[] polychromaticGradientPalettes
      Polychromatic gradient palettes
    • earthTones

      public static final ColorPalette earthTones
      Earth tones (legacy)
    • applesOranges

      public static final ColorPalette applesOranges
      Apples and oranges (legacy)
    • gems

      public static final ColorPalette gems
      Gems (legacy)
    • softShades

      public static final ColorPalette softShades
      Soft shades (legacy)
    • qci

      public static final ColorPalette qci
      Queen Charlotte Islands (legacy)
    • jamaicanJam

      public static final ColorPalette jamaicanJam
      Jamaican Jam (legacy)
    • primary

      public static final ColorPalette primary
      Primary (legacy)
    • elev1

      public static final ColorPalette elev1
      Elevation 1 (legacy)
    • blueLagoon

      public static final ColorPalette blueLagoon
      Blue Lagoon (legacy)
    • bcRainforest

      public static final ColorPalette bcRainforest
      BC Rainforest (legacy)
    • overTheRainbow

      public static final ColorPalette overTheRainbow
      Over the rainbow (legacy)
    • progressive

      public static final ColorPalette progressive
      Progressive (legacy)
    • legacy

      public static final ColorPalette[] legacy
      Legacy palette collection
    • brBG

      public static final ColorPalette brBG
      Diverging Brown Bluegreen
    • pRGn

      public static final ColorPalette pRGn
      Diverging Purple Green
    • piYG

      public static final ColorPalette piYG
      Diverging Pink Green
    • puOr

      public static final ColorPalette puOr
      Diverging Purple Orange
    • rdBu

      public static final ColorPalette rdBu
      Diverging Red Blue
    • rdGy

      public static final ColorPalette rdGy
      Diverging Red Gray
    • rdYlBu

      public static final ColorPalette rdYlBu
      Diverging Red Yellow Blue
    • rdYlGn

      public static final ColorPalette rdYlGn
      Diverging Red Yellow Green
    • spectral

      public static final ColorPalette spectral
      Diverging Spectral
    • accent

      public static final ColorPalette accent
      Qualitative Accent
    • dark2

      public static final ColorPalette dark2
      Qualitative Dark2
    • paired

      public static final ColorPalette paired
      Qualitative Paired
    • pastel1

      public static final ColorPalette pastel1
      Qualitative Pastel1
    • pastel2

      public static final ColorPalette pastel2
      Qualitative pastel2
    • set1

      public static final ColorPalette set1
      Qualitative Set1
    • set2

      public static final ColorPalette set2
      Qualitative Set2
    • set3

      public static final ColorPalette set3
      Qualitative Set3
    • blues

      public static final ColorPalette blues
      Sequential Blues
    • buGn

      public static final ColorPalette buGn
      Sequential Blue Green
    • buPu

      public static final ColorPalette buPu
      Sequential Blue Purple
    • gnBu

      public static final ColorPalette gnBu
      Sequential Green Blue
    • greens

      public static final ColorPalette greens
      Sequential Greens
    • greys

      public static final ColorPalette greys
      Sequential Greys
    • orRd

      public static final ColorPalette orRd
      Sequential Orange Red
    • oranges

      public static final ColorPalette oranges
      Sequential Oranges
    • puBu

      public static final ColorPalette puBu
      Sequential Purple Blue
    • puBuGn

      public static final ColorPalette puBuGn
      Sequential Purple Blue Green
    • puRd

      public static final ColorPalette puRd
      Sequential Purple Red
    • purples

      public static final ColorPalette purples
      Sequential Purples
    • rdPu

      public static final ColorPalette rdPu
      Sequential Red Purple
    • reds

      public static final ColorPalette reds
      Sequential Reds
    • ylGn

      public static final ColorPalette ylGn
      Sequential Yellow Green
    • ylGnBu

      public static final ColorPalette ylGnBu
      Sequential Yellow Green Blue
    • ylOrBr

      public static final ColorPalette ylOrBr
      Sequential Yellow Orange Brown
    • ylOrRd

      public static final ColorPalette ylOrRd
      Sequential Yellow Orange Red
    • algae

      public static final ColorPalette algae
      Sequential algae
    • amp

      public static final ColorPalette amp
      Sequential amp
    • deep

      public static final ColorPalette deep
      Sequential deep
    • dense

      public static final ColorPalette dense
      Sequential dense
    • fire

      public static final ColorPalette fire
      Diverging fire
    • gray

      public static final ColorPalette gray
      Sequential gray
    • haline

      public static final ColorPalette haline
      Sequential haline
    • ice

      public static final ColorPalette ice
      Sequential ice
    • matter

      public static final ColorPalette matter
      Sequential matter
    • rain

      public static final ColorPalette rain
      Sequential rain
    • rainbow

      public static final ColorPalette rainbow
      Diverging rainbow
    • solar

      public static final ColorPalette solar
      Sequential solar
    • speed

      public static final ColorPalette speed
      Sequential speed
    • tempo

      public static final ColorPalette tempo
      Sequential tempo
    • thermal

      public static final ColorPalette thermal
      Sequential thermal
    • turbid

      public static final ColorPalette turbid
      Sequential turbid
    • sequential

      public static final ColorPalette[] sequential
      Array of sequential palettes
    • diverging

      public static final ColorPalette[] diverging
      Array of diverging palettes
    • qualitative

      public static final ColorPalette[] qualitative
      Array of qualitative palettes
    • palettes

      public static final ColorPalette[] palettes
      A list of all statically defined palettes
  • Constructor Details

  • Method Details

    • getName

      public String getName()
      Return the name of the palette
    • getType

      public String getType()
      Return the category type of the palette
    • getColors

      public abstract Color[] getColors(int size)
      Return the colors provided by this palette.
      size - the number of colors requested
    • getGradientPalettes

      public static ColorPalette[] getGradientPalettes()
      Get a list of ColorPalette objects suiable for gradient maps
    • getPaletteMenu

      public static JPopupMenu getPaletteMenu(int size, boolean gradientOnly, ActionListener listener)