-
1. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
sstanleyau Jul 9, 2008 6:53 PM (in response to (Cara_Brooke_Adams))You want something like this (untested):<br /><br />tell application "Adobe InDesign CS3"<br /> tell document 1<br /> set properties of all graphics whose class is image to {clipping<br />path:{applied path name:"Path 1", clipping type:photoshop path}}<br /> end tell<br />end tell<br /><br />But it may run into problems if there are pics with no such path.<br /><br />-- <br />Shane Stanley <sstanley@myriad-com.com.au> -
2. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
(StevenV) Aug 11, 2008 12:59 PM (in response to (Cara_Brooke_Adams))I am looking for a script to do the exact opposite. We have a large catalog which has been converted from Quark and we need to quickly turn off all the clipping paths. Do you know of any? -
3. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
(StevenV) Oct 7, 2008 12:42 PM (in response to (Cara_Brooke_Adams))Does anyone have an update to this question of turning the paths off in Indesign? -
4. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
Eric @ MCA Oct 7, 2008 5:10 PM (in response to (Cara_Brooke_Adams))Maybe something like this? I haven't tested thoroughly, but it should turn off every clipping in the document I think...
tell application "Adobe InDesign CS2"
tell active document
repeat with thisGraphic in all graphics of every page
set clipping type of clipping path of thisGraphic to none
end repeat
end tell
end tell -
5. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
(jasonbak) Apr 2, 2009 6:39 AM (in response to (Cara_Brooke_Adams))The script to turn off the clipping paths works great. -Thanks
I get an error when trying to run the script to turn the clipping paths on.
Adobe InDesign CS3 got an error: Invalid value for set property 'clipping type'. Expected none/detect edges/alpha channel/photoshop path/user modified path, but received (=>("clippingpath", (clipping type=>photoshop path,applied path name=>"Path 1"))).
Running InDesign CS3 version 5.0.4 -
6. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
joesickspack Oct 15, 2010 6:13 PM (in response to (jasonbak))This works in CS4:
tell application "Adobe InDesign CS4"
tell active document
repeat with thisGraphic in all graphics of every page
try
set (properties of thisGraphic) to {clipping path:{clipping type:detect edges, inset frame:-0.5, restrict to frame:true, threshold:1, tolerance:0, use high resolution image:true}}
end try
end repeat
end tell
end tell
For Photoshop path substitute in this line:
set (properties of thisGraphic) to {clipping type:photoshop path, clipping path:{applied path name:"Path 1"}}
For other properties see:
CS3: http://www.indesignscriptingreference.com/CS3/AppleScript/clipping-path-settings.htm
CS4: http://www.indesignscriptingreference.com/CS4/AppleScript/clipping-path-settings.htm
-
7. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
Andrew Kinnear Feb 7, 2012 8:16 AM (in response to Eric @ MCA)Eric @ MCA wrote:
tell application "Adobe InDesign CS2"
tell active document
repeat with thisGraphic in all graphics of every page
set clipping type of clipping path of thisGraphic to none
end repeat
end tell
end tellBrilliant, thank you for posting that Eric.
Can anyone translate this to JavaScript? I'm attempting to learn and I find like for like examples help hugely.
Apologies for resurrecting an old thread, just noticed the date, sorry.
-
8. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
John Hawkinson Feb 8, 2012 7:42 PM (in response to Andrew Kinnear)var i, j, allGraphics, allGraphicsArrays = app.activeDocument.pages.everyItem().allGraphics; for (i=0; i<allGraphicsArrays.length; i++) { allGraphics = allGraphicsArrays[i]; for (j=0; j<allGraphics.length; j++) { allGraphics[j].clippingPath.clippingType = ClippingPathType.NONE; } }
-
9. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
Andrew Kinnear Feb 9, 2012 2:06 AM (in response to John Hawkinson)Thank you very much for taking the time to do that John, that's extremely helpful and working perfectly.
Andrew
-
10. Re: Applescript that turns ON all Clipping Paths in InDesign CS3 document
gpub Oct 9, 2012 6:05 PM (in response to Andrew Kinnear)Was/ is anyone able to create a .jsx script to turn "all" paths on in a document?
I work in designing and laying out catalogs and this would save a ton of time. Thanks again!
Gabe