jxl.format
Class Colour

java.lang.Object
  |
  +--jxl.format.Colour
Direct Known Subclasses:
Colour

public class Colour
extends java.lang.Object

Enumeration class which contains the various colours available within the standard Excel colour palette


Field Summary
static Colour BLACK
           
static Colour BLUE
           
static Colour BRIGHT_GREEN
           
static Colour BROWN
           
private static Colour[] colours
          The list of colours
static Colour DARK_BLUE
           
static Colour DARK_RED
           
static Colour DEFAULT_BACKGROUND
           
static Colour GOLD
           
static Colour GRAY_25
           
static Colour GRAY_50
           
static Colour GRAY_80
           
static Colour GREEN
           
static Colour LIGHT_BLUE
           
static Colour LIGHT_GREEN
           
static Colour LIGHT_ORANGE
           
static Colour LIME
           
static Colour ORANGE
           
static Colour PALE_BLUE
           
static Colour PINK
           
static Colour RED
           
static Colour ROSE
           
static Colour SKY_BLUE
           
private  java.lang.String string
          The display string for the colour.
static Colour UNKNOWN
           
private  int value
          The internal numerical representation of the colour
static Colour VERY_LIGHT_ORANGE
           
static Colour VERY_LIGHT_YELLOW
           
static Colour VIOLET
           
static Colour WHITE
           
static Colour YELLOW
           
 
Constructor Summary
protected Colour(int val, java.lang.String s)
          Private constructor
 
Method Summary
static Colour getColour(int val)
          Gets the colour from the value
 java.lang.String getDescription()
          Gets the string description for display purposes
 int getValue()
          Gets the value of this colour.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

value

private int value
The internal numerical representation of the colour

string

private java.lang.String string
The display string for the colour. Used when presenting the format information

colours

private static Colour[] colours
The list of colours

UNKNOWN

public static final Colour UNKNOWN

BLACK

public static final Colour BLACK

WHITE

public static final Colour WHITE

GRAY_80

public static final Colour GRAY_80

GRAY_50

public static final Colour GRAY_50

GRAY_25

public static final Colour GRAY_25

RED

public static final Colour RED

DARK_RED

public static final Colour DARK_RED

ORANGE

public static final Colour ORANGE

LIGHT_ORANGE

public static final Colour LIGHT_ORANGE

VERY_LIGHT_ORANGE

public static final Colour VERY_LIGHT_ORANGE

BLUE

public static final Colour BLUE

LIGHT_BLUE

public static final Colour LIGHT_BLUE

PALE_BLUE

public static final Colour PALE_BLUE

DARK_BLUE

public static final Colour DARK_BLUE

SKY_BLUE

public static final Colour SKY_BLUE

YELLOW

public static final Colour YELLOW

VERY_LIGHT_YELLOW

public static final Colour VERY_LIGHT_YELLOW

GOLD

public static final Colour GOLD

GREEN

public static final Colour GREEN

BRIGHT_GREEN

public static final Colour BRIGHT_GREEN

LIGHT_GREEN

public static final Colour LIGHT_GREEN

LIME

public static final Colour LIME

BROWN

public static final Colour BROWN

VIOLET

public static final Colour VIOLET

PINK

public static final Colour PINK

ROSE

public static final Colour ROSE

DEFAULT_BACKGROUND

public static final Colour DEFAULT_BACKGROUND
Constructor Detail

Colour

protected Colour(int val,
                 java.lang.String s)
Private constructor
Parameters:
val -  
s - the display string
Method Detail

getValue

public int getValue()
Gets the value of this colour. This is the value that is written to the generated Excel file
Returns:
the binary value

getDescription

public java.lang.String getDescription()
Gets the string description for display purposes
Returns:
the string description

getColour

public static Colour getColour(int val)
Gets the colour from the value
Parameters:
val -  
Returns:
the colour with that value