Skip to content

Commit fbe5b28

Browse files
authored
Merge pull request #57 from docsforadobe/colombo/beta-26.0
Add new script APIs for 26.0 Beta
2 parents 3085d73 + 4c6a807 commit fbe5b28

File tree

5 files changed

+183
-10
lines changed

5 files changed

+183
-10
lines changed

docs/introduction/changelog.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,17 @@ What's new and changed for scripting?
88

99
---
1010

11+
## After Effects 26 (Beta)
12+
13+
### After Effects 26.0 (Beta) (November 2025)
14+
15+
- Scripting methods and attributes added:
16+
- Added: [PropertyGroup.addVariableFontAxis()](../property/propertygroup.md#propertygroupaddvariablefontaxis)
17+
- Added: [Property.propertyParameters](../property/property.md#propertypropertyparameters)
18+
- Added: [Property.valueText](../property/property.md#propertyvaluetext)
19+
20+
---
21+
1122
## After Effects 25
1223

1324
### [After Effects 25.4](https://helpx.adobe.com/after-effects/using/whats-new/2025-4.html) (August 2025)

docs/matchnames/layer/textlayer.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
| `ADBE Text First Margin` | First Margin |
2424
| `ADBE Text Last Margin` | Last Margin |
2525
| `ADBE Text More Options` | More Options |
26+
| `ADBE Text Variable Font Spacing` | Variable Font Spacing |
2627
| `ADBE Text Anchor Point Align` | Grouping Alignment |
2728
| `ADBE Text Animators` | Animators |
2829

docs/property/property.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -460,6 +460,38 @@ Integer; read-only.
460460

461461
---
462462

463+
### Property.propertyParameters
464+
465+
`app.project.item(index).layer(index).propertySpec.propertyParameters`
466+
467+
!!! note
468+
This functionality was added in After Effects (Beta) 26.0 and is subject to change while it remains in Beta.
469+
470+
#### Description
471+
472+
An array of all item strings in a dropdown menu property. This attribute applies to dropdown menu properties of effects and layers, including custom strings in the Menu property of the Dropdown Menu Control.
473+
474+
This property corresponds to [Property.setPropertyParameters()](#propertysetpropertyparameters), acting as the getter for the strings in a dropdown menu.
475+
476+
#### Examples
477+
478+
```javascript
479+
// Get all options from a Dropdown Menu Control
480+
var comp = app.project.activeItem;
481+
if (comp && comp.selectedLayers.length > 0) {
482+
var lyr = comp.selectedLayers[0];
483+
var fx = lyr.property("ADBE Effect Parade").property("Dropdown Menu Control");
484+
var menuProp = fx.property("Menu");
485+
var options = menuProp.propertyParameters; // Array of strings
486+
}
487+
```
488+
489+
#### Type
490+
491+
Array of strings; read-only.
492+
493+
---
494+
463495
### Property.propertyValueType
464496

465497
`app.project.item(index).layer(index).propertySpec.propertyValueType`
@@ -576,6 +608,36 @@ A value appropriate for the type of the property (see [Property.propertyValueTyp
576608

577609
---
578610

611+
### Property.valueText
612+
613+
`app.project.item(index).layer(index).propertySpec.valueText`
614+
615+
!!! note
616+
This functionality was added in After Effects (Beta) 26.0 and is subject to change while it remains in Beta.
617+
618+
#### Description
619+
620+
The text string of the currently-selected item in a dropdown menu property. This attribute applies to dropdown menu properties of effects and layers, including custom strings in the Menu property of Dropdown Menu Controls.
621+
622+
#### Examples
623+
624+
```javascript
625+
// Get the currently-selected text string from a Dropdown Menu Control
626+
var comp = app.project.activeItem;
627+
if (comp && comp.selectedLayers.length > 0) {
628+
var lyr = comp.selectedLayers[0];
629+
var fx = lyr.property("ADBE Effect Parade").property("Dropdown Menu Control");
630+
var menuProp = fx.property("Menu");
631+
var selectedText = menuProp.valueText; // e.g., "Sunday"
632+
}
633+
```
634+
635+
#### Type
636+
637+
String; read-only.
638+
639+
---
640+
579641
## Methods
580642

581643
### Property.addKey()

docs/property/propertygroup.md

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,83 @@ Boolean.
129129

130130
---
131131

132+
### PropertyGroup.addVariableFontAxis()
133+
134+
`app.project.item(index).layer(index).propertyGroupSpec.addVariableFontAxis(axisTag)`
135+
136+
!!! note
137+
This functionality was added in After Effects (Beta) 26.0 and is subject to change while it remains in Beta.
138+
139+
#### Description
140+
141+
Creates and returns a Property object for a variable font axis, and adds it to this property group. This method can only be called on the "ADBE Text Animator Properties" property group within a text animator.
142+
143+
Common axis tags include (but are not limited to):
144+
145+
- `"wght"` - Weight (100-900 typical range)
146+
- `"wdth"` - Width (percentage of normal width)
147+
- `"slnt"` - Slant (angle in degrees)
148+
- `"ital"` - Italic (0-1 range)
149+
- `"opsz"` - Optical Size (point size)
150+
151+
Fonts may also include custom axes with 4-character uppercase tags (e.g., `"INFM"` for Informality).
152+
153+
#### Variable Font Spacing
154+
155+
When animating Variable Font axes, individual characters can change width. The Variable Font Spacing property (found in the "More Options" section of a text animator) controls how After Effects handles character spacing compensation for these width changes.
156+
157+
The Variable Font Spacing property can be accessed via its matchName `"ADBE Text Variable Font Spacing"` and is a dropdown control property. This property appears only when at least one variable font axis is active in the animator.
158+
159+
160+
!!! tip
161+
Axes must exist on the font to have any impact. To discover what axes a font supports, use [FontObject.designAxesData](../text/fontobject.md#fontobjectdesignaxesdata).
162+
163+
#### Parameters
164+
165+
| Parameter | Type | Description
166+
| --------- | ------ | -----------------------------------------------------------------------------------------------------|
167+
| `axisTag` | String | The 4-character tag identifying the variable font axis (e.g., `"wght"`, `"wdth"`, `"slnt"`, `"ital"`).
168+
169+
#### Returns
170+
171+
[Property object](property.md) representing the variable font axis.
172+
173+
#### Examples
174+
175+
```javascript
176+
// Create a comp
177+
var comp = app.project.items.addComp("Create Axis Comp", 1920, 1080, 1, 30, 30);
178+
comp.openInViewer();
179+
180+
// Create a text layer
181+
var textLayer = comp.layers.addText("Hello World!");
182+
183+
// Set the font to variable font
184+
var textDocument = textLayer.property("Source Text").value;
185+
textDocument.font = 'ShantellSans'; // Must be a variable font
186+
textLayer.property("Source Text").setValue(textDocument);
187+
188+
// Get the text property and animators group
189+
var textProp = textLayer.property("Text");
190+
var animators = textProp.property("Animators");
191+
192+
// Add a new animator
193+
var animator = animators.addProperty("ADBE Text Animator");
194+
var animatorProps = animator.property("ADBE Text Animator Properties");
195+
196+
// Add the Weight axis
197+
var axisProp = animatorProps.addVariableFontAxis("wght");
198+
199+
// Set a static value
200+
axisProp.setValue(700);
201+
202+
// Set keyframes
203+
axisProp.setValueAtTime(0, 300); // Light at 0 seconds
204+
axisProp.setValueAtTime(2, 900); // Heavy at 2 seconds
205+
```
206+
207+
---
208+
132209
### PropertyGroup.property()
133210

134211
`app.project.item(index).layer(index).propertyGroupSpec.property(index)`

docs/text/fontobject.md

Lines changed: 32 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,24 +20,46 @@ Most of these APIs simply return information which is contained in the Font data
2020
#### Description
2121

2222
Returns an Array of Objects, containing the design axes data from the font.
23-
Each object is composed of the axis `name`, `tag`, `min` value and `max` value.
23+
Each object is composed of the axis `name`, `tag`, `min` value, `max` value, and `default` value.
2424

2525
!!! tip
2626
Will return undefined for non-variable fonts.
2727

2828
#### Example
2929

30-
This example will select the first returned Font Family Array.
30+
This example demonstrates how to see the axes of a variable font on a selected Text layer:
3131

3232
```javascript
33-
// Getting the first available Variable Font on the system
34-
var firstVariableFont = fontsWithDefaultDesignAxes[0];
35-
var axesData = firstVariableFont.designAxesData;
36-
37-
// Getting the first design axis for that Font
38-
var firstAxis = axesData[0];
39-
40-
alert(firstAxis.name+"\n"+firstAxis.tag+"\n"+firstAxis.min+"\n"+firstAxis.max);
33+
// Prerequisite: Create and select a Text layer that uses a variable font
34+
var textLayer = app.project.activeItem.selectedLayers[0];
35+
36+
// Get the font object
37+
var textDocument = textLayer.property("Source Text").value;
38+
var fontObject = textDocument.fontObject;
39+
40+
// Check for axes and display any that are found
41+
if (fontObject && fontObject.designAxesData) {
42+
var axes = fontObject.designAxesData;
43+
var message = "Variable Font Axes (" + axes.length + " total):\n\n";
44+
45+
for (var i = 0; i < axes.length; i++) {
46+
var axis = axes[i];
47+
message += "Axis " + (i + 1) + ":\n";
48+
message += " Tag: " + axis.tag + "\n";
49+
message += " Name: " + axis.name + "\n";
50+
message += " Min: " + axis.min + "\n";
51+
message += " Max: " + axis.max + "\n";
52+
message += " Default: " + axis.default + "\n";
53+
54+
if (i < axes.length - 1) {
55+
message += "\n";
56+
}
57+
}
58+
59+
alert(message);
60+
} else {
61+
alert("No variable font axes found");
62+
}
4163
```
4264

4365
#### Type

0 commit comments

Comments
 (0)