A gradient.
Go to Property Listing | Method Listing
addEventListener, duplicate, extractLabel, getElements, insertLabel, merge, remove, removeEventListener, toSource, toSpecifier
Boolean, ColorGroup, EventListeners, Events, GradientStops, GradientType, Number, Object, String
Property |
Type |
Access |
Description |
---|---|---|---|
readonly |
A collection of event listeners. |
||
readonly |
A collection of events. |
||
readonly |
A collection of gradient stops. |
||
readonly |
The unique ID of the Gradient. |
||
readonly |
The index of the Gradient within its containing object. |
||
readonly |
Returns true if the object specifier resolves to valid objects. |
||
read/write |
A property that can be set to any string. |
||
read/write |
The name of the Gradient. |
||
readonly |
The parent of the Gradient (a Application or Document). |
||
readonly |
The color group that a swatch belongs to |
||
read/write |
A property that allows setting of several properties at the same time. |
||
read/write |
The gradient type. |
EventListener addEventListener (eventType:String, handler:Varies File JavaScriptFunction, [captures:Boolean=Boolean])
Adds an event listener.
Parameter |
Type |
Description |
---|---|---|
eventType |
The event type. |
|
handler |
JavaScriptFunction |
The event handler. Can accept: File or JavaScript Function. |
captures |
This parameter is obsolete. (Optional) (default: false) |
Gradient duplicate ()
Duplicates the Gradient.
String extractLabel (key:String)
Gets the label value associated with the specified key.
Parameter |
Type |
Description |
---|---|---|
key |
The key. |
Gradient getElements ()
Resolves the object specifier, creating an array of object references.
undefined insertLabel (key:String, value:String)
Sets the label to the value associated with the specified key.
Swatch merge (with:Array of Varies Swatches Swatch String)
Merges the specified swatches with the swatch.
Parameter |
Type |
Description |
---|---|---|
with |
Array of Swatches |
The swatches to merge. Can accept: Array of Swatches, Swatch or String. |
undefined remove (replacingWith:Swatch)
Deletes the swatch.
Parameter |
Type |
Description |
---|---|---|
replacingWith |
The swatch to apply in place of the deleted swatch. (Optional) |
Boolean removeEventListener (eventType:String, handler:Varies File JavaScriptFunction, [captures:Boolean=Boolean])
Removes the event listener.
Parameter |
Type |
Description |
---|---|---|
eventType |
The registered event type. |
|
handler |
JavaScriptFunction |
The registered event handler. Can accept: File or JavaScript Function. |
captures |
This parameter is obsolete. (Optional) (default: false) |
String toSource ()
Generates a string which, if executed, will return the Gradient.
String toSpecifier ()
Retrieves the object specifier.