(define (-1+ n)
(- n 1))
(define (rename-all-layers image renamer)
(let*
((res (gimp-image-get-layers image))
(nlayers (car res))
(layers (vector->list (cadr res)))
(loop
(lambda (total-layers layers)
(if (> (length layers) 0)
(let*
((layer (car layers))
(layer-index (-1+ (length layers)))
(layer-name (renamer layer layer-index total-layers)))
Message too long. Click here to view full text.