Layer¶
Description¶
A layer object.
Layers may contain nested layers, which are called sublayers in the user interface. The layer object contains all of the page items in the specific layer as elements. Your script can access page items as elements of either the layer object or the document object.
Properties¶
allLocked readonly | If true, the layer’s contents and settings are locked. |
blendMode readonly | The mode to use when compositing an object. |
bounds readonly | If the Layer is a layer set, this property returns a reference to the corresponding layer set object. |
boundsNoEffects readonly | Bounding rectangle of the Layer not including effects. |
id readonly | The unique ID of this layer. |
itemIndex readonly | The layer index sans layer groups, how Photoshop would index them. |
linkedLayers readonly | The layers linked to this layer. |
name readonly | The name of the layer. |
opacity readonly | The layer’s master opacity (as a percentage). Range: 0.0 to 100.0. |
parent readonly | The object’s container. |
typename readonly | The class name of the object. |
visible readonly | If true, the layer is visible. |
xmpMetadata readonly | XMP metadata associated with the Layer. |
Methods¶
duplicate readonly | Duplicate this object. |
link readonly | Links the layer with the specified layer. |
move readonly | Move the object. |
moveToEnd readonly | … |
remove readonly | Deletes this object. |
removeAll readonly | Deletes all elements. |
resize readonly | Scales the object. |
rotate readonly | Rotates the object. |
translate readonly | Moves the object relative to its current position. |
unlink readonly | Unlinks the layer. |