Rgb24Color

Inheritance: java.lang.Object

public class Rgb24Color

Represents 24-bit color in RGB format, with 8 bits per every channel (Red, Green, Blue). Does not support transparency. Designed to be useful for (but not limited to) CSS operations. See more: https://developer.mozilla.org/en-US/docs/Web/CSS/color_value

Constructors

Constructor Description
Rgb24Color(int r, int g, int b)

Methods

Rgb24Color(int r, int g, int b)

public Rgb24Color(int r, int g, int b)

Parameters:

Parameter Type Description
r int
g int
b int

toInternal()

public Rgb24Color toInternal()

Returns: Rgb24Color

fromInternal(Rgb24Color color)

public static Rgb24Color fromInternal(Rgb24Color color)

Parameters:

Parameter Type Description
color com.groupdocs.htmlcss.drawing.Rgb24Color

Returns: Rgb24Color

fromRgb(int red, int green, int blue)

public static Rgb24Color fromRgb(int red, int green, int blue)

Parameters:

Parameter Type Description
red int
green int
blue int

Returns: Rgb24Color

getR()

public int getR()

Returns: int

getG()

public int getG()

Returns: int

getB()

public int getB()

Returns: int

isDefault()

public boolean isDefault()

Returns: boolean

getBrightness()

public float getBrightness()

Returns: float

getHue()

public float getHue()

Returns: float

getSaturation()

public float getSaturation()

Returns: float

toArgb()

public int toArgb()

Returns: int

hashCode()

public int hashCode()

Returns: int

equals(Object obj)

public boolean equals(Object obj)

Parameters:

Parameter Type Description
obj java.lang.Object

Returns: boolean

toRGB()

public String toRGB()

Returns: java.lang.String

toHex()

public String toHex()

Returns: java.lang.String

toString()

public String toString()

Returns: java.lang.String