I wrote this script to aid in making animated gifs. To give an idea how it works, the image below (left) shows 3 blocks of .xcf files after loading as layers, and right shows their layer positions after running the script.
For the script to work correctly the user first needs to “Open as layers” a number of blocks, each of the blocks must contain the same number of layers. The script is then run with the user entering the number of blocks when prompted.
If the user enters a number that will divide into the total number of layers (in the example 15) with no remainder the script will run. In the example 3 (blocks) will give the correct outcome, 5 will run but give the wrong result, any other number exit’s the script after setting the foreground square to red, if I didn‘t exit it would crash.
Script here
Attachment:
re-order-layers.scm [1.7 KiB]
Downloaded 142 times
Placed at Layer > Stack > Re-order layers
The practise .xcf file here (the 3 .xcf blocks preloaded together)
Attachment:
Blue Green Red 1-5.xcf [29.21 KiB]
Downloaded 124 times
Any comments/critique on code or its performance welcome, always looking to learn and improve
Steve