Skip to main content
Phil 815
Inspiring
June 1, 2023
Question

UXP Table Scripting extremely slow

  • June 1, 2023
  • 1 reply
  • 1467 views

I'm posting this to note the slow performance of UXP versus CEP/Extendscript when creating and formatting tables. When running the same script on both, the UXP scropt takes over 1 minute to populate and format a medium sized table while it takes Extendscript ~20 seconds. I don't think 20 seconds is good, but over a minute is awful. I'm not sure if others have noticed this performance drop when switching, but it ultimately might discourage my company from adopting the new language. I hope Adobe is aware of this...

This topic has been closed for replies.

1 reply

m1b
Community Expert
Community Expert
June 1, 2023

Hi @Phil 815, thanks for posting. It's good to collect real-world data on this stuff. You are right that manupulating tables is very slow, even with ExtendScript, so I would hope that that is on the list for Adobe to improve. I noticed your other post, which shows a video of populating a table. I've been waiting for a UXP expert to answer, but since there have been no answers yet, I'll hazard a guess that the enableRedraw = false isn't implemented yet. Only a guess. UXP for Indesign has a lot missing at this early stage. Please keep posting any other issues you find—it really is helpful.

- Mark

Inspiring
June 1, 2023

For another speed comparison: I've set up UXPScriptSparker to make it easy to run side-by-side comparisons between UXPScript and ExtendScript speeds. One example:

https://github.com/zwettemaan/UXPScriptSparker/wiki/InDesignBrot

There are a few more sample scripts embedded into UXPScriptSparker

m1b
Community Expert
Community Expert
June 1, 2023

Hey this is a great resource @RorohikoKris. Thank you for making it and sharing. Very interesting. Your rough estimate seems to be that UXP DOM manipulating takes about 3x the time compared to ExtendScript.

 

It would be fascinating to know the process of implementing UXP. I guess they are connecting to the existing scripting API via UXP, which may involve an intermediate layer (and the speed bump). What else would explain the lower performance?

- Mark