Copy link to clipboard
Copied
Hi, I have a 780 page document that consists of 110 InDesign files. The file was set up by someone else to European standards and the copy is too close to the edge of the page for our printer to be able to hold the current safety zone and has asked for more space. So, I need to go in and move all the copy and other vital elements at laeast 3/16" from the Trim Area, and then adjust all the elements to be inside the Safety Area.
Is there a way to have these Safety Marks set up in some script or macro process? Having those marks would make all the other adjustment work I need to do much easier. Thanks!
Try this AppleScript
set safezone to 0.375
tell application id "com.adobe.indesign"
tell active document
set docviewprefs to properties of view preferences
set properties of view preferences to {ruler origin:spread origin, vertical measurement units:inches, horizontal measurement units:inches}
set zero point to {0.0, 0.0}
set p to every page
repeat with x in p
tell x
set {a, b, c, d} to bounds
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:a + safezone}
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:c - safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:b + safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:d - safezone}
end tell
end repeat
set properties of view preferences to docviewprefs
end tell
end tell
Copy link to clipboard
Copied
Hi, I have a 780 page document that consists of 110 InDesign files. The file was set up by someone else to European standards and the copy is too close to the edge of the page for our printer to be able to hold the current safety zone and has asked for more space. So, I need to go in and move all the copy and other vital elements at laeast 3/16" from the Trim Area, and then adjust all the elements to be inside the Safety Area.
Is there a way to have these Safety Marks set up in some script or macro process? Having those marks would make all the other adjustment work I need to do much easier. Thanks!
Try this AppleScript
set safezone to 0.375
tell application id "com.adobe.indesign"
tell active document
set docviewprefs to properties of view preferences
set properties of view preferences to {ruler origin:spread origin, vertical measurement units:inches, horizontal measurement units:inches}
set zero point to {0.0, 0.0}
set p to every page
repeat with x in p
tell x
set {a, b, c, d} to bounds
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:a + safezone}
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:c - safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:b + safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:d - safezone}
end tell
end repeat
set properties of view preferences to docviewprefs
end tell
end tell
Copy link to clipboard
Copied
Do the pages have Masters? If they do make a layer on top and add page guides to the masters.
Copy link to clipboard
Copied
I missed the 110 InDesign files part. Are the 110 files part of a Book file?
Copy link to clipboard
Copied
Hi Rob, thanks for your reply. Yes, they do have masters, and the 110 files are part of a Book File. I'm loooking for some way to set this up once and replicate it in some autonomous fashion rather than do it 780 or even 110 times. Thanks!
Copy link to clipboard
Copied
You can take a look at Quick Resize: http://www.id-extras.com/products/quickresize/
Copy link to clipboard
Copied
Thanks Brian, Unfortunately we need to keep the overall document the same size so this won't work. We just need to adjust the bleed and safeties on every page of all files in the book (then go in and manually adjust all the elements). I'm just looking for an easy way to set up the safety guides on 780 pages across 110 docs. I appreciate the suggestion though.
Copy link to clipboard
Copied
What OS are you using?
Copy link to clipboard
Copied
Mac Catalina 10.15.6
Copy link to clipboard
Copied
Try this AppleScript
set safezone to 0.375
tell application id "com.adobe.indesign"
tell active document
set docviewprefs to properties of view preferences
set properties of view preferences to {ruler origin:spread origin, vertical measurement units:inches, horizontal measurement units:inches}
set zero point to {0.0, 0.0}
set p to every page
repeat with x in p
tell x
set {a, b, c, d} to bounds
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:a + safezone}
make new guide with properties {orientation:horizontal, guide type:ruler, fit to page:true, location:c - safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:b + safezone}
make new guide with properties {orientation:vertical, guide type:ruler, fit to page:true, location:d - safezone}
end tell
end repeat
set properties of view preferences to docviewprefs
end tell
end tell
Copy link to clipboard
Copied
Thanks Rob. I'll give it a shot and let you know how it goes. I appreciate you taking the time to write the script for me.
Copy link to clipboard
Copied
Hi Rob, that didn't seem to work. It didn't add any visual guides for me. (Using InDesign CC 14.0.1) I'm going to see if I can play around with it a bit, but I'm still open to other suggestions. Thanks.
Copy link to clipboard
Copied
Do you get an error, or are the simply guides not added? Are you running the script from AppleScript Editor, or are you compiling it in Script file format, and running it from your Scripts folder?
Copy link to clipboard
Copied
Hi Rob, I have InDesign CC open, one of the InDesign files open, and am running the script from the Script Editor. I'm not very familar with how to manage scripts, so if I'm doing something wrong I appreacaite the feedback/direction. Thanks.
Copy link to clipboard
Copied
The script is adding page guides, are you sure you don’t have guides hidden—View>Grids & Guides>Show Guides? And your View>Screen Mode is set to Normal?
Copy link to clipboard
Copied
This is what I get with guides showing in Normal mode when I Run
Copy link to clipboard
Copied
Thanks Rob. Perhaps I'm doing something wrong... I'm not getting that. In fact, it seems like nothing happens on my end.
Copy link to clipboard
Copied
Can you share a sample file via your CC account or Dropbox?
Copy link to clipboard
Copied
Here’s a compiled version. You could try copying it into your Scripts folder and see if that works. I’m not using Catalina so it might be a script editor problem that I’m not aware of.
https://shared-assets.adobe.com/link/df3a2514-9d28-43d4-7816-e6052b4795e6
Copy the script file here:
/Applications/Adobe InDesign 2020/Scripts/Scripts Panel
and it should show in your ID Scripts panel. Double click to run.
Copy link to clipboard
Copied
Thanks Rob.
I followed your directions above and it didn't seem to work for me. Here's a link to the file on Dropbox. Does it work for you? https://www.dropbox.com/s/u8uslcej4heoui0/0101_Energieketten.indd?dl=0
Copy link to clipboard
Copied
It worked for me.
I notice your file is saved with the View>Screen Mode set to Preview, and page guides don’t show in Preview mode. Also there are a lot of page items and the guides get added on the bottom layer. The script could create a top layer for the guides with the color set to black.
Here I’ve hidden your layers with the bottom layer showing so it is easier to see the scripted guides:
Copy link to clipboard
Copied
Here’s your doc saved with the added guides and the updated compiled script which puts the guides on their own layer:
https://shared-assets.adobe.com/link/b5a5760d-ccc2-4c26-59a1-99b21da54669
Copy link to clipboard
Copied
Thank you so much Rob! I really appreciate your help. Having the guides on a top layer is definitely helpful, as I just want to adjust elements to be inside those guides.
Quick couple of questions. Does this script add the guides to every doc that's open in InDeisgn? Or only the doc that I'm in? Or only the page I'm on? And is it additng to masters or pages?
Copy link to clipboard
Copied
Its adding 4 guides to each page of the active document. The master pages are not included