We have some important news to share: the Pixelmator Team plans to join Apple. If you need product support please contact us here.

Learn more

AppleScript Reorder

Talk about Pixelmator Pro, share tips & tricks, tutorials, and other resources.

The Pixelmator Community has been archived and cannot accept new posts or comments.

User avatar

2022-02-28 15:52:03

Is there a way to flip the order of the layers via AppleScript?

Thank you
User avatar

2022-03-09 15:42:50

Good question! You can try the following script:
tell application "Pixelmator Pro"
	tell the front document
		repeat with a from 1 to number of layers
			move layer (number of layers) to before layer a
		end repeat
	end tell
end tell
One slight issue with AppleScript is that it doesn't really like nested layers, so if there are any groups in your project, you'd have to reorder the layers in them manually.
User avatar

2022-03-09 15:53:18

I ended up solving it another way but thank you.
User avatar

2022-03-10 13:18:31

by dick rick I ended up solving it another way but thank you.
Ah, I see. Perhaps it'll come in handy another time, then. :)
User avatar

2023-11-08 14:41:55

This helped me, thank you!