Illustrator (Desktop) SDK/Scripting Issues
83 results found
-
Access to recent files via a script
Once upon a time, app.recentFiles returned an array of recently used files.
It would be nice to have that feature back4 votes -
Script cannot detect that app.openCloudDocument failed
en
When an error occurs during the execution of openCloudDocument, Illustrator forces a message in a dialog.
The message is something like this. Not sure what it would be displayed in English.
Cannot open file.
The current account does not have access permission to this file. Contact the owner for more details.
The message cannot be circumvented by enclosing it in a “try” syntax, nor can the error be caught in a “catch” statement. In other words, this message may stop the batch process.
The ideal behavior is to be able to catch an error…
4 votes -
Variable font support in scripts
There doesn't seem to be any way to use variable fonts in scripts. There is an undocumented property TextFont.axisVector, but it is read-only. So there is no way to adjust the axes of a variable font via script, even though Illustrator has supported variable fonts for many years now.
Relevant thread:
https://community.adobe.com/t5/illustrator-discussions/scripting-variable-fonts-in-illustrator/td-p/98345144 votes -
Join command is unavailable when run from an action via a script
We have an action that works, when launched form the Actions panel.
Operations are simple:
1. Copy
2. Deselect All
3. Paste in Front
4. Join
5. Join
It is designed to create a new closed shape from two segments from different shapes.However, when we call this exact action from a script with a app.doScript, it doesn’t work, an error message 'The object "Join" is not currently available' is displayed.
Please see the video.
4 votes -
Erroneous fillColor type one shapes with Freeform Gradients
Trying to get the fillColor properties of shapes that feature Freeform Gradients
- Using app.activeDocument.selection[0].fillColor
- Returns a [GrayColor] instead of what we would expect to be a [GradientColor] of GradientType.FREEFORM
4 votes -
import graphic styles from file or library
with javascript, there is no way to import graphic styles from libraries or files. there is a way to open ai documents as graphic style libraries but then there is no script access to that library.
currently what i have to do is have an ai file with objects with graphic styles assign to them. with my script i open that file, select the objects, copy them, close the file, switch documents, paste objects, delete objects.
this can take a while and it is a very ugly solution. ideally there should be something as simple as importGraphicStylesFromFile(File)
or at least …
4 votes -
Dialog display in the event of a path segment exceedance during script processing is displayed with 8191 pieces.
Illustrator ver.29.3.1
The current Illustrator specification allows "31999" segments to be included in a single path, but the exceedance error displayed during script execution is displayed at "8191" segments. This is the value of the limit in past versions and has not been updated when the specification was changed.
When run the following script, we get an error dialog with 8191 segments, but there are 32000 path points and 31999 segments added to the path on the document.
var depth = 8;
var size = 500;
var doc = app.activeDocument;
var layer = doc.layers.add();
layer.name = "Hilbert Curve";
var pth…3 votes -
[Scripting API] Give access to a SymbolItem's "anchor" and matrix
It would be great to have access to a SymbolItem's "anchor" and matrix (as read/write properties). Setting a new anchor [x,y] would move the anchor (and the SymbolItem) to that point, and setting a new matrix would replace the SymbolItem's existing matrix.
3 votes -
Duplicating a group with a script does not change/update groupItems.length
When you duplicate a group via script (check the video and screenshots) activeDocument.groupItems.length is not reflecting that. It stays the same. app.redraw() is not helping. Only when you set the new group to .selected = true you can force an update. But that slows down everything when you have a lot of groups.
Video: https://drive.google.com/file/d/1dd0PyBRDBciNnUgnhGLV7Hf40rrG_vSb/view
Steps to Reproduce:
All with script!
1. Create a group (put something in that group)
2. Alert the activeDocument.groupItems.length (it's now 1)
2. Duplicate the group.
3. Alert the activeDocument.groupItems.length: it stays the same (1 instead of 2)
Please take a look at the script…3 votes -
DocumentRasterResolution - How do we set HighResolution? Please give an example of how to set and how to read document resolution. Thanks
DocumentRasterResolution - How do we set HighResolution? Please give an example of how to set and how to read document resolution. Thanks.
Example:
DocumentRasterResolution.HighResolution; //Does nothing So how to do? Why is this not an app.documents.add() function or method to begin with? Why is the app.document.add so limited in parameters? I would think there would be a huge parameter list but there is not.3 votes -
DocumentArtboardLayout under app.documents.add is broken
var aDoc = app.documents.add(DocumentColorSpace.CMYK, 612.0, 792.0, 3, DocumentArtboardLayout.GridByCol, 40.0, 1);
Running the above script.jsx GridByCol broken. I get two rows, should be a single column. Changed GridByCol to GridByRows and also outputs 2 rows of artboards. DocumentArtboardLayout is broken.
3 votes -
[Typo] View rotateAngle property in omv.xml
For several years, the same incorrect information about the document rotation property has been repeated in the omv.xml (Object Model Viewer) file in folder "Scripting Dictionaries CC". Checked in СС 2023, 2024, 2025
/Library/Application Support/Adobe/Scripting Dictionaries CC/Illustrator [vers.]/omv.xml
At the same time, the PDF documentation "Adobe Illustrator Scripting Reference: JavaScript", the property name is correct.
Expected Property Name:
rotateAngleActual Property Name in omv.xml:
rotate<classdef name="View" dynamic="true">
....
<property name="rotate">
<shortdesc>The rotation angle of this view.</shortdesc>
<datatype>
<type>number</type>
</datatype>
</property>
...
</classdef>3 votes -
Bug: JavaScript unary operators "+" and "-" do not function as documented for UnitValue objects
According to the Illustrator ExtendScript documentation, applying the unary operators "+" or "-" to a UnitValue object should respectively produce the numeric value or the negated numeric value of the UnitValue. However, they instead respectively produce the UnitValue unmodified or the UnitValue with its value negated.
Either the documentation or the behaviour should be updated to reflect the other.
I observed this behaviour in Illustrator 28.5 on Mac OS Sonoma.
The behaviour may be quickly tested with the following script:
var uv = new UnitValue(2, "px");
alert(
"Results:" +
"\nUnitValue unmodified: \"" + uv + "\" (" + (typeof uv)…3 votesNihiltres, UnitValue is an object with properties
baseUnit - type of UnitValue data type
type - type of String data type
value - type of Numeric data type.
When using unary operator on object, the underlying value property of the object is modified.
Example:
var uv = new UnitValue(2, "px");
"-uv" will result in uv.value modified from "2" to "-2" and stays as Numeric data type.
Any unary operator on object as whole will return the object itself.
Alternatively you can achieve the result you expected by directly manipulating the value instead of the object
var uv = new UnitValue(2, "px");
"-uv.value" this will return the Numeric data type with negating the value, in this case it will convert the number 2 to -2
I do see it is working as documented, I would like to hear your view with the above information.
Unary operators (~, !,…
-
Vertically alignChildren in ScriptUI does not align properly
In the ScriptUI documentation, there is an alignChildren attribute: "Tells the layout manager how to align children of this container that are not of the same size in a column or row". The issue of vertical alignment of UI objects in the scripts dialog box persists from version to version of Illustrator.
As we can see in the image, only the top alignment seems to be correct. The center alignment is shifted up, and the bottom alignment does not reach the bottom. At the same time, native UI dialogs contain the correct alignment. Thus script interfaces always look less professional.
…
3 votes -
Please update "Planet X" in backend to "Live Paint"
Actions read from API are named "Planet X".
In AI menu, they are "Live Paint"Additionally, there is one typo: "Marge Planet X" = "Merge Live Paint"
When Loupedeck reads the actions from API, they appear with outdated names in Loupedeck UI.
3 votes -
Update the VSCode ExtendScript Debugger
This is an essential tool.
Too many issues to mention here - and that's just on a PC. It doesn't work at all on ARMx64
The community needs this kept up to date!
3 votes -
Commands from Special characters / Whitespace section gives an error
A simple script:
app.executeMenuCommand('~copyright')
gives an error 1200: 1346458189 ('PARM')3 votes -
retrieve transformation matrix of a symbol instance
there seems to be no way to retrieve a symbol instance's transformation matrix (neither javascript nor SDK).
It is only possible to compare the bounding box to the expected one3 votes -
Fails to retrieve file creation date | AI 2020, MacOS Catalina
This issue appears only on MacOS Catalina.
Steps to reproduce:
File(file_path).created.getTime()
3 votes -
Using method duplicate() on a group of threaded text frame items will lose threading
Hi together,
if we duplicate a group of threaded text frame items to a different Illustrator document the story's threaded text frame items will not be threaded anymore in the target document.If you duplicate the group in the same document the threaded text frame items remain threaded.
All details here at Adobe Illustrator Scripting Forum:
[BUG] copying threaded text-frames.
Silly-V Mar 22, 2019 9:30 AM
https://forums.adobe.com/message/10991060#10991060One has to rethread the text frame items in the target document.
That should not be necessary.No issue if we copy and paste grouped and threaded text frame items using the menu…
3 votes
- Don't see your idea?