Analysis brackets with labels: Difference between revisions
Appearance
Import snippet from LSR |
mNo edit summary |
||
| (3 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
Text markup may be added to analysis brackets | Text markup may be added to analysis brackets using the <code>text</code> property of the <code>HorizontalBracketText</code> grob. Adding different texts to brackets beginning at the same time requires the <code>\tweak</code> command. | ||
Bracket text | Bracket text gets parenthesized after a line break. | ||
<lilypond version="2.24"> | |||
\layout { | \layout { | ||
\context { | \context { | ||
| Line 31: | Line 29: | ||
</lilypond> | </lilypond> | ||
[[Category:Contexts and engravers]] | |||
[[Category:Editorial annotations]] | [[Category:Editorial annotations]] | ||
[[Category:Tweaks and overrides]] | [[Category:Tweaks and overrides]] | ||
[[Category:Included in the official documentation]] | [[Category:Included in the official documentation]] | ||
[[Category:Snippet]] | |||
Latest revision as of 12:09, 11 December 2025
Text markup may be added to analysis brackets using the text property of the HorizontalBracketText grob. Adding different texts to brackets beginning at the same time requires the \tweak command.
Bracket text gets parenthesized after a line break.
\version "2.24"
\layout {
\context {
\Voice
\consists "Horizontal_bracket_engraver"
\override HorizontalBracket.direction = #UP
}
}
{
\once\override HorizontalBracketText.text = "a"
c''\startGroup d''\stopGroup
\once\override HorizontalBracketText.text = "a'"
e''\startGroup d''\stopGroup |
c''-\tweak HorizontalBracketText.text
\markup \bold \huge "b" \startGroup
-\tweak HorizontalBracketText.text "a" \startGroup
d''\stopGroup
e''-\tweak HorizontalBracketText.text "a'" \startGroup
d''\stopGroup\stopGroup |
c''-\tweak HorizontalBracketText.text foo \startGroup
d'' e'' f'' | \break
g'' a'' b'' c'''\stopGroup
}