Photoshop Flip a layer?

How can flip the image layer on the vertical or the Horizontal?


I can only find flip canvas in the library.


or

rotatecurrent layerangle -180 anchor positionbottom center


But not to flip the image?

iMac, Mac OS X (10.6.8)

Posted on Oct 17, 2012 8:05 AM

Reply
3 replies

Oct 17, 2012 12:19 PM in response to MattJayC

I just dug this out my old script stuff. Photoshop has a scriptlistener plugin that you can install. As far as AppleScript is concerned it's JavaScript so you can use it with the do javascript command. It allows you much more access to Photoshop's capabilities as scriptable image editor. The syntax of the plugin output is Photoshop ActionManager code. You could also record your other question using this. Anyhow's this should work although it may look a little alien… Pass it a reference to a document and an app constant… As you can see I used to use this with CS2. Set the active layer first and test it's not background…


on Flip_HV(Doc_Ref, H_or_V)

tell application "Adobe Photoshop CS2"

if H_or_V is vertical then set H_or_V to "Vrtc"

if H_or_V is horizontal then set H_or_V to "Hrzn"

tell Doc_Ref

do javascript "Flip_HV(); function Flip_HV() {function cTID(s) { return app.charIDToTypeID(s); }; function sTID(s) { return app.stringIDToTypeID(s); }; var desc01 = new ActionDescriptor(); var ref01 = new ActionReference(); ref01.putEnumerated( cTID('Lyr '), cTID('Ordn'), cTID('Trgt') ); desc01.putReference( cTID('null'), ref01 ); desc01.putEnumerated( cTID('Axis'), cTID('Ornt'), cTID('" & H_or_V & "') ); executeAction( cTID('Flip'), desc01, DialogModes.NO ); };" show debugger on runtime error

end tell

end tell

end Flip_HV

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Photoshop Flip a layer?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.