duplicate layers

Post Reply
pcarvalho
Member
Posts: 24
Joined: Tue Dec 16, 2014 12:08 pm

duplicate layers

Post by pcarvalho »

Hello,
Is it possible to duplicate a layer and its contents, in a PDF?
Why do i ask this?, Because i want to rasterise the text but also want to keep it editable with 100% transparent.
bens
Advanced member
Posts: 253
Joined: Thu Mar 03, 2011 10:13 am

Re: duplicate layers

Post by bens »

First a small caveat: layers in PDF are nothing like layers in Photoshop. (In fact, layers don't exist in PDF. It's very unfortunate that Acrobat (and many other applications, including PitStop) talk about "layers" when they should be talking about "Optional Content". But let's not get too technical here.) Layers in Photoshop are like transparent sheets of paper with a well-defined order. In PDF, layers are just collections of objects, without order, and objects can appear on many layers without being duplicated.

That said, I think what you want is possible - but it will require a combination of Action Lists and manual work. I will assume you already have a PDF with the text in a layer called "Text", and you want a new layer "Raster" with the rasterized text.

First, select all text, copy it, and immediately paste it (if it moves, check the offsets in Preferences - Edit). Now you have two copies of the text: one in the layer Text, one without layer. Now we'll use an Action List to add the new copy to a new layer. Create an Action List with:

Select objects in layer by name ("Text")
NOT
Add objects to layer with name ("Raster")

And there you have it, the layer is duplicated. Check the result, and save a copy of the file.

Unfortunately the rasterizing part is a bit of a hassle (unless you have some other application to do it more easily). PitStop cannot rasterize only selected objects or layers: it's either a full page or nothing. So, open the original file again, and rasterize that using an Action List. Select and copy the resulting image, and paste it in the file with two layers. Then use a similar Action List as above to add the image to the Raster layer.

Alternatively, you can use the "Select last added objects" action after rasterizing. This will select the new image and you can add it to the Raster layer in the same Action List. But then you will still need to go back to your original document to copy and paste the text again.
Post Reply