org.gnu.gdk
Class Color

java.lang.Object
  |
  +--org.gnu.glib.Boxed
        |
        +--org.gnu.gdk.Color

public class Color
extends Boxed


Field Summary
static Color BLACK
           
static Color BLUE
           
static Color GREEN
           
static Color ORANGE
           
static Color RED
           
static Color WHITE
           
static Color YELLOW
           
 
Constructor Summary
Color(int handle)
          Construct a Color object from a handle to a native resource.
Color(int red, int green, int blue)
          Creates an sRGB color with the specified red, green, and blue values in the range (0 - 65535).
 
Method Summary
 java.lang.Object clone()
          Makes a copy of this color.
 boolean equals(java.lang.Object color)
          Determines whether another object is equal to this Color.
 int getBlue()
          Returns the blue component in the range 0-65535 in the default sRGB space.
 int getGreen()
          Returns the green component in the range 0-65535 in the default sRGB space.
 int getRed()
          Returns the red component in the range 0-65535 in the default sRGB space.
 int hashCode()
           
 void setBlue(short value)
          Sets the blue component in the range of 0-65535.
 void setGreen(short value)
          Sets the green component in the range of 0-65535.
 void setRed(short value)
          Sets the red component in the range of 0-65535.
 java.lang.String toString()
          Returns a string representation of this Color.
 
Methods inherited from class org.gnu.glib.Boxed
equals, getHandle
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

RED

public static final Color RED

BLUE

public static final Color BLUE

GREEN

public static final Color GREEN

BLACK

public static final Color BLACK

YELLOW

public static final Color YELLOW

WHITE

public static final Color WHITE

ORANGE

public static final Color ORANGE
Constructor Detail

Color

public Color(int handle)
Construct a Color object from a handle to a native resource.


Color

public Color(int red,
             int green,
             int blue)
Creates an sRGB color with the specified red, green, and blue values in the range (0 - 65535).

Method Detail

clone

public java.lang.Object clone()
Makes a copy of this color.

Overrides:
clone in class java.lang.Object

equals

public boolean equals(java.lang.Object color)
Determines whether another object is equal to this Color.

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

getRed

public int getRed()
Returns the red component in the range 0-65535 in the default sRGB space.


setRed

public void setRed(short value)
Sets the red component in the range of 0-65535.


getGreen

public int getGreen()
Returns the green component in the range 0-65535 in the default sRGB space.


setGreen

public void setGreen(short value)
Sets the green component in the range of 0-65535.


getBlue

public int getBlue()
Returns the blue component in the range 0-65535 in the default sRGB space.


setBlue

public void setBlue(short value)
Sets the blue component in the range of 0-65535.


toString

public java.lang.String toString()
Returns a string representation of this Color.

Overrides:
toString in class java.lang.Object

Please send any bug reports, comments, or suggestions for the API or documentation to java-gnome-developer@lists.sf.net