]> git.donarmstrong.com Git - lilypond.git/commitdiff
repeat tremolo: robust to zero-duration elements
authorKeith OHara <k-ohara5a5a@oco.net>
Sun, 3 May 2015 05:49:54 +0000 (22:49 -0700)
committerKeith OHara <k-ohara5a5a@oco.net>
Fri, 15 May 2015 06:07:18 +0000 (23:07 -0700)
scm/music-functions.scm

index 611879ae8b517ec9bb23d3507d1cdd3b10af84b6..65f885bbf87e1a76921c7f3e8e98900e2b0c980c 100644 (file)
@@ -285,8 +285,9 @@ depth-first through MUSIC."
          (body (ly:music-property tremolo 'element))
          (children (if (music-is-of-type? body 'sequential-music)
                        ;; \repeat tremolo n { ... }
-                       (length (extract-named-music body '(EventChord
-                                                           NoteEvent)))
+                       (count duration-of-note ; do not count empty <>
+                              (extract-named-music body
+                                                   '(EventChord NoteEvent)))
                        ;; \repeat tremolo n c4
                        1))
          (tremolo-type (if (positive? children)