Quantcast
Channel: Adobe Community: Message List - Photoshop Scripting
Viewing all articles
Browse latest Browse all 27456

Copy Shape Attributes & Layer Style from one layer & paste to another?

$
0
0

I don't know Photoshop scripting and wanted a script to copy both the Shape Attributes and Layer Style from one layer, and then another script to paste them to a different layer.

 

I used the ScriptingListener plugin to record these and they do work, but with a problem. If the vector shape has layer styles it will work fine, but if the the shape I'm copying doesn't have any layer styles then it shows an error (as it's trying to copy layer styles that aren't there).

 

Is it possible for a script to detect whether layer styles are present, and if not ignore that and just copy/paste the shape attributes? Or could the script 'try' to copy layer styles but 'fail silently' if none are applied to a layer, and then just copy/paste only the shape attributes?


Viewing all articles
Browse latest Browse all 27456

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>