Alternative bar numbering: Difference between revisions
Appearance
m New category Tags: Mobile edit Mobile web edit |
m Improve display for PDF output in the documentation |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
Setting the <code>alternativeNumberingStyle</code> context property, two additional methods are available for enumerating bar numbers in repeats. | |||
<lilypond version="2.24" | <lilypond version="2.24"> | ||
music = \relative c' { | music = \relative c' { | ||
\repeat volta 3 { | \repeat volta 3 { | ||
| Line 12: | Line 12: | ||
} | } | ||
{ | { | ||
\textMark \markup \large "default" | |||
\music | \music | ||
} | } | ||
{ | { | ||
\textMark \markup \large \typewriter "numbers" | |||
\set Score.alternativeNumberingStyle = #'numbers | \set Score.alternativeNumberingStyle = #'numbers | ||
\music | \music | ||
} | } | ||
{ | { | ||
\textMark \markup \large \typewriter "numbers-with-letters" | |||
\set Score.alternativeNumberingStyle = #'numbers-with-letters | \set Score.alternativeNumberingStyle = #'numbers-with-letters | ||
\music | \music | ||
} | } | ||
\ | \layout { | ||
\context { | |||
\Score | |||
\override TextMark.Y-offset = #5 | |||
} | |||
} | |||
</lilypond> | </lilypond> | ||
[[Category:Editorial annotations]] | [[Category:Editorial annotations]] | ||
[[Category:Staff notation]] | [[Category:Staff notation]] | ||
[[Category:Tweaks and overrides]] | [[Category:Tweaks and overrides]] | ||
[[Category:Included in the official documentation]] | |||
[[Category:Snippet]] | [[Category:Snippet]] | ||
Latest revision as of 06:00, 11 January 2026
Setting the alternativeNumberingStyle context property, two additional methods are available for enumerating bar numbers in repeats.
\version "2.24"
music = \relative c' {
\repeat volta 3 {
c4 d e f |
\alternative {
\volta 1 { c4 d e f | c2 d \break }
\volta 2 { f4 g a b | f4 g a b | f2 a | \break }
\volta 3 { c4 d e f | c2 d } } }
c1 \bar "|."
}
{
\textMark \markup \large "default"
\music
}
{
\textMark \markup \large \typewriter "numbers"
\set Score.alternativeNumberingStyle = #'numbers
\music
}
{
\textMark \markup \large \typewriter "numbers-with-letters"
\set Score.alternativeNumberingStyle = #'numbers-with-letters
\music
}
\layout {
\context {
\Score
\override TextMark.Y-offset = #5
}
}