@c -*- coding: utf-8; mode: texinfo; -*-
+@c This file is part of lilypond.tely
+@ignore
+ Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
+
+ When revising a translation, copy the HEAD committish of the
+ version that you are working on. See TRANSLATION for details.
+@end ignore
+
@node Example templates
@appendix Example templates
}
@end lilypond
+@appendixsubsec SATB with aligned contexts
+
+Here all the lyrics lines are placed using @code{alignAboveContext}
+and @code{alignBelowContext}.
+
+@lilypond[quote,verbatim,ragged-right]
+\version "2.10.0"
+global = {
+ \key c \major
+ \time 4/4
+}
+
+sopMusic = \relative c'' {
+ c4 c c8[( b)] c4
+}
+sopWords = \lyricmode {
+ hi hi hi hi
+}
+
+altoMusic = \relative c' {
+ e4 f d e
+}
+altoWords =\lyricmode {
+ ha ha ha ha
+}
+
+tenorMusic = \relative c' {
+ g4 a f g
+}
+tenorWords = \lyricmode {
+ hu hu hu hu
+}
+
+bassMusic = \relative c {
+ c4 c g c
+}
+bassWords = \lyricmode {
+ ho ho ho ho
+}
+
+\score {
+ \new ChoirStaff <<
+ \new Staff = women <<
+ \new Voice =
+ "sopranos" { \voiceOne << \global \sopMusic >> }
+ \new Voice =
+ "altos" { \voiceTwo << \global \altoMusic >> }
+ >>
+ \new Lyrics \with {alignAboveContext=women} \lyricsto sopranos \sopWords
+ \new Lyrics \with {alignBelowContext=women} \lyricsto altos \altoWords
+% we could remove the line about this with the line below, since we want
+% the alto lyrics to be below the alto Voice anyway.
+% \new Lyrics \lyricsto altos \altoWords
+
+ \new Staff = men <<
+ \clef bass
+ \new Voice =
+ "tenors" { \voiceOne <<\global \tenorMusic >> }
+ \new Voice =
+ "basses" { \voiceTwo <<\global \bassMusic >> }
+ >>
+
+ \new Lyrics \with {alignAboveContext=men} \lyricsto tenors \tenorWords
+ \new Lyrics \with {alignBelowContext=men} \lyricsto basses \bassWords
+% again, we could replace the line above this with the line below.
+% \new Lyrics \lyricsto basses \bassWords
+ >>
+
+ \layout {
+ \context {
+ % a little smaller so lyrics
+ % can be closer to the staff
+ \Staff
+ \override VerticalAxisGroup #'minimum-Y-extent = #'(-3 . 3)
+ }
+ }
+}
+
+
+\score {
+ \new ChoirStaff <<
+ \new Staff = women <<
+ \new Voice =
+ "sopranos" { \voiceOne << \global \sopMusic >> }
+ \new Voice =
+ "altos" { \voiceTwo << \global \altoMusic >> }
+ >>
+
+ \new Lyrics \with {alignAboveContext=women} \lyricsto sopranos \sopWords
+ \new Lyrics \lyricsto altos \altoWords
+
+ \new Staff = men <<
+ \clef bass
+ \new Voice =
+ "tenors" { \voiceOne <<\global \tenorMusic >> }
+ \new Voice =
+ "basses" { \voiceTwo <<\global \bassMusic >> }
+ >>
+
+ \new Lyrics \with {alignAboveContext=men} \lyricsto tenors \tenorWords
+ \new Lyrics \lyricsto basses \bassWords
+ >>
+
+ \layout {
+ \context {
+ % a little smaller so lyrics
+ % can be closer to the staff
+ \Staff
+ \override VerticalAxisGroup #'minimum-Y-extent = #'(-3 . 3)
+ }
+ }
+}
+@end lilypond
+
@c bad node name to avoid node name confict
@node Ancient notation templates