5 "With @code{music-map}, you can apply functions operating on a single
6 piece of music to an entire music expression. In this example, the
7 scripts and dynamics of the first measure of music are applied to the
15 #(define (notes-to-skip m)
16 "Convert all stuff with duration (notes, lyrics, bass figures, etc.) to skips.
17 Scripts and dynamics are maintained.
19 (if (memq 'rhythmic-event (ly:get-mus-property m 'types))
20 (let* ((newmus (make-music-by-name 'SkipEvent)))
22 (lambda (x) (ly:set-mus-property! newmus (car x) (cdr x)))
23 (ly:get-mutable-properties m))
30 foobar = \notes \transpose c c' { c4-\>-^ c4-^ c4-\!-^ c4-^ }
33 \notes \relative c'' \context Voice {
36 < \apply #(lambda (x) (music-map x notes-to-skip))