Indesign help

YouKPrinter

New member
Afternoon all,

I'm more of an Adobe Illustrator user, but realising the force is strong with Adobe Indesign.

I've got a mountain of documents to get through, and need to do the following tasks...

1. Create 3 new layers (Text / Artwork / Background)
2. Assign all text elements to text layer
Assign all images and vectors to Artwork layers
Assign background to background Layer

3. Resize the document canvas on all pages from Size A to Size B

Are there any nifty script shortcuts I could use?

///////

I wondered if at very least, there was a script that'd pick up all the text elements and pop them onto the text layer

(i'm doubtful if images / vectors / backgrounds could be identified automatically and moved to the respective layers)

And, I'm hoping that there is a way, I could bulk change the document canvas settings with a script.

Fingers crossed, and thanks a million in advance.

Tim
 
A quick Google search kicked up the following script for images:

https://indesignsecrets.com/topic/sc...seperate-layer (ensure that quotes are straight, not curly)

This script is not for batch processing, it is one document at a time...

It should just take a little bit of hacking to work for text frames, which may or may not be beyond my current beginner scripting abilities! A wider search may turn up a script for text etc.

Depending on the layout, there could be stacking issues if the image is above or below the text layer… or perhaps stacking/ordering problems between images.

Test with care.

P.S. Not sure how the background would be identified… However once the images and text are isolated on their own layer, perhaps the only thing left is the background (presuming no other native objects are used)?

Resizing the document may or may not be so easy, content can be adapted to fit or not etc.



Stephen Marsh
 
Last edited:
Here is a script for the Text layer:

Code:
// https://forums.adobe.com/thread/583929
var newLayer = app.activeDocument.layers.add({name:"Text"});
var tfs =
app
.activeDocument
.spreads.everyItem().textFrames.everyItem().getElements();
while(tf = tfs.pop()){
   tf.move(newLayer);
}


Test with care. Hope this helps,

Stephen Marsh
 
Last edited:
Glad to try to help. I did notice that the stacking order changes, so if elements overlap then they could potentially end up in the incorrect order. Both scripts can be combined into a single script to save running twice.


Stephen Marsh
 
Last edited:
I've done quite a bit of InDesign scripting myself and what you've stated definitely sounds possible. Just reviewing what everyone else has said, here's a couple of thoughts:

1) I would create a script that loops through all files in a folder and processes the script to do batch processing
2) To avoid the error of stacking order changes, group the items first. Grouping the items should preserve the item order. Then move the group to the new layer
3) As for the background, I'm not sure how the file is built but you could try to identify the background by it's size. So if it's always the full portion of the page, you could filter it that way.

In my experience, anything that a user can do while interacting with the InDesign UI can be done with scripting. In fact, scripting can probably do more..

Depending on how many files you have to process, a script can definitely save you tons of time. If you'd like, you can message me and maybe send me an example file (take out anything confidential or proprietary) and perhaps I can help you develop a script. Or if you have questions let me know.

Good Luck!
 

PressWise

A 30-day Fix for Managed Chaos

As any print professional knows, printing can be managed chaos. Software that solves multiple problems and provides measurable and monetizable value has a direct impact on the bottom-line.

“We reduced order entry costs by about 40%.” Significant savings in a shop that turns about 500 jobs a month.


Learn how…….

   
Back
Top