ColorColors

A collection of colors.

Instance Properties

Name Description Access
length number The number of objects in the collection. read-only

Methods

add(
[withProperties])
 → Color
anyItem(
)
 → Color
count(
)
 → number
everyItem(
)
 → Color
firstItem(
)
 → Color
item(
index)
 → Color
itemByID(
id)
 → Color
itemByName(
name)
 → Color
itemByRange(
from, to)
 → Color
lastItem(
)
 → Color
middleItem(
)
 → Color
nextItem(
obj)
 → Color
previousItem(
obj)
 → Color
toSource(
)
 → string
add(
[withProperties])
 → Color
Creates a new Color.
withProperties Object Initial values for properties of the new Color (Optional)
anyItem(
)
 → Color
Returns any Color in the collection.
count(
)
 → number
Displays the number of elements in the Color.
everyItem(
)
 → Color
Returns every Color in the collection.
firstItem(
)
 → Color
Returns the first Color in the collection.
item(
index)
 → Color
Returns the Color with the specified index or name.
index The index or name. Can accept: Long Integer or String.
itemByID(
id)
 → Color
Returns the Color with the specified ID.
id number The ID.
itemByName(
name)
 → Color
Returns the Color with the specified name.
name string The name.
itemByRange(
from, to)
 → Color
Returns the Colors within the specified range.
from The Color, index, or name at the beginning of the range. Can accept: Color, Long Integer or String.
to The Color, index, or name at the end of the range. Can accept: Color, Long Integer or String.
lastItem(
)
 → Color
Returns the last Color in the collection.
middleItem(
)
 → Color
Returns the middle Color in the collection.
nextItem(
obj)
 → Color
Returns the Color whose index follows the specified Color in the collection.
obj Color The Color whose index comes before the desired Color.
previousItem(
obj)
 → Color
Returns the Color with the index previous to the specified index.
obj Color The index of the Color that follows the desired Color.
toSource(
)
 → string
Generates a string which, if executed, will return the Color.