public class BaseColor extends Object
Modifier and Type | Field and Description |
---|---|
static BaseColor |
BLACK |
static BaseColor |
BLUE |
static BaseColor |
CYAN |
static BaseColor |
DARK_GRAY |
private static double |
FACTOR |
static BaseColor |
GRAY |
static BaseColor |
GREEN |
static BaseColor |
LIGHT_GRAY |
static BaseColor |
MAGENTA |
static BaseColor |
ORANGE |
static BaseColor |
PINK |
static BaseColor |
RED |
private int |
value |
static BaseColor |
WHITE |
static BaseColor |
YELLOW |
Constructor and Description |
---|
BaseColor(Color color)
Construct a new BaseColor from a java.awt.Color
|
BaseColor(float red,
float green,
float blue)
Construct a BaseColor with float values.
|
BaseColor(float red,
float green,
float blue,
float alpha)
Construct a BaseColor with float values.
|
BaseColor(int argb)
Construct a BaseColor by setting the combined value.
|
BaseColor(int red,
int green,
int blue) |
BaseColor(int red,
int green,
int blue,
int alpha)
Construct a new BaseColor.
|
Modifier and Type | Method and Description |
---|---|
BaseColor |
brighter()
Make this BaseColor brighter.
|
BaseColor |
darker()
Make this color darker.
|
boolean |
equals(Object obj) |
int |
getAlpha() |
int |
getBlue() |
int |
getGreen() |
int |
getRed() |
int |
getRGB() |
int |
hashCode() |
String |
toString() |
private static void |
validate(int value) |
public static final BaseColor LIGHT_GRAY
private static final double FACTOR
private final int value
public BaseColor(int red, int green, int blue, int alpha)
red
- the value for the red gammagreen
- the value for the green gammablue
- the value for the blue gammaalpha
- the value for the alpha gammapublic BaseColor(int red, int green, int blue)
red
- green
- blue
- public BaseColor(float red, float green, float blue, float alpha)
red
- green
- blue
- alpha
- public BaseColor(float red, float green, float blue)
red
- green
- blue
- public BaseColor(int argb)
argb
- public int getRGB()
public int getRed()
public int getGreen()
public int getBlue()
public int getAlpha()
public BaseColor brighter()
public BaseColor darker()
private static void validate(int value)
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses