GroupLayer
Though the default is for a shape to consist of a single path, a single stroke, and a single fill—arranged from top to bottom in the Timeline panel—much of the power and flexibility of shape layers arises from your ability to add and reorder shape attributes and create more complex compound shapes.
You can group shapes or shape attributes that are at the same grouping level within a single shape layer.
A group is a collection of shape attributes: paths, fills, strokes, path operations, and other groups. Each group has its own blending mode and its own set of transform properties. By assembling shapes into groups, you can work with multiple shapes simultaneously—such as scaling all shapes in the group by the same amount or applying the same stroke to each shape. You can even place individual shapes or individual shape attributes within their own groups to isolate transformations. For example, you can scale a path without scaling its stroke by grouping the path by itself.
When you add a shape attribute using the Add menu in the Tools panel or Timeline panel, the attribute is added within the group that is selected. You can drag groups and attributes to reorder them in the Timeline panel. By reordering and grouping shapes and shape attributes, you can affect their rendering order with respect to other shapes and shape attributes.
Hierarchy
GroupLayer
Constructors
constructor
newGroupLayer(parent: any): GroupLayer
Properties
anchor
anchor: Property = new Property(this, PropertyType.ANCHOR)
autoOrient
autoOrient: boolean = false
blendMode
blendMode: BlendMode = BlendMode.NORMAL
classNames
classNames: string[] = []
effects
effects: any
height
height: number = 0
id
id: string = ""
inPoint
inPoint: number = 0
Optional index
index: undefined | number
is3D
is3D: boolean = false
name
name: string = ""
opacity
opacity: Property = new Property(this, PropertyType.OPACITY)
Optional orientation
outPoint
outPoint: number = 0
Protected parent
parent: any
position
position: Property = new Property(this, PropertyType.POSITION)
Optional rotation
Optional rotationX
Optional rotationY
Optional rotationZ
scale
scale: Property = new Property(this, PropertyType.SCALE)
startTime
startTime: number = 0
timeStretch
timeStretch: number = 1
Readonly type
type: GROUP = LayerType.GROUP
width
width: number = 0
Accessors
colors
get colors(): string[]
Returns string[]
Array of colors.
totalFrames
get totalFrames(): number
Returns number
Number of frames.
Methods
fromJSON
fromJSON(json: Record<string, any>): GroupLayer
toJSON
toJSON(): Record<string, any>
Returns Record<string, any>
JSON object
Last updated