Valentin

Are these worth a snippet (or two?) for Rhythms?

\relative c'' {
 % Print the first and every fifth bar numbers
 \set Score.barNumberVisibility = #(every-nth-bar-number-visible 1)
 \override Score.BarNumber #'break-visibility = #all-visible
 \bar ""
 c1
 \set Score.barNumberVisibility = #(every-nth-bar-number-visible 5)
 \repeat unfold 9 { c1 }
}

The alternative is Neil's music function:

#(define ((first-and-every-nth-bar-number-visible n) barnum)
         (or
           (= 1 barnum)
           (= 0 (modulo barnum n))))

\relative c'' {
 \override Score.BarNumber #'break-visibility = #end-of-line-invisible
\set Score.barNumberVisibility = #(first-and-every-nth-bar-number-visible 5)
 \bar ""
 \repeat unfold 10 { c1 }
}

Trevor



_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to