Skip to main content
Inspiring
Aug 23, 2024 8:40 AM UTC
Question

•  Change "Row Size" in "Layers Panel Options" via Javascript, possible?

Hello -

 

I'd like to make a small script that I can easilychange the "Row Size" preview (from the "Layers" palette).

Is possible via Javascript?

ChatGPT says "NO", Gemini write this script (but it doesn't work)   😄

 

#target Illustrator

var doc = app.activeDocument;
var layerPanelOptions = doc.layerPanels[0].options;
layerPanelOptions.rowSize = LayerPanelRowSize.small;

 

Thank you for any help,

enjoy your day…

 

 

 - Dimitri

 

This topic is closed to new replies. Start a new post to keep the conversation going.

4 replies

Kurt Gold
Community Expert
Community Expert
Aug 23, 2024 8:25 PM UTC

I'm pretty sure that currently one does not have access to these settings via javascript.

Translate
Inspiring
Aug 24, 2024 9:47 AM UTC

Hi Kurt -

 

Thx for your reply…

Could we imagine a Adobe Javascript that call an Applescript? What do you think?

 

I made already a small Applescript app that drop down some menus in Acrobat and check/ubcheck some "preferences".

So may be it could work? 

 

 

- Dimitri 

 

Translate
m1b
Community Expert
Community Expert
Aug 26, 2024 6:33 AM UTC

Hi @dimitri_cas, it may work. Your applescript might be able to target "System Events" if I remember correctly and simulate UI, eg clicks etc. But if you can get it to work (a BIG if) it won't be pretty and won't play nice with a larger workflow unless maybe your whole workflow is in Applscript too. I'm no expert so I might be talking as much rubbish as Gemini!

- Mark

Translate