Packagegraphics.colors
Classpublic class CMYK
InheritanceCMYK Inheritance CMY Inheritance Object

CMYK (short for cyan, magenta, yellow, and key (black), and often referred to as process color or four color) is a subtractive color model, used in color printing, also used to describe the printing process itself.



Public Properties
 PropertyDefined By
 Inheritedc : Number
The cyan component (between 0 and 1)
CMY
  k : Number
The black component (between 0 and 1)
CMYK
 Inheritedm : Number
The magenta component (between 0 and 1)
CMY
 Inheritedy : Number
The yellow component (between 0 and 1)
CMY
Public Methods
 MethodDefined By
  
CMYK(c:Number = 0, m:Number = 0, y:Number = 0, k:Number = 0)
Creates a new CMYK instance.
CMYK
  
clone():*
[override] Creates and returns a shallow copy of the object.
CMYK
  
difference():void
[override] Transforms the cyan, magenta, yellow and black components of the color in this difference color representation.
CMYK
  
equals(o:*):Boolean
[override] Compares the specified object with this object for equality.
CMYK
  
interpolate(color:CMY, level:Number = 1):CMY
[override] Interpolate the color and returns a new CMY object.
CMYK
  
set(... args):void
[override] Sets all cmyk components.
CMYK
  
toObject():Object
[override] Converts an object to an equivalent Object value.
CMYK
  
toSource(indent:int = 0):String
[override] Returns the source code string representation of the object.
CMYK
  
toString():String
[override] Returns a String representation of the object.
CMYK
Property Detail
kproperty
k:Number

The black component (between 0 and 1)


Implementation
    public function get k():Number
    public function set k(value:Number):void
Constructor Detail
CMYK()Constructor
public function CMYK(c:Number = 0, m:Number = 0, y:Number = 0, k:Number = 0)

Creates a new CMYK instance.

Parameters
c:Number (default = 0) — The cyan component, value between 0 and 1 (default 0).
 
m:Number (default = 0) — The magenta component, value between 0 and 1 (default 0).
 
y:Number (default = 0) — The yellow component, value between 0 and 1 (default 0).
 
k:Number (default = 0) — The black component, value between 0 and 1 (default 0).
Method Detail
clone()method
override public function clone():*

Creates and returns a shallow copy of the object.

Returns
* — A new object that is a shallow copy of this instance.
difference()method 
override public function difference():void

Transforms the cyan, magenta, yellow and black components of the color in this difference color representation.

equals()method 
override public function equals(o:*):Boolean

Compares the specified object with this object for equality.

Parameters

o:*

Returns
Booleantrue if the the specified object is equal with this object.
interpolate()method 
override public function interpolate(color:CMY, level:Number = 1):CMY

Interpolate the color and returns a new CMY object.

Parameters

color:CMY — The CMY reference used to interpolate the current CMY object.
 
level:Number (default = 1) — The level of the interpolation as a decimal, where 0 is the start and 1 is the end.

Returns
CMY — The new interpolate CMY reference.
set()method 
override public function set(... args):void

Sets all cmyk components.

Parameters

... args — The cyan component, value between 0 and 1 (default 0).

toObject()method 
override public function toObject():Object

Converts an object to an equivalent Object value.

Returns
Object — the Object representation of the instance.
toSource()method 
override public function toSource(indent:int = 0):String

Returns the source code string representation of the object.

Parameters

indent:int (default = 0)

Returns
String — the source code string representation of the object.
toString()method 
override public function toString():String

Returns a String representation of the object.

Returns
String — a String representation of the object.