Skip to main content
Inspiring
August 23, 2024
Question

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

  • August 23, 2024
  • 1 reply
  • 560 views

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 has been closed for replies.

1 reply

Kurt Gold
Community Expert
Community Expert
August 23, 2024

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

Inspiring
August 24, 2024

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 

 

m1b
Community Expert
Community Expert
August 26, 2024

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