For more information, see @ref{Special characters}.
@lilypond[quote,verbatim]
-\relative c'' { d8 c16 a bes8 f e' d c4 }
+\relative c'' { d8 c16 a bes8 f ees' d c4 }
\addlyrics { „Schad’ um das schö -- ne grü -- ne Band, }
@end lilypond
@funindex \addlyrics
@funindex \lyricsto
-Lyrics are printed by interpreting them in the context called
-@code{Lyrics}, see @ref{Contexts explained}.
+Lyrics are interpreted in @code{\lyricmode} and printed in a
+@code{Lyrics} context, see @ref{Contexts explained}.
@example
\new Lyrics \lyricmode @{ @dots{} @}
@end example
+Two variants of @code{\lyricmode} additionally set an associated
+context used to synchronise the lyric syllables to music. The more
+convenient @code{\addlyrics} immediately follows the musical content
+of the Voice context with which it should be synchronised, implicitly
+creating a Lyrics context of its own. The more versatile
+@code{\lyricsto} requires both specifying the associated Voice context
+by name and explicitly creating a containing Lyrics context. For
+details see @ref{Automatic syllable durations}.
+
Lyrics can be aligned with melodies in two main ways:
@itemize
@code{Voice} context is specified first, followed by the
@code{Lyrics} context. The lyrics themselves follow the
@code{\lyricsto} command. The @code{\lyricsto} command
-invokes lyric mode automatically, so the @code{\lyricmode} keyword
-may be omitted. By default, the lyrics are placed underneath the
-notes. For other placements, see @ref{Placing lyrics vertically}.
+invokes lyric mode automatically. By default, the lyrics are placed
+underneath the notes. For other placements, see
+@ref{Placing lyrics vertically}.
@subheading Using @code{\addlyrics}
@ref{Score layout},
@ref{Separating systems},
@ref{Setting the staff size},
-@ref{Explicit breaks},
+@ref{Breaks},
@ref{Vertical spacing}.
Internals Reference:
c c c
@end lilypond
-Alternatively, if there are many character changes, it may be
-easier to set up @qq{instrument} definitions for each character at
-the top level so that @code{\instrumentSwitch} can be used to
-indicate each change. As notes for vocal parts are usually entered
-at sounding pitch no instrument transposition is required, even
-when, as here, the tenor line is printed an octave higher.
+Alternatively, if there are many character changes, it may be easier
+to set up variables to hold the definitions for each character so
+that the switch of characters can be indicated easily and concisely.
@lilypond[quote,verbatim]
-\addInstrumentDefinition #"kaspar"
- #`((instrumentTransposition . ,(ly:make-pitch 0 0 0))
- (shortInstrumentName . "Kas.")
- (clefGlyph . "clefs.G")
- (clefTransposition . -7)
- (middleCPosition . 1)
- (clefPosition . -2)
- (instrumentCueName . ,(markup #:fontsize 1 #:smallCaps "Kaspar"))
- (midiInstrument . "voice oohs"))
-
-\addInstrumentDefinition #"melchior"
- #`((instrumentTransposition . ,(ly:make-pitch 0 0 0))
- (shortInstrumentName . "Mel.")
- (clefGlyph . "clefs.F")
- (clefTransposition . 0)
- (middleCPosition . 6)
- (clefPosition . 2)
- (instrumentCueName . ,(markup #:fontsize 1 #:smallCaps "Melchior"))
- (midiInstrument . "choir aahs"))
+kaspar = {
+ \clef "G_8"
+ \set Staff.shortVocalName = "Kas."
+ \set Staff.midiInstrument = "voice oohs"
+ <>^\markup \smallCaps "Kaspar"
+}
+
+melchior = {
+ \clef "bass"
+ \set Staff.shortVocalName = "Mel."
+ \set Staff.midiInstrument = "choir aahs"
+ <>^\markup \smallCaps "Melchior"
+}
\relative c' {
- \instrumentSwitch "kaspar"
+ \kaspar
c4 c c c
- \instrumentSwitch "melchior"
+ \melchior
a4 a a a
- \instrumentSwitch "kaspar"
+ \kaspar
c4 c c c
}
@end lilypond
@seealso
+Learning Manual:
+@rlearning{Organizing pieces with variables}.
+
Notation Reference:
-@ref{Instrument names},
-@ref{Scheme functions},
@ref{Text},
@ref{Text markup commands}.
-Extending LilyPond:
-@rextend{Markup construction in Scheme}.
-
@node Musical cues
@unnumberedsubsubsec Musical cues
c4. g8
% position name of cue-ing instrument just before the cue notes,
% and above the staff
- \new CueVoice {
- \override InstrumentSwitch.self-alignment-X = #RIGHT
- \set instrumentCueName = "Flute"
- }
+ <>^\markup { \right-align { \tiny "Flute" } }
\cueDuring "flute" #UP { g4 bes4 }
}
pianoLH = \relative c { c4 <c' e> e, <g c> }
automatically. The example below shows this transposition for a
B-flat clarinet. The notes in this example are low on the staff so
@code{DOWN} is specified in @code{\cueDuring} (so the stems are
-down) and the instrument name is positioned below the staff. Note
-also that the piano right-hand voice is explicitly declared. This
-is because the cue notes in this example begin at the start of the
-first bar and this would otherwise cause the entire piano right-hand
-notes to be placed in a @code{CueVoice} context.
+down) and the instrument name is positioned below the staff.
@lilypond[quote,verbatim]
clarinet = \relative c' {
pianoRH = \relative c'' {
\transposition c'
% position name of cue-ing instrument below the staff
- \new CueVoice {
- \override InstrumentSwitch.self-alignment-X = #RIGHT
- \override InstrumentSwitch.direction = #DOWN
- \set instrumentCueName = "Clar."
- }
+ <>_\markup { \right-align { \tiny "Clar." } }
\cueDuring "clarinet" #DOWN { c4. g8 }
g4 bes4
}
@rlsr{Vocal music}.
Internals Reference:
-@rinternals{InstrumentSwitch},
@rinternals{CueVoice}.
@knownissues