org.gnu.pango

Class Color


public class Color
extends Boxed

The PangoColor structure is used to represent a color in an uncalibrated RGB colorspace.

Field Summary

Fields inherited from class org.gnu.glib.Boxed

handle

Constructor Summary

Color(Handle handle)
Color(Color color)
Create a new Color that is a copy of the provided color.

Method Summary

protected void
finalize()
int
getBlue()
Returns the Blue component of the color.
protected static int
getBlue(Handle obj)
int
getGreen()
Returns the Green component of the color.
protected static int
getGreen(Handle obj)
int
getRed()
Returns the red component of the color.
protected static int
getRed(Handle obj)
protected static Handle
pango_color_copy(Handle src)
protected static void
pango_color_free(Handle color)
protected static int
pango_color_get_type()
protected static boolean
pango_color_parse(Handle color, String spec)
boolean
setColor(String spec)
Fill in the fields of a color from a string specification.

Methods inherited from class org.gnu.glib.Boxed

equals, getHandle, hashCode, setHandle

Constructor Details

Color

protected Color(Handle handle)


Color

public Color(Color color)
Create a new Color that is a copy of the provided color.

Parameters:
color -

Method Details

finalize

protected void finalize()
            throws Throwable


getBlue

public int getBlue()
Returns the Blue component of the color. This is a value between 0 and 65535, with 65535 indicating full intensity.


getBlue

protected static final int getBlue(Handle obj)


getGreen

public int getGreen()
Returns the Green component of the color. This is a value between 0 and 65535, with 65535 indicating full intensity.


getGreen

protected static final int getGreen(Handle obj)


getRed

public int getRed()
Returns the red component of the color. This is a value between 0 and 65535, with 65535 indicating full intensity.


getRed

protected static final int getRed(Handle obj)


pango_color_copy

protected static final Handle pango_color_copy(Handle src)


pango_color_free

protected static final void pango_color_free(Handle color)


pango_color_get_type

protected static final int pango_color_get_type()


pango_color_parse

protected static final boolean pango_color_parse(Handle color,
                                                 String spec)


setColor

public boolean setColor(String spec)
Fill in the fields of a color from a string specification. The string can either one of a large set of standard names. (Taken from the X11 rgb.txt file), or it can be a hex value in the form 'rgb' 'rrggbb' 'rrrgggbbb' or 'rrrrggggbbbb' where 'r', 'g' and 'b' are hex digits of the red, green, and blue components of the color, respectively. (White in the four forms is 'fff' 'ffffff' 'fffffffff' and 'ffffffffffff')

Parameters:
spec - A string specifying the new color

Returns:
TRUE if parsing of the specifier succeeded, otherwise false.