Properties
Returns:
Boolean
The art item's blend mode as specified by the Art.BLEND_* staticproperties.
Returns:
Number
Returns:
Boolean
A boolean value that specifies whether the art item defines a clip mask.This can only be set on paths, compound paths, and text frame objects,and only if the item is already contained within a clip group.Sample code:
var group = new Group();group.appendChild(path);group.clipped = true;path.clipMask = true;
Returns:
Boolean
Read-only.The bounds of the art item including stroke width and controls.
Returns:
Returns:
Object
Read-only.
Returns:
Boolean
Read-only.Returns the first art item contained within this art item.
Returns:
A boolean value that specifies whether the art item is fullyselected. For paths this means that all segments are selected,for container objects all children are selected.
Returns:
Boolean
Read-only.The bounds of the art item excluding stroke width.
Returns:
Returns:
Boolean
Returns:
Boolean
Read-only.
Returns:
Boolean
A boolean value that specifies whether the art item is locked.Sample code:
var path = new Path();print(path.locked) // returns falsepath.locked = true; // locks the pathprint(path.locked) // returns true
Returns:
Boolean
Read-only.
Returns:
Number
The name of the art item as it appears in the layers palette.Sample code:
var layer = new Layer(); // a layer is an art itemprint(layer.name); // returns '<Layer 2>'layer.name = "A nice name";print(layer.name); // returns 'A nice name'
Returns:
String
Read-only.Returns the next art item on the same level as this art item.
Returns:
A value between 0 and 1 that specifies the opacity of the art item.
Returns:
Number
Read-only.Returns the previous art item on the same level as this art item.
Returns:
A boolean value that specifies whether an art item is selected.Returns true if the art item is selected or partially selected (groups withsome selected objects/partially selected paths), false otherwise.Sample code:
print(activeDocument.selectedItems.length) // returns 0var path = new Path(); // new art items are always created in the active layerpath.selected = true; // select the pathprint(activeDocument.selectedItems.length) // returns 1
Returns:
Boolean
Read-only.
Returns:
Boolean
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Returns:
Number
Functions
Appends the specified art item as a child of this art item.
You can use this function for groups, compound paths and layers.
Sample code:
You can use this function for groups, compound paths and layers.
Sample code:
var group = new Group(); var path = new Path(); group.appendChild(path); print(path.isInside(group)) // returns true
Parameters:
art: Art - The art item that will be appended as a child
Returns:
Boolean
Clones the art item within the same document.
Returns:
Object
- the newly cloned art object
Breaks artwork up into individual parts and works just like calling
"expand" from the Object menu in Illustrator.
It outlines stroked lines, text objects, gradients, patterns, etc.
The art item itself is removed, and the newly created item containing the expanded artwork is returned.
It outlines stroked lines, text objects, gradients, patterns, etc.
The art item itself is removed, and the newly created item containing the expanded artwork is returned.
Parameters:
flags: Number - #EXPAND_*
steps: Number
Returns:
Art
- the newly created item containing the expanded artwork
Checks if the art object has children.
Returns:
Boolean
- true if it has one or more children, false otherwise
Checks if this art item is above the specified art item in the stacking
order of the document.
Sample code:
Sample code:
var firstPath = new Path(); var secondPath = new Path(); print(secondPath.isAbove(firstPath)) // returns true
Parameters:
art: Art - The art item to check against
Returns:
Boolean
- true if it is above the specified art item, false
otherwise
Checks if this art item is an ancestor of the specified art item.
Sample code:
Sample code:
var group = new Group(); var path = new Path(); group.appendChild(path); print(group.isAncestor(path)) // returns true
Parameters:
art: Art - the art item to check against
Returns:
Boolean
- true if it is an ancestor of the specified art
item, false otherwise
Checks if the art item is below the specified art item in the stacking
order of the document
Sample code:
var firstPath = new Path(); var secondPath = new Path(); print(firstPath.isBelow(secondPath)) // returns true
Parameters:
art: Art - The art item to check against
Returns:
Boolean
- true if it is below the specified art item, false
otherwise
Checks if the art item's name as it appears in the layers palette is a
default descriptive name, rather then a user-assigned name.
Returns:
Boolean
- true if it's name is default, false otherwise.
Checks if the art item is contained within the specified art item
Sample code:
var group = new Group(); var path = new Path(); group.appendChild(path); print(path.isInside(group)) // returns true
Parameters:
art: Art - The art item to check against
Returns:
Boolean
- true if it is inside the specified art item,
false otherwise
Moves this art item above the specified art item.
Sample code:
Sample code:
var firstPath = new Path(); var secondPath = new Path(); print(firstPath.isAbove(secondPath)) // returns false firstPath.moveAbove(secondPath); print(firstPath.isAbove(secondPath)) // returns true
Parameters:
art: Art - The art item above which it should be moved
Returns:
Boolean
- true if it was moved, false otherwise
Moves the art item below the specified art object.
var firstPath = new Path(); var secondPath = new Path(); print(secondPath.isBelow(firstPath)) // returns false secondPath.moveBelow(firstPath); print(secondPath.isBelow(firstPath)) // returns true
Parameters:
art: Art - the art item below which it should be moved
Returns:
Boolean
- true if it was moved, false otherwise
Parameters:
type: Number
resolution: Number
antialiasing: Number
width: Number
height: Number
Returns:
Removes the art item from the document. If the art item has children,
they are also removed.
Returns:
Boolean
- true if the art item was removed, false
otherwise
Rotates the art item around an anchor point by a given angle.
Parameters:
theta: Number - the rotation angle in radians
x: Number
y: Number
See also:Matrix
Parameters:
theta: Number
anchor: Point
Scales the art item by creating a scale Matrix and executing transform()
Parameters:
sx: Number
sy: Number
See also:scale(scale)
Shears the art item with a given amount.
Parameters:
shx: Number
shy: Number
See also:shear(shearX, shearY)
Transforms the art item with custom flags to be set.
Parameters:
matrix: Matrix
flags: Number - Art. TRANSFORM_*
Translates (moves) the art item by the given offsets.
Parameters:
tx: Number
ty: Number
See also:translate(pt)
Translates (moves) the art item by the given offset point.
Parameters:
t: Point
-

SG
-

AI- Point
- Rectangle
- Color
- Matrix
- Art
- Segment
- SegmentList
- Curve
- CurveList
- TextRange
- TextStory
- PathStyle
- FillStyle
- StrokeStyle
- ParagraphStyle
- FontFamily
- FontWeight
- FontList
- ArtSet
- Pathfinder
- HitTest
- Document
- DocumentList
- LayerList
- Swatch
- SwatchList
- Gradient
- GradientList
- GradientStop
- GradientStopList
- Symbol
- SymbolList
- Pattern
- PatternList
- Timer
- LiveEffect
- Annotator
- DocumentView
- DocumentViewList
-

ADM