adobe-indesign

Extracting InDesign CS4 Graphics using C# and COM

巧了我就是萌 提交于 2021-02-16 09:30:22
问题 I'm trying to get details of the graphics in an InDesign file. For technical reasons I'm using COM. Not my favourite, as (discussed elsewhere in StackOverflow) you have to spend half your life casting. In Theory (!), the code snippet belwo should work. Intellisense shows doc.AllGraphics as returning objects . The CS3 scripting reference at http://www.indesignscriptingreference.com/CS3/JavaScript/Document.htm shows it as Array of Graphic for (int g = 1; g <= doc.AllGraphics.Count; g++) {

save InDesign ScriptUI options in file and load in the next run

牧云@^-^@ 提交于 2021-01-29 15:31:18
问题 I built a Dialog in InDesign script that has any options. I want to save the settings the user selects in a file (For example in a file named setting.ini) to do not require a re-adjustment in the next run and the same settings are enabled for the Dialog. Is there such a possibility? 回答1: Yes, you can use the label functionality to save any information to any InDesign objects. To save things from dialogs that you want to access the next time that a script is run, it would make most sense to

Indesign Script JS: Edit Document TextFrame Content and get back to Dialog Window

馋奶兔 提交于 2021-01-29 08:31:17
问题 I want to edit some textframe content in Indesign documents by JS. But I cannot find any solution to get any change with feedback in Dialog Window. So I just have a simple document with one Textframe with name test I just paste relevant parts to keep it simple, in my Dialog I have lot of settings... var w = new Window ("dialog","DialogTitle"); var changeText = w.add("button", [0,0,150,20], "change test Text"); changeText.onClick = function(){ w.close(1); } var result = w.show(); if (result ==

Need to JSON stringify an object in ExtendScript

醉酒当歌 提交于 2021-01-23 06:17:40
问题 I am working on processing meta data information of my Indesign document links, using ExtentdScript. I want to convert the object to string using JSON.stringify but when I use it, I am getting error saying: can't execute script in target engine . If I remove linkObjStr = JSON.stringify(linksInfObj); from below code, then everything works fine. What is the equivalent to JSON.stringify in ExtendScript, or is there any other possibilities to display linksInfObj with its proper contents instead

Need to JSON stringify an object in ExtendScript

徘徊边缘 提交于 2021-01-23 06:17:07
问题 I am working on processing meta data information of my Indesign document links, using ExtentdScript. I want to convert the object to string using JSON.stringify but when I use it, I am getting error saying: can't execute script in target engine . If I remove linkObjStr = JSON.stringify(linksInfObj); from below code, then everything works fine. What is the equivalent to JSON.stringify in ExtendScript, or is there any other possibilities to display linksInfObj with its proper contents instead

InDesign javascript to find overlapping textframes

梦想的初衷 提交于 2021-01-07 03:34:06
问题 is there anyway in InDesign using Javascript to search for any text frames in a document that overlaps? I've been looking through a document with all the properties of TextFrame and can't find anything that might tell whether there's any overlapping boxes or not. I don't know Javascript but do know Ruby so i understand bits of it. 回答1: Each Page object has got a read only attribute textFrames with alle textFrames on the page. Each textFrame has got a method visibleBounds which will return an

InDesign javascript to find overlapping textframes

谁都会走 提交于 2021-01-07 03:33:55
问题 is there anyway in InDesign using Javascript to search for any text frames in a document that overlaps? I've been looking through a document with all the properties of TextFrame and can't find anything that might tell whether there's any overlapping boxes or not. I don't know Javascript but do know Ruby so i understand bits of it. 回答1: Each Page object has got a read only attribute textFrames with alle textFrames on the page. Each textFrame has got a method visibleBounds which will return an

InDesign javascript to find overlapping textframes

ⅰ亾dé卋堺 提交于 2021-01-07 03:33:28
问题 is there anyway in InDesign using Javascript to search for any text frames in a document that overlaps? I've been looking through a document with all the properties of TextFrame and can't find anything that might tell whether there's any overlapping boxes or not. I don't know Javascript but do know Ruby so i understand bits of it. 回答1: Each Page object has got a read only attribute textFrames with alle textFrames on the page. Each textFrame has got a method visibleBounds which will return an

How to execute an InDesign extendscript from command line?

北慕城南 提交于 2020-07-18 07:38:10
问题 I need to execute a .jsx script for InDesign from command line (Windows). For Illustrator, it works easily with the following command: "C:\Program Files\Adobe\Adobe Illustrator CS6 (64 Bit)\Support Files\Contents\Windows\Illustrator.exe" "...\myscript.jsx" Both applications Illustrator and ExtendScript Toolkit CS6 open then the script is automatically launched. When I try the same for InDesign, it doesn't work (InDesign says 'Unable to open myscript.jsx ...'). I also tried to launch

How to group XML elements in in-design by adding them to a parent tag

ぃ、小莉子 提交于 2020-03-04 05:53:09
问题 I have XML elements linked to the root element of the document and there are some elements that should be grouped and then linked to the design document, So I would like to know how I can create a virtual group and add the elements to a parent tag that will, in turn, be the child of the parent in InDesign scripting Existing : -EL1 -EL2 -EL3 -EL4 -EL5 Expected: -EL1 -EL --EL2 --EL3 --EL4 -EL5 Where EL is the parent and EL2,EL3,EL4 are the child elements. 回答1: Setup a demo .indd To provide some