Cf. <URL:http://lists.gnu.org/archive/html/bug-lilypond/2013-10/msg00083.html>.
Actually, the whole function is an obfuscated Scheme programming
contest. I made a few of the more flamboyant list manipulations
boring while at it.
x))
pointlist))
;; a path must begin with a `moveto'
- (prepend-origin (apply list (cons 'moveto origin) path))
+ (prepend-origin (cons (cons 'moveto origin) path))
;; if this path is connected, add closepath to the end
(final-path (if connect
- (append prepend-origin (list 'closepath))
+ (append prepend-origin (list '(closepath)))
prepend-origin))
- (command-list (fold-right append '() final-path)))
+ (command-list (concatenate final-path)))
(ly:make-stencil
`(path ,thickness
`(,@',command-list)