Package com.itextpdf.text.pdf
Class ExtendedColor
- java.lang.Object
-
- com.itextpdf.text.BaseColor
-
- com.itextpdf.text.pdf.ExtendedColor
-
- Direct Known Subclasses:
CMYKColor,DeviceNColor,GrayColor,LabColor,PatternColor,ShadingColor,SpotColor
public abstract class ExtendedColor extends BaseColor
-
-
Field Summary
Fields Modifier and Type Field Description private static longserialVersionUIDprotected inttypestatic intTYPE_CMYKa type of extended color.static intTYPE_DEVICENa type of extended color.static intTYPE_GRAYa type of extended color.static intTYPE_LABa type of extended color.static intTYPE_PATTERNa type of extended color.static intTYPE_RGBa type of extended color.static intTYPE_SEPARATIONa type of extended color.static intTYPE_SHADINGa type of extended color.
-
Constructor Summary
Constructors Constructor Description ExtendedColor(int type)Constructs an extended color of a certain type.ExtendedColor(int type, float red, float green, float blue)Constructs an extended color of a certain type and a certain color.ExtendedColor(int type, int red, int green, int blue, int alpha)Constructs an extended color of a certain type and a certain color.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetType()Gets the type of this color.static intgetType(BaseColor color)Gets the type of a given color.(package private) static floatnormalize(float value)
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
TYPE_RGB
public static final int TYPE_RGB
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_GRAY
public static final int TYPE_GRAY
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_CMYK
public static final int TYPE_CMYK
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_SEPARATION
public static final int TYPE_SEPARATION
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_PATTERN
public static final int TYPE_PATTERN
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_SHADING
public static final int TYPE_SHADING
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_DEVICEN
public static final int TYPE_DEVICEN
a type of extended color.- See Also:
- Constant Field Values
-
TYPE_LAB
public static final int TYPE_LAB
a type of extended color.- See Also:
- Constant Field Values
-
type
protected int type
-
-
Constructor Detail
-
ExtendedColor
public ExtendedColor(int type)
Constructs an extended color of a certain type.- Parameters:
type-
-
ExtendedColor
public ExtendedColor(int type, float red, float green, float blue)Constructs an extended color of a certain type and a certain color.- Parameters:
type-red-green-blue-
-
ExtendedColor
public ExtendedColor(int type, int red, int green, int blue, int alpha)Constructs an extended color of a certain type and a certain color.- Parameters:
type-red-green-blue-alpha-
-
-
Method Detail
-
getType
public int getType()
Gets the type of this color.- Returns:
- one of the types (see constants)
-
getType
public static int getType(BaseColor color)
Gets the type of a given color.- Parameters:
color-- Returns:
- one of the types (see constants)
-
normalize
static final float normalize(float value)
-
-