]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/notation/vocal.itely
Doc: NR 2.1 Vocal: remove obsolete TODO
[lilypond.git] / Documentation / notation / vocal.itely
1 @c -*- coding: utf-8; mode: texinfo; -*-
2 @ignore
3     Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
4
5     When revising a translation, copy the HEAD committish of the
6     version that you are working on.  For details, see the Contributors'
7     Guide, node Updating translation committishes..
8 @end ignore
9
10 @c \version "2.12.0"
11
12 @node Vocal music
13 @section Vocal music
14
15 @c TODO: inspirational headword
16
17 This section explains how to typeset vocal music, and make sure
18 that the lyrics will be aligned with the notes of their melody.
19
20 @menu
21 * Common notation for vocal music::
22 * Techniques specific to lyrics::
23 * Stanzas::
24 * Songs::
25 * Choral::
26 * Opera and stage musicals::
27 * Chants psalms and hymns::
28 * Ancient vocal music::
29
30 @end menu
31
32
33 @node Common notation for vocal music
34 @subsection Common notation for vocal music
35
36 This section discusses issues common to most types of vocal music.
37
38 @menu
39 * References for vocal music::
40 * Entering lyrics::
41 * Aligning lyrics to a melody::
42 * Automatic syllable durations::
43 * Manual syllable durations::
44 * Multiple syllables to one note::
45 * Multiple notes to one syllable::
46 * Skipping notes::
47 * Extenders and hyphens::
48 @end menu
49
50
51 @node References for vocal music
52 @unnumberedsubsubsec References for vocal music
53
54 This section indicates where to find details of notation issues
55 that may arise in any type of vocal music.
56
57 @itemize
58
59 @item
60 Most styles of vocal music use written text as lyrics.  An introduction
61 to this notation is to be found in @rlearning{Setting simple songs}.
62
63 @item
64 Vocal music is likely to require the use of @code{markup} mode, either
65 for lyrics of for other text elements (character's names, etc.).
66 This syntax is described in @ref{Text markup introduction}.
67
68 @item
69 @notation{Ambitus} may be added at the beginning of vocal staves, as explained
70 in @ref{Ambitus}.
71
72 @end itemize
73
74 @seealso
75 Music Glossary:
76 @rglos{ambitus}.
77
78 @node Entering lyrics
79 @unnumberedsubsubsec Entering lyrics
80
81 @cindex lyrics, entering
82 @cindex entering lyrics
83 @cindex punctuation in lyrics
84 @cindex lyrics punctuation
85 @cindex spaces in lyrics
86 @cindex quotes in lyrics
87 @funindex \lyricmode
88
89 @c TODO should we explain hyphens here
90
91 Lyrics are entered in a special input mode, which can be introduced
92 by the keyword @code{\lyricmode}, or by using @code{\addlyrics} or
93 @code{\lyricsto}.  In this mode the input @code{d} is not parsed as
94 the pitch @notation{D}, but rather as a one-letter syllable of text.
95 In other words, syllables are entered like notes but with pitches
96 replaced by text.
97
98 For example:
99
100 @example
101 \lyricmode @{ Three4 blind mice,2 three4 blind mice2 @}
102 @end example
103
104 There are two main methods for specifying the horizontal placement
105 of the syllables, either by specifying the duration of each syllable
106 explicitly, as in the example above, or by leaving the lyrics to be
107 aligned automatically to a melody or other voice of music, using
108 @code{\addlyrics} or @code{\lyricsto}.  The former method is
109 described below in @ref{Manual syllable durations}.  The latter
110 method is described in @ref{Automatic syllable durations}.
111
112 A word or syllable of lyrics begins with an alphabetic character
113 (plus some other characters, see below) and is terminated by any
114 white space or a digit.  Later characters in the syllable can be any
115 character that is not a digit or white space.
116
117 Because any character that is not a digit or white space is regarded
118 as part of the syllable, a word is valid even if it ends with
119 @code{@}}, which often leads to the following mistake:
120
121 @example
122 \lyricmode @{ lah lah lah@}
123 @end example
124
125 In this example, the @code{@}} is included in the final syllable, so the
126 opening brace is not balanced and the input file will probably not
127 compile.  Instead, braces should always be surrounded with white space:
128
129 @example
130 \lyricmode @{ lah lah lah @}
131 @end example
132
133 @cindex overrides in lyric mode
134 @funindex \override in \lyricmode
135
136 Similarly, in lyric mode, a period will be included in the
137 alphabetic sequence that it follows.  As a consequence, spaces
138 must be inserted around the period in @code{\override} commands.
139 Do @emph{not} write
140
141 @example
142 \override Score.LyricText #'font-shape = #'italic
143 @end example
144
145 @noindent
146 but instead use
147
148 @example
149 \override Score . LyricText #'font-shape = #'italic
150 @end example
151
152 Punctuation, lyrics with accented characters, characters from
153 non-English languages, or special characters (such as the heart
154 symbol or slanted quotes), may simply be inserted directly
155 into the input file, providing it is saved with UTF-8 encoding.
156 For more information, see @ref{Text encoding}.
157
158 @lilypond[quote,verbatim]
159 \relative c' { e4 f e d e f e2 }
160 \addlyrics { He said: “Let my peo -- ple go.” }
161 @end lilypond
162
163 Normal quotes may be used in lyrics, but they have to be preceded
164 with a backslash character and the whole syllable has to be
165 enclosed between additional quotes.  For example,
166
167 @lilypond[quote,verbatim]
168 \relative c' { \time 3/4 e4 e4. e8 d4 e d c2. }
169 \addlyrics { "\"I" am so lone -- "ly,\"" said she }
170 @end lilypond
171
172 The full definition of a word start in lyrics mode is somewhat more
173 complex.  A word in lyrics mode is one that begins with an
174 alphabetic character, @code{_}, @code{?}, @code{!}, @code{:},
175 @code{'}, the control characters @code{^A} through @code{^F},
176 @code{^Q} through @code{^W}, @code{^Y}, @code{^^}, any 8-bit
177 character with an ASCII code over 127, or a two-character
178 combination of a backslash followed by one of @code{`}, @code{'},
179 @code{"}, or @code{^}.
180
181 @c " to balance double quotes for not-so-bright context-sensitive editors
182
183 @seealso
184 Learning Manual:
185 @rlearning{Songs}.
186
187 Notation Reference:
188 @ref{Automatic syllable durations},
189 @ref{Fonts},
190 @ref{Input modes},
191 @ref{Manual syllable durations}.
192
193 Internals Reference:
194 @rinternals{LyricText}.
195
196
197 @node Aligning lyrics to a melody
198 @unnumberedsubsubsec Aligning lyrics to a melody
199
200 @cindex lyrics, aligning to a melody
201 @cindex @code{associatedVoice}
202 @funindex \lyricmode
203 @funindex \addlyrics
204 @funindex \lyricsto
205
206 Lyrics are printed by interpreting them in the context called
207 @code{Lyrics}, see @ref{Contexts explained}.
208
209 @example
210 \new Lyrics \lyricmode @{ @dots{} @}
211 @end example
212
213 Lyrics can be aligned with melodies in two main ways:
214
215 @itemize
216
217 @item
218 Lyrics can be aligned automatically, with the durations of the
219 syllables being taken from another voice of music or (in special
220 circumstances) an associated melody, using @code{\addlyrics},
221 @code{\lyricsto}, or by setting the @code{associatedVoice} property.
222 For more details, see @ref{Automatic syllable durations}.
223
224 @lilypond[quote,ragged-right,verbatim]
225 <<
226   \new Staff <<
227     \time 2/4
228     \new Voice = "one" \relative c'' {
229       \voiceOne
230       c4 b8. a16 g4. r8 a4 ( b ) c2
231     }
232     \new Voice = "two" \relative c' {
233       \voiceTwo
234        s2 s4. f8 e4 d c2
235     }
236   >>
237
238 % takes durations and alignment from notes in "one"
239   \new Lyrics \lyricsto "one" {
240     Life is __ _ love, live __ life.
241   }
242
243 % takes durations and alignment from notes in "one" initially
244 % then switches to "two"
245   \new Lyrics \lyricsto "one" {
246     No more let
247     \set associatedVoice = "two"  % must be set one syllable early
248     sins and sor -- rows grow.
249   }
250 >>
251 @end lilypond
252
253 The first stanza shows the normal way of entering lyrics.
254
255 The second stanza shows how the voice from which the lyric
256 durations are taken can be changed.  This is useful if the words to
257 different stanzas fit the notes in different ways and all the
258 durations are available in Voice contexts.  For more details, see
259 @ref{Stanzas}.
260
261 @item
262 Lyrics can be aligned independently of the duration of any notes
263 if the durations of the syllables are specified explicitly,
264 and entered with @code{\lyricmode}.
265
266 @lilypond[quote,ragged-right,verbatim]
267 <<
268   \new Voice = "one" \relative c'' {
269     \time 2/4
270     c4 b8. a16 g4. f8 e4 d c2
271   }
272
273 % uses default durations of 2;
274   \new Lyrics \lyricmode {
275     Joy to the earth!
276   }
277
278 % explicit durations, set to a different rhythm
279   \new Lyrics \lyricmode {
280     Life4 is love,2. live4 life.2
281   }
282 >>
283 @end lilypond
284
285 The first stanza is not aligned with the notes because the durations
286 were not specified, and the default value of 2 is used for each
287 word.
288
289 The second stanza shows how the words can be aligned quite
290 independently from the notes.  This is useful if the words to
291 different stanzas fit the notes in different ways and the required
292 durations are not available in a music context.  For more details
293 see @ref{Manual syllable durations}.  This technical is also useful
294 when setting dialogue over music; for examples showing this, see
295 @ref{Dialogue over music}.
296
297 When entered in this way the words are left-aligned to the notes
298 by default, but may be center-aligned to the notes of a melody by
299 specifying an associated voice, if one exists.  For details, see
300 @ref{Manual syllable durations}.
301
302 @end itemize
303
304 @seealso
305 Learning Manual:
306 @rlearning{Aligning lyrics to a melody}.
307
308 Internals Reference:
309 @rinternals{Lyrics}.
310
311 @node Automatic syllable durations
312 @unnumberedsubsubsec Automatic syllable durations
313
314 @cindex syllable durations, automatic
315 @cindex lyrics and melodies
316 @cindex associatedVoice
317 @funindex \addlyrics
318 @funindex \lyricsto
319
320 Lyrics can be automatically aligned to the notes of a melody in
321 three ways:
322
323 @itemize
324
325 @item
326 by specifying the named Voice context containing the melody with
327 @code{\lyricsto},
328
329 @item
330 by introducing the lyrics with @code{\addlyrics} and placing them
331 immediately after the Voice context containing the melody,
332
333 @item
334 by setting the @code{associatedVoice} property, the alignment of
335 the lyrics may be switched to a different named Voice context at
336 any musical moment.
337
338 @end itemize
339
340 In all three methods hyphens can be drawn between the syllables of
341 a word and extender lines can be drawn beyond the end of a word.  For
342 details, see @ref{Extenders and hyphens}.
343
344 The @code{Voice} context containing the melody to which the lyrics
345 are being aligned must not have @qq{died}, or the lyrics after that
346 point will be lost.  This can happen if there are periods when that
347 voice has nothing to do.  For methods of keeping contexts alive, see
348 @ref{Keeping contexts alive}.
349
350 @subheading Using @code{\lyricsto}
351
352 @cindex \lyricsto
353 @funindex \lyricsto
354
355 Lyrics can be aligned under a melody automatically by specifying
356 the named Voice context containing the melody with
357 @code{\lyricsto}:
358
359 @lilypond[quote,verbatim,relative=2]
360 <<
361   \new Voice = "melody" {
362     a4 a a a
363   }
364   \new Lyrics \lyricsto "melody" {
365     These are the words
366   }
367 >>
368 @end lilypond
369
370 @noindent
371 This aligns the lyrics to the notes of the named @code{Voice}
372 context, which must already exist.  Therefore normally the
373 @code{Voice} context is specified first, followed by the
374 @code{Lyrics} context.  The lyrics themselves follow the
375 @code{\lyricsto} command.  The @code{\lyricsto} command
376 invokes lyric mode automatically, so the @code{\lyricmode} keyword
377 may be omitted.  By default, the lyrics are placed underneath the
378 notes.  For other placements, see @ref{Placing lyrics vertically}.
379
380 @subheading Using @code{\addlyrics}
381
382 @cindex \addlyrics
383 @funindex \addlyrics
384
385 The @code{\addlyrics} command is just a convenient shortcut that
386 can sometimes be used instead of having to set up the lyrics
387 through a more complicated LilyPond structure.
388
389 @example
390 @{ MUSIC @}
391 \addlyrics @{ LYRICS @}
392 @end example
393
394 @noindent
395 is the same as
396
397 @example
398 \new Voice = "blah" @{ MUSIC @}
399 \new Lyrics \lyricsto "blah" @{ LYRICS @}
400 @end example
401
402 Here is an example,
403
404 @lilypond[verbatim,quote]
405 {
406   \time 3/4
407   \relative c' { c2 e4 g2. }
408   \addlyrics { play the game }
409 }
410 @end lilypond
411
412 More stanzas can be added by adding more
413 @code{\addlyrics} sections:
414
415
416 @lilypond[ragged-right,verbatim,fragment,quote]
417 \time 3/4
418 \relative c' { c2 e4 g2. }
419 \addlyrics { play the game }
420 \addlyrics { speel het spel }
421 \addlyrics { joue le jeu }
422 @end lilypond
423
424 The command @code{\addlyrics} cannot handle polyphonic settings.
425 For these cases one should use @code{\lyricsto}.
426
427 @subheading Using associatedVoice
428
429 The melody to which the lyrics are being aligned can be changed by
430 setting the @code{associatedVoice} property,
431
432 @example
433 \set associatedVoice = #"lala"
434 @end example
435
436 @noindent
437
438 The value of the property (here: @code{"lala"}) should be the name
439 of a @code{Voice} context.  For technical reasons, the @code{\set}
440 command must be placed one syllable before the one to which the
441 change in voice is to apply.
442
443 Here is an example demonstrating its use:
444
445 @lilypond[quote,ragged-right,verbatim]
446 <<
447   \new Staff <<
448     \time 2/4
449     \new Voice = "one" \relative c'' {
450       \voiceOne
451       c4 b8. a16 g4. r8 a4 ( b ) c2
452     }
453     \new Voice = "two" \relative c' {
454       \voiceTwo
455        s2 s4. f8 e8 d4. c2
456     }
457   >>
458 % takes durations and alignment from notes in "one" initially
459 % then switches to "two"
460   \new Lyrics \lyricsto "one" {
461     No more let
462     \set associatedVoice = "two"  % must be set one syllable early
463     sins and sor -- rows grow.
464   }
465 >>
466 @end lilypond
467
468 @seealso
469 Notation Reference:
470 @ref{Extenders and hyphens}.
471
472 @node Manual syllable durations
473 @unnumberedsubsubsec Manual syllable durations
474
475 In some complex vocal music, it may be desirable to place lyrics
476 completely independently of notes.  In this case do not use
477 @code{\lyricsto} or @code{\addlyrics} and do not set
478 @code{associatedVoice}.  Syllables are entered like notes --
479 but with pitches replaced by text -- and the duration of each
480 syllable is entered explicitly after the syllable.
481
482 By default, syllables will be left-aligned to the corresponding
483 musical moment.  Hyphenated lines may be drawn between syllables
484 as usual, but extender lines cannot be drawn when there is no
485 associated voice.
486
487 Here are two examples:
488
489 @lilypond[relative=1,verbatim,quote]
490 <<
491   \new Voice = "melody" {
492     \time 3/4
493     c2 e4 g2 f
494   }
495   \new Lyrics \lyricmode {
496     play1 the4 game4
497   }
498 >>
499 @end lilypond
500
501
502 @lilypond[quote,verbatim,ragged-right]
503 <<
504   \new Staff {
505     \relative c'' {
506       c2 c2
507       d1
508     }
509   }
510   \new Lyrics {
511     \lyricmode {
512       I2 like4. my8 cat!1
513     }
514   }
515   \new Staff {
516     \relative c' {
517       c8 c c c c c c c
518       c8 c c c c c c c
519     }
520   }
521 >>
522 @end lilypond
523
524 This technique is useful when writing dialogue over music, see
525 @ref{Dialogue over music}.
526
527 To center-align syllables on the notes at the corresponding musical
528 moments, set @code{associatedVoice} to the name of the Voice context
529 containing those notes.  When @code{associatedVoice} is set, both
530 double hyphens and double underscores can be used to draw
531 hyphenated lines and extenders under melismata correctly.
532
533 @lilypond[relative=1,verbatim,quote]
534 <<
535   \new Voice = "melody" {
536     \time 3/4
537     c2 e4 g f g
538   }
539   \new Lyrics \lyricmode {
540     \set associatedVoice = #"melody"
541     play2 the4 game2. __
542   }
543 >>
544 @end lilypond
545
546 @c TODO see also feature request 707 - show how to do this with manual durations
547
548 @seealso
549 Notation Reference:
550 @ref{Dialogue over music},
551 @ref{Keeping contexts alive}.
552
553 Internals Reference:
554 @rinternals{Lyrics},
555 @rinternals{Voice}.
556
557
558 @node Multiple syllables to one note
559 @unnumberedsubsubsec Multiple syllables to one note
560
561 @funindex _
562 @cindex spaces, in lyrics
563 @cindex quotes, in lyrics
564 @cindex ties, in lyrics
565
566 In order to assign more than one syllable to a single note with
567 spaces between the syllables, you can surround the phrase with
568 quotes or use a @code{_} character.  Alternatively, you can use
569 code the tilde symbol (@code{~}) to get a lyric tie.  The lyric
570 tie is implemented with the Unicode character U+203F, so be
571 sure to have a font (like DejaVuLGC) installed that includes this
572 glyph.
573
574 @lilypond[quote,ragged-right,fragment,verbatim]
575 \time 3/4
576 \relative c' { c2 e4 g2 e4 }
577 \addlyrics { gran- de_a- mi- go }
578 \addlyrics { pu- "ro y ho-" nes- to }
579 \addlyrics { pu- ro~y~ho- nes- to }
580 @end lilypond
581
582
583 @seealso
584 Internals Reference:
585 @rinternals{LyricCombineMusic}.
586
587
588 @node Multiple notes to one syllable
589 @unnumberedsubsubsec Multiple notes to one syllable
590
591 @cindex melisma
592 @cindex melismata
593 @cindex phrasing, in lyrics
594 @funindex \melisma
595 @funindex \melismaEnd
596
597 Sometimes, particularly in Medieval music, several notes are to be
598 sung on one syllable; such vocalises are called melismata, or
599 @rglos{melisma}s.  The syllable to a melisma is usually
600 left-aligned with the first note of the melisma.
601
602 When a melisma occurs on a syllable other that the last one in a
603 word, that syllable is usually joined to the following one with a
604 hyphenated line.  This is indicated by placing a double hyphen,
605 @code{--}, immediately after the syllable.
606
607 Alternatively, when a melisma occurs on the last or only syllable in
608 a word an extender line is usually drawn from the end of the syllable
609 to the last note of the melisma.  This is indicated by placing a
610 double underscore, @code{__}, immediately after the word.
611
612 There are five ways in which melismata can be indicated:
613
614 @itemize
615
616 @item
617 Melismata are created automatically over notes which are tied
618 together:
619
620 @lilypond[quote,relative=2,verbatim]
621 <<
622   \new Voice = "melody" {
623     \time 3/4
624     f4 g2 ~ |
625     g4 e2 ~ |
626     e8
627   }
628   \new Lyrics \lyricsto "melody" {
629     Ki -- ri -- e __
630   }
631 >>
632 @end lilypond
633
634 @item
635 Melismata can be created automatically from the music by placing
636 slurs over the notes of each melisma.  This is the usual way of
637 entering lyrics:
638
639 @lilypond[quote,relative=2,verbatim]
640 <<
641   \new Voice = "melody" {
642     \time 3/4
643     f4 g8 ( f e f )
644     e8 ( d e2 )
645   }
646   \new Lyrics \lyricsto "melody" {
647     Ki -- ri -- e __
648   }
649 >>
650 @end lilypond
651
652 @item
653 Notes are considered a melisma if they are manually beamed,
654 providing automatic beaming is switched off.  See
655 @ref{Setting automatic beam behavior}.
656
657 @lilypond[quote,relative=2,verbatim]
658 <<
659   \new Voice = "melody" {
660     \time 3/4
661     \autoBeamOff
662     f4 g8[ f e f]
663     e2.
664   }
665   \new Lyrics \lyricsto "melody" {
666     Ki -- ri -- e
667   }
668 >>
669 @end lilypond
670
671 Clearly this is not suited to melisma over notes which are longer
672 than eighth notes.
673
674 @item
675 An unslurred group of notes will be treated as a melisma if they
676 are bracketed between @code{\melisma} and @code{\melismaEnd}.
677
678 @lilypond[quote,relative=2,verbatim]
679 <<
680   \new Voice = "melody" {
681     \time 3/4
682     f4 g8
683     \melisma
684     f e f
685     \melismaEnd
686     e2.
687   }
688   \new Lyrics \lyricsto "melody" {
689     Ki -- ri -- e
690   }
691 >>
692 @end lilypond
693
694 Note that this method cannot be used to indicate two melismata if
695 the first one is immediately followed by another.
696
697 @item
698 A melisma can be defined entirely in the lyrics by entering a
699 single underscore character, @code{_}, for every extra note that has
700 to be added to the melisma.
701
702 @lilypond[verbatim, quote, relative=2]
703 <<
704   \new Voice = "melody" {
705     \time 3/4
706     f4 g8 f e f
707     e8 d e2
708   }
709   \new Lyrics \lyricsto "melody" {
710     Ki -- ri -- _ _ _ e __ _ _
711   }
712 >>
713 @end lilypond
714
715 @end itemize
716
717 It is possible to have ties, slurs and manual beams in the melody
718 without their indicating melismata.  To do this, set
719 @code{melismaBusyProperties} and indicate the melismata with single
720 underscores in the lyrics, one underscore for each extra note:
721
722 @lilypond[relative=1,verbatim,quote]
723 <<
724   \new Voice = "melody" {
725     \time 3/4
726     \set melismaBusyProperties = #'()
727     c4 d ( e )
728     g8 [ f ] f4( e)
729     d e ~ e
730   }
731   \new Lyrics \lyricsto "melody" {
732     Ky -- _ _ _ _ ri -- _ _ e __ _
733   }
734 >>
735 @end lilypond
736
737 Other settings for @code{melismaBusyProperties} can be used to
738 include or exclude ties, slurs, and beams from the automatic
739 detection of melismata; see @code{melismaBusyProperties} in
740 @rinternals{Tunable context properties}.
741
742 @predefined
743
744 @code{\autoBeamOff},
745 @code{\autoBeamOn},
746 @code{\melisma},
747 @code{\melismaEnd}.
748
749 @seealso
750 Musical Glossary:
751 @rglos{melisma}.
752
753 Learning Manual:
754 @rlearning{Aligning lyrics to a melody}.
755
756 Notation Reference:
757 @ref{Aligning lyrics to a melody},
758 @ref{Automatic syllable durations},
759 @ref{Setting automatic beam behavior}.
760
761 Internals Reference:
762 @rinternals{Tunable context properties}.
763
764 @knownissues
765
766 Extender lines under melismata are not created automatically; they
767 must be inserted manually with a double underscore.
768
769 @node Skipping notes
770 @unnumberedsubsubsec Skipping notes
771
772 Making a lyric line run slower than the melody can be achieved by
773 inserting @code{\skip}s into the lyrics.  For every @code{\skip},
774 the text will be delayed by another note.  The @code{\skip} command
775 must be followed by a valid duration, but this is ignored when
776 @code{\skip} is used in lyrics which derive their durations from the
777 notes in an associated melody through @code{\addlyrics} or
778 @code{\lyricsto}.
779
780 @lilypond[verbatim,ragged-right,quote]
781 \relative c' { c c g' }
782 \addlyrics {
783   twin -- \skip 4
784   kle
785 }
786 @end lilypond
787
788
789 @node Extenders and hyphens
790 @unnumberedsubsubsec Extenders and hyphens
791
792 @cindex melisma
793 @cindex extender
794
795 @c leave this as samp. -gp
796 In the last syllable of a word, melismata are sometimes indicated with
797 a long horizontal line starting in the melisma syllable, and ending in
798 the next one.  Such a line is called an extender line, and it is
799 entered as @samp{ __ } (note the spaces before and after the two
800 underscore characters).
801
802 @warning{Melismata are indicated in the score with extender lines,
803 which are entered as one double underscore; but short melismata can
804 also be entered by skipping individual notes, which are entered as
805 single underscore characters; these do not make an extender line to be
806 typeset by default.}
807
808 @cindex hyphens
809
810 @c leave this as samp. -gp
811 Centered hyphens are entered as @samp{ -- } between syllables of a same word
812 (note the spaces before and after the two hyphen characters).  The hyphen
813 will be centered between the syllables, and its length will be adjusted
814 depending on the space between the syllables.
815
816 In tightly engraved music, hyphens can be removed.  Whether this
817 happens can be controlled with the @code{minimum-distance} (minimum
818 distance between two syllables) and the @code{minimum-length}
819 (threshold below which hyphens are removed).
820
821
822 @seealso
823 Internals Reference:
824 @rinternals{LyricExtender},
825 @rinternals{LyricHyphen}.
826
827
828 @node Techniques specific to lyrics
829 @subsection Techniques specific to lyrics
830
831 @c TODO this whole section is to be reorganised
832
833 @menu
834 * Working with lyrics and variables::
835 * Placing lyrics vertically::
836 * Placing syllables horizontally::
837 * Lyrics and repeats::
838 * Divisi lyrics::
839 @end menu
840
841
842
843 @node Working with lyrics and variables
844 @unnumberedsubsubsec Working with lyrics and variables
845
846 @c TODO rewrite this section
847
848 @cindex lyrics, variables
849
850 To define variables containing lyrics, the function @code{\lyricmode}
851 must be used.  Durations do not need to be added if the variable is
852 to be invoked with @code{\addlyrics} or @code{\lyricsto}.
853
854 @lilypond[quote,verbatim]
855 verseOne = \lyricmode { Joy to the world, the Lord is come. }
856 \score {
857   <<
858     \new Voice = "one" \relative c'' {
859       \autoBeamOff
860       \time 2/4
861       c4 b8. a16 g4. f8 e4 d c2
862     }
863     \addlyrics { \verseOne }
864   >>
865 }
866 @end lilypond
867
868 For different or more complex orderings, the best way is to set up the
869 hierarchy of staves and lyrics first, e.g.,
870 @example
871 \new ChoirStaff <<
872   \new Voice = "soprano" @{ @emph{music} @}
873   \new Lyrics = "sopranoLyrics" @{ s1 @}
874   \new Lyrics = "tenorLyrics" @{ s1 @}
875   \new Voice = "tenor" @{ @emph{music} @}
876 >>
877 @end example
878
879 @noindent
880 and then combine the appropriate melodies and lyric lines:
881
882 @example
883 \context Lyrics = sopranoLyrics \lyricsto "soprano"
884 @emph{the lyrics}
885 @end example
886
887 @noindent
888 The final input would resemble
889
890 @example
891 <<
892   \new ChoirStaff <<
893     @emph{setup the music}
894   >>
895   \lyricsto "soprano" @emph{etc}
896   \lyricsto "alto" @emph{etc}
897   @emph{etc}
898 >>
899 @end example
900
901 @seealso
902 Internals Reference:
903 @rinternals{LyricCombineMusic},
904 @rinternals{Lyrics}.
905
906
907 @node Placing lyrics vertically
908 @unnumberedsubsubsec Placing lyrics vertically
909
910 @cindex placement of lyrics
911 @cindex lyrics, positioning
912
913 Depending on the type of music, lyrics may be positioned
914 above the staff, below the staff, or between staves.  Placing
915 lyrics below the associated staff is the easiest, and can be
916 achieved by simply defining the Lyrics context below the Staff
917 context:
918
919 @lilypond[quote,verbatim]
920 \score {
921   <<
922     \new Staff {
923       \new Voice = "melody" {
924         \relative c'' { c4 c c c }
925       }
926     }
927     \new Lyrics {
928       \lyricsto "melody" {
929         Here are the words
930       }
931     }
932   >>
933 }
934 @end lilypond
935
936 Lyrics may be positioned above the staff using one of
937 two methods.  The simplest is to use the same syntax as
938 above and explicitly specify the position of the lyrics:
939
940 @lilypond[quote,verbatim]
941 \score {
942   <<
943     \new Staff = "staff" {
944       \new Voice = "melody" {
945         \relative c'' { c4 c c c }
946       }
947     }
948     \new Lyrics \with { alignAboveContext = "staff" } {
949       \lyricsto "melody" {
950         Here are the words
951       }
952     }
953   >>
954 }
955 @end lilypond
956
957 Alternatively, a two-step process may be used.  First the Lyrics
958 context is declared (without any content) before the Staff and
959 Voice contexts, then the @code{\lyricsto} command comes after
960 the Voice declaration it references, as follows:
961
962 @lilypond[quote,verbatim]
963 \score {
964   <<
965     \new Lyrics = "lyrics"
966     \new Staff {
967       \new Voice = "melody" {
968         \relative c'' { c4 c c c }
969       }
970     }
971     \context Lyrics = "lyrics" {
972       \lyricsto "melody" {
973         Here are the words
974       }
975     }
976   >>
977 }
978 @end lilypond
979
980 When there are two voices on separate staves the lyrics may be
981 placed between the staves using either of these methods.  Here
982 is an example of the second method:
983
984 @lilypond[quote,verbatim]
985 \score {
986   \new ChoirStaff <<
987     \new Staff {
988       \new Voice = "sopranos" {
989         \relative c'' { c4 c c c }
990       }
991     }
992     \new Lyrics = "sopranos"
993     \new Lyrics = "contraltos"
994     \new Staff {
995       \new Voice = "contraltos" {
996         \relative c'' { a4 a a a }
997       }
998     }
999     \context Lyrics = "sopranos" {
1000       \lyricsto "sopranos" {
1001         Sop -- ra -- no words
1002       }
1003     }
1004     \context Lyrics = "contraltos" {
1005       \lyricsto "contraltos" {
1006         Con -- tral -- to words
1007       }
1008     }
1009   >>
1010 }
1011 @end lilypond
1012
1013 Other combinations of lyrics and staves may be generated by
1014 elaborating these examples, or by examining the
1015 @rlearning{Vocal ensembles} templates in the Learning Manual.
1016
1017 @seealso
1018 Learning Manual:
1019 @rlearning{Vocal ensembles}.
1020
1021 Notation Reference:
1022 @ref{Aligning contexts},
1023 @ref{Creating contexts}.
1024
1025 @node Placing syllables horizontally
1026 @unnumberedsubsubsec Placing syllables horizontally
1027
1028 @cindex Spacing lyrics
1029 @cindex Lyrics, increasing space between
1030
1031 To increase the spacing between lyrics, set the @code{minimum-distance}
1032 property of @code{LyricSpace}.
1033
1034 @lilypond[relative,verbatim,fragment,quote,ragged-right]
1035 {
1036   c c c c
1037   \override Lyrics.LyricSpace #'minimum-distance = #1.0
1038   c c c c
1039 }
1040 \addlyrics {
1041   longtext longtext longtext longtext
1042   longtext longtext longtext longtext
1043 }
1044 @end lilypond
1045
1046 @noindent
1047 To make this change for all lyrics in the score, set the property in the
1048 layout.
1049
1050 @lilypond[verbatim,quote,ragged-right]
1051 \score {
1052   \relative c' {
1053   c c c c
1054   c c c c
1055   }
1056   \addlyrics {
1057   longtext longtext longtext longtext
1058   longtext longtext longtext longtext
1059   }
1060   \layout {
1061     \context {
1062       \Lyrics
1063       \override LyricSpace #'minimum-distance = #1.0
1064     }
1065   }
1066 }
1067 @end lilypond
1068
1069 @c @snippets
1070 @c This snippet has been renamed to "lyrics-alignment.ly"
1071 @c update as soon as lsr/is updated -vv
1072 @c @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
1073 @c {lyrics-alignment.ly}
1074
1075 @c TODO: move to LSR -vv
1076 @snippets
1077
1078 Checking to make sure that text scripts and lyrics are within the margins is
1079 a relatively large computational task.  To speed up processing, LilyPond does
1080 not perform such calculations by default; to enable it, use
1081
1082 @example
1083 \override Score.PaperColumn #'keep-inside-line = ##t
1084 @end example
1085
1086 To make lyrics avoid bar lines as well, use
1087
1088 @example
1089 \layout @{
1090   \context @{
1091     \Lyrics
1092       \consists "Bar_engraver"
1093       \consists "Separating_line_group_engraver"
1094       \override BarLine #'transparent = ##t
1095   @}
1096 @}
1097 @end example
1098
1099 @c TODO Create and add lsr example of lyricMelismaAlignment
1100 @c It's used like this to center-align all lyric syllables,
1101 @c even when notes are tied. -td
1102
1103 @ignore
1104 \layout
1105 {
1106      \context { \Score lyricMelismaAlignment = #0 }
1107 }
1108 @end ignore
1109
1110
1111 @node Lyrics and repeats
1112 @unnumberedsubsubsec Lyrics and repeats
1113
1114 @cindex repeats and lyrics
1115 @cindex lyrics, repeating
1116
1117 @subheading Simple repeats
1118
1119 Repeats in @emph{music} are fully described elsewhere; see
1120 @ref{Repeats}.  This section explains how to add lyrics to repeated
1121 sections of music.
1122
1123 Lyrics to a section of music that is repeated should be surrounded
1124 by exactly the same repeat construct as the music, if the words are
1125 unchanged.
1126
1127 @lilypond[verbatim,quote]
1128 \score {
1129   <<
1130     \new Staff {
1131       \new Voice = "melody" {
1132         \relative c'' {
1133           a4 a a a
1134           \repeat volta 2 { b4 b b b }
1135         }
1136       }
1137     }
1138     \new Lyrics {
1139       \lyricsto "melody" {
1140         Not re -- peat -- ed.
1141         \repeat volta 2 { Re -- peat -- ed twice. }
1142       }
1143     }
1144   >>
1145 }
1146 @end lilypond
1147
1148 The words will then be correctly expanded if the repeats are
1149 unfolded.
1150
1151 @lilypond[verbatim,quote]
1152 \score {
1153   \unfoldRepeats {
1154     <<
1155       \new Staff {
1156         \new Voice = "melody" {
1157           \relative c'' {
1158             a4 a a a
1159             \repeat volta 2 { b4 b b b }
1160           }
1161         }
1162       }
1163       \new Lyrics {
1164         \lyricsto "melody" {
1165           Not re -- peat -- ed.
1166           \repeat volta 2 { Re -- peat -- ed twice. }
1167         }
1168       }
1169     >>
1170   }
1171 }
1172 @end lilypond
1173
1174 If the repeated section is to be unfolded and has different words,
1175 simply enter all the words:
1176
1177 @lilypond[verbatim,quote,ragged-right]
1178 \score {
1179   <<
1180     \new Staff {
1181       \new Voice = "melody" {
1182         \relative c'' {
1183           a4 a a a
1184           \repeat unfold 2 { b4 b b b }
1185         }
1186       }
1187     }
1188     \new Lyrics {
1189       \lyricsto "melody" {
1190         Not re -- peat -- ed.
1191         The first time words.
1192         Sec -- ond time words.
1193       }
1194     }
1195   >>
1196 }
1197 @end lilypond
1198
1199 @cindex lyric skip
1200 @funindex \skip
1201
1202 When the words to a repeated volta section are different, the words
1203 to each repeat must be entered in separate @code{Lyrics} contexts.
1204 Earlier unrepeated sections must be skipped in the second and
1205 subsequent repeats.  The easiest way to skip several notes is to
1206 use @code{\repeat unfold} around the @code{\skip} command.
1207
1208 Note: do not use an underscore, @code{_}, to skip notes in this
1209 particular case.  As this syntax indicates a melisma, it will cause
1210 the preceding syllable to be left-aligned.
1211
1212 @warning{The @code{@bs{}skip} command must be followed by a number,
1213 but this number is ignored in lyrics which derive their durations
1214 from the notes in an associated melody through @code{\addlyrics} or
1215 @code{\lyricsto}.  Each @code{@bs{}skip} skips a single note of any
1216 value, irrespective of the value of the following number.}
1217
1218 @lilypond[verbatim,quote]
1219 \score {
1220   <<
1221     \new Staff {
1222       \new Voice = "melody" {
1223         \relative c'' {
1224           a4 a a a
1225           \repeat volta 2 { b4 b b b }
1226         }
1227       }
1228     }
1229     \new Lyrics {
1230       \lyricsto "melody" {
1231         Not re -- peat -- ed.
1232         The first time words.
1233       }
1234     }
1235     \new Lyrics {
1236       \lyricsto "melody" {
1237         % skip 4 notes of any duration
1238         \repeat unfold 4 { \skip 1 }
1239         Sec -- ond time words.
1240       }
1241     }
1242   >>
1243 }
1244 @end lilypond
1245
1246 @cindex lyrics, repeating with a temporary voice
1247
1248 An alternative way, which avoids skips and having to count notes,
1249 is to use a temporary voice for the repeated section.  This may be
1250 preferable if the earlier sections are still subject to change.  A
1251 temporary voice can be inserted anywhere in the main music stream
1252 in parallel with it, as shown below, but it may be necessary to
1253 keep the main voice alive in complex scores when using this
1254 technique; see @ref{Keeping contexts alive}.
1255
1256 @lilypond[verbatim,quote,ragged-right]
1257 \score {
1258   <<
1259     \new Staff {
1260       \new Voice = "singleVoice" {
1261         \relative c'' { a4 a a a }
1262         \new Voice = "repeatVoice" {
1263           \relative c'' \repeat volta 3 { b4 b b b }
1264         }
1265         \relative c'' { c4 c c c }
1266       }
1267     }
1268     \new Lyrics <<
1269       \lyricsto "singleVoice" {
1270         Not re -- peat -- ed.
1271         The end sec -- tion.
1272       }
1273       \lyricsto "repeatVoice" {
1274         The first time words.
1275       }
1276     >>
1277     \new Lyrics {
1278       \lyricsto "repeatVoice" {
1279         Sec -- ond time words.
1280       }
1281     }
1282     \new Lyrics {
1283       \lyricsto "repeatVoice" {
1284         The third time words.
1285       }
1286     }
1287   >>
1288 }
1289 @end lilypond
1290
1291 @c TODO lowering a common line of lyrics
1292
1293 @subheading Repeats with alternative endings
1294
1295 @cindex lyrics, repeats with alternative endings
1296 @cindex repeating lyrics with alternative endings
1297 @cindex alternative endings and lyrics
1298
1299 If the words of the repeated section are the same, exactly the
1300 same structure can be used for both the lyrics and music.
1301
1302 @lilypond[quote,verbatim]
1303 \score {
1304   <<
1305     \new Staff {
1306       \time 2/4
1307       \new Voice = "melody" {
1308         \relative c'' {
1309           a4 a a a
1310           \repeat volta 2 { b4 b }
1311           \alternative { { b b } { b c } }
1312         }
1313       }
1314     }
1315     \new Lyrics {
1316       \lyricsto "melody" {
1317         Not re -- peat -- ed.
1318         \repeat volta 2 { Re -- peat -- }
1319         \alternative { { ed twice. } { ed twice. } }
1320       }
1321     }
1322   >>
1323 }
1324 @end lilypond
1325
1326 But when the repeated section has different words, a repeat
1327 construct cannot be used around the words and @code{\skip} commands
1328 have to be inserted manually as described in the previous section to
1329 skip over the notes in the alternative sections which do not apply.
1330
1331 @lilypond[verbatim,quote,ragged-right]
1332 \score {
1333   <<
1334     \new Staff {
1335       \time 2/4
1336       \new Voice = "melody" {
1337         \relative c'' {
1338           \repeat volta 2 { b4 b }
1339           \alternative { { b b } { b c } }
1340           c4 c
1341         }
1342       }
1343     }
1344     \new Lyrics {
1345       \lyricsto "melody" {
1346         The first time words.
1347         \repeat unfold 2 { \skip 1 }
1348         End here.
1349       }
1350     }
1351     \new Lyrics {
1352       \lyricsto "melody" {
1353         Sec -- ond
1354         \repeat unfold 2 { \skip 1 }
1355         time words.
1356       }
1357     }
1358   >>
1359 }
1360 @end lilypond
1361
1362 @cindex lyrics and tied notes
1363 @funindex \repeatTie
1364
1365 When a note is tied over into two or more alternative endings a
1366 tie is used to carry the note into the first alternative ending and
1367 a @code{\repeatTie} is used in the second and subsequent endings.
1368 This structure causes difficult alignment problems when lyrics are
1369 involved and increasing the length of the alternative sections so
1370 the tied notes are contained wholly within them may give a more
1371 acceptable result.
1372
1373 The tie creates a melisma into the first alternative, but not into
1374 the second and subsequent alternatives, so to align the lyrics
1375 correctly it is necessary to disable the automatic creation of
1376 melismata over the volta section and insert manual skips.
1377
1378 @lilypond[quote,verbatim]
1379 \score {
1380   <<
1381     \new Staff {
1382       \time 2/4
1383       \new Voice = "melody" {
1384         \relative c'' {
1385           \set melismaBusyProperties = #'()
1386           \repeat volta 2 { b4 b ~}
1387           \alternative { { b b } { b \repeatTie c } }
1388           \unset melismaBusyProperties
1389           c4 c
1390         }
1391       }
1392     }
1393     \new Lyrics {
1394       \lyricsto "melody" {
1395         \repeat volta 2 { Here's a __ }
1396         \alternative {
1397           { \skip 1 verse }
1398           { \skip 1 sec }
1399         }
1400         ond one.
1401       }
1402     }
1403   >>
1404 }
1405 @end lilypond
1406
1407 Note that if @code{\unfoldRepeats} is used around a section
1408 containing @code{\repeatTie}, the @code{\repeatTie} should be
1409 removed to avoid both types of tie being printed.
1410
1411 When the repeated section has different words a @code{\repeat}
1412 cannot be used around the lyrics and @code{\skip} commands need to
1413 be inserted manually, as before.
1414
1415 @lilypond[quote,verbatim]
1416 \score {
1417   <<
1418     \new Staff {
1419       \time 2/4
1420       \new Voice = "melody" {
1421         \relative c'' {
1422           \repeat volta 2 { b4 b ~}
1423           \alternative { { b b } { b \repeatTie c } }
1424           c4 c
1425         }
1426       }
1427     }
1428     \new Lyrics {
1429       \lyricsto "melody" {
1430         Here's a __ verse.
1431         \repeat unfold 2 { \skip 1 }
1432       }
1433     }
1434     \new Lyrics {
1435       \lyricsto "melody" {
1436         Here's one
1437         \repeat unfold 2 { \skip 1 }
1438         more to sing.
1439       }
1440     }
1441   >>
1442 }
1443 @end lilypond
1444
1445 If you wish to show extenders and hyphens into and out of
1446 alternative sections these must be inserted manually.
1447
1448 @lilypond[quote,verbatim]
1449 \score {
1450   <<
1451     \new Staff {
1452       \time 2/4
1453       \new Voice = "melody" {
1454         \relative c'' {
1455           \repeat volta 2 { b4 b ~}
1456           \alternative { { b b } { b \repeatTie c } }
1457           c4 c
1458         }
1459       }
1460     }
1461     \new Lyrics {
1462       \lyricsto "melody" {
1463         Here's a __ verse.
1464         \repeat unfold 2 { \skip 1 }
1465       }
1466     }
1467     \new Lyrics {
1468       \lyricsto "melody" {
1469         Here's "a_"
1470         \skip 1
1471         "_" sec -- ond one.
1472       }
1473     }
1474   >>
1475 }
1476 @end lilypond
1477
1478
1479
1480 @node Divisi lyrics
1481 @unnumberedsubsubsec Divisi lyrics
1482
1483 @cindex divided lyrics
1484 @cindex lyrics, divided
1485
1486 When just the words and rhythms of the two parts differ with the
1487 pitches remaining the same, temporarily turning off the automatic
1488 detection of melismata and indicating the melisma in the lyrics
1489 may be the appropriate method to use:
1490
1491 @lilypond[quote,verbatim]
1492 \score {
1493   <<
1494     \new Voice = "melody" {
1495       \relative c' {
1496         \set melismaBusyProperties = #'()
1497         \slurDown
1498         \slurDashed
1499         e4 e8 ( e ) c4 c |
1500         \unset melismaBusyProperties
1501         c
1502       }
1503     }
1504     \new Lyrics \lyricsto "melody" {
1505       They shall not o -- ver -- come
1506     }
1507     \new Lyrics \lyricsto "melody" {
1508       We will _
1509     }
1510   >>
1511 }
1512 @end lilypond
1513
1514 When both music and words differ it may be better to display
1515 the differing music and lyrics by naming voice contexts and
1516 attaching lyrics to those specific contexts:
1517
1518 @lilypond[verbatim,ragged-right,quote]
1519 \score {
1520   <<
1521     \new Voice = "melody" {
1522       \relative c' {
1523         <<
1524           {
1525             \voiceOne
1526             e4 e8 e
1527           }
1528           \new Voice = "splitpart" {
1529             \voiceTwo
1530             c4 c
1531           }
1532         >>
1533         \oneVoice
1534         c4 c |
1535         c
1536       }
1537     }
1538     \new Lyrics \lyricsto "melody" {
1539       They shall not o -- ver -- come
1540     }
1541     \new Lyrics \lyricsto "splitpart" {
1542       We will
1543     }
1544   >>
1545 }
1546 @end lilypond
1547
1548
1549 @node Stanzas
1550 @subsection Stanzas
1551
1552 @menu
1553 * Adding stanza numbers::
1554 * Adding dynamics marks to stanzas::
1555 * Adding singers' names to stanzas::
1556 * Stanzas with different rhythms::
1557 * Printing stanzas at the end::
1558 * Printing stanzas at the end in multiple columns::
1559 @end menu
1560
1561
1562 @node Adding stanza numbers
1563 @unnumberedsubsubsec Adding stanza numbers
1564
1565 @cindex stanza number
1566
1567 Stanza numbers can be added by setting @code{stanza}, e.g.,
1568
1569 @lilypond[quote,ragged-right,verbatim,relative=2,fragment]
1570 \new Voice {
1571   \time 3/4 g2 e4 a2 f4 g2.
1572 } \addlyrics {
1573   \set stanza = #"1. "
1574   Hi, my name is Bert.
1575 } \addlyrics {
1576   \set stanza = #"2. "
1577   Oh, ché -- ri, je t'aime
1578 }
1579 @end lilypond
1580
1581
1582 @noindent
1583 These numbers are put just before the start of the first syllable.
1584
1585 @c TODO Create and add snippet to show how two lines of a
1586 @c stanza can be grouped together, along these lines:
1587 @c (might need improving a bit) -td
1588
1589 @ignore
1590 leftbrace = \markup { \override #'(font-encoding . fetaBraces) \lookup
1591 #"brace105" }
1592
1593 stanzaOneOne = {
1594   \set stanza = \markup { "1. " \leftbrace }
1595   \lyricmode { Child, you're mine and I love you.
1596     Lend thine ear to what I say.
1597
1598   }
1599 }
1600
1601 stanzaOneThree =  {
1602 %  \set stanza = \markup { "   "}
1603   \lyricmode { Child, I have no great -- er joy
1604     Than to have you walk in truth.
1605
1606   }
1607 }
1608
1609 \new Voice {
1610   \repeat volta 2 { c'8 c' c' c' c' c' c'4
1611                     c'8 c' c' c' c' c' c'4   }
1612 }  \addlyrics { \stanzaOneOne }
1613    \addlyrics { \stanzaOneThree }
1614
1615 @end ignore
1616
1617 @node Adding dynamics marks to stanzas
1618 @unnumberedsubsubsec Adding dynamics marks to stanzas
1619
1620 Stanzas differing in loudness may be indicated by putting a
1621 dynamics mark before each stanza.  In LilyPond, everything coming in
1622 front of a stanza goes into the @code{StanzaNumber} object; dynamics marks
1623 are no different.  For technical reasons, you have to set the stanza
1624 outside @code{\lyricmode}:
1625
1626 @lilypond[quote,ragged-right,verbatim]
1627 text = {
1628   \set stanza = \markup { \dynamic "ff" "1. " }
1629   \lyricmode {
1630     Big bang
1631   }
1632 }
1633
1634 <<
1635   \new Voice = "tune" {
1636     \time 3/4
1637     g'4 c'2
1638   }
1639 \new Lyrics \lyricsto "tune" \text
1640 >>
1641 @end lilypond
1642
1643 @node Adding singers' names to stanzas
1644 @unnumberedsubsubsec Adding singers' names to stanzas
1645
1646 @cindex singer name
1647 @cindex name of singer
1648
1649 Names of singers can also be added.  They are printed at the start of
1650 the line, just like instrument names.  They are created by setting
1651 @code{vocalName}.  A short version may be entered as @code{shortVocalName}.
1652
1653 @lilypond[fragment,ragged-right,quote,verbatim,relative=2]
1654 \new Voice {
1655   \time 3/4 g2 e4 a2 f4 g2.
1656 } \addlyrics {
1657   \set vocalName = #"Bert "
1658   Hi, my name is Bert.
1659 } \addlyrics {
1660   \set vocalName = #"Ernie "
1661   Oh, ché -- ri, je t'aime
1662 }
1663 @end lilypond
1664
1665 @node Stanzas with different rhythms
1666 @unnumberedsubsubsec Stanzas with different rhythms
1667
1668 Often, different stanzas of one song are put to one melody in slightly
1669 differing ways.  Such variations can still be captured with
1670 @code{\lyricsto}.
1671
1672 @subsubheading Ignoring melismata
1673
1674 One possibility is that the text has a melisma in one stanza, but
1675 multiple syllables in another one.  One solution is to make the faster
1676 voice ignore the melisma.  This is done by setting
1677 @code{ignoreMelismata} in the Lyrics context.
1678
1679 @lilypond[verbatim,ragged-right,quote]
1680 <<
1681   \relative c' \new Voice = "lahlah" {
1682     \set Staff.autoBeaming = ##f
1683     c4
1684     \slurDotted
1685     f8.[( g16])
1686     a4
1687   }
1688   \new Lyrics \lyricsto "lahlah" {
1689     more slow -- ly
1690   }
1691   \new Lyrics \lyricsto "lahlah" {
1692     go
1693     \set ignoreMelismata = ##t
1694     fas -- ter
1695     \unset ignoreMelismata
1696     still
1697   }
1698 >>
1699 @end lilypond
1700
1701 @knownissues
1702 Unlike most @code{\set} commands, @code{\set ignoreMelismata} does
1703 not work if prefixed with @code{\once}.  It is necessary to use
1704 @code{\set} and @code{\unset} to bracket the lyrics where melismata
1705 are to be ignored.
1706
1707 @subsubheading Adding syllables to grace notes
1708
1709 By default, grace notes (e.g. via @code{\grace}) do not get assigned
1710 syllables when using @code{\lyricsto}, but this behavior can be
1711 changed:
1712
1713 @lilypond[verbatim,ragged-right,quote]
1714 \relative c' {
1715   f4 \appoggiatura a32 b4
1716   \grace { f16[ a16] } b2
1717   \afterGrace b2 { f16[ a16] }
1718   \appoggiatura a32 b4
1719   \acciaccatura a8 b4
1720 }
1721 \addlyrics {
1722   normal
1723   \set includeGraceNotes = ##t
1724   case,
1725   gra -- ce case,
1726   after -- grace case,
1727   \set ignoreMelismata = ##t
1728   app. case,
1729   acc. case.
1730 }
1731 @end lilypond
1732
1733 @knownissues
1734 Like for @code{associatedVoice}, @code{includeGraceNotes} needs to be
1735 set at latest one syllable before the one which is to be put under a
1736 grace note.  For the case of a grace note at the very beginning of a
1737 piece of music, consider using a @code{\with} or @code{\context}
1738 block:
1739
1740 @lilypond[verbatim,ragged-right,quote]
1741 <<
1742   \new Voice = melody \relative c' {
1743     \grace { c16[( d e f] }
1744     g1) f
1745   }
1746   \new Lyrics \with { includeGraceNotes = ##t }
1747   \lyricsto melody {
1748     Ah __ fa
1749   }
1750 >>
1751 @end lilypond
1752
1753 @subsubheading Switching to an alternative melody
1754
1755 More complex variations in text underlay are possible.  It is possible
1756 to switch the melody for a line of lyrics during the text.  This is
1757 done by setting the @code{associatedVoice} property.  In the example
1758
1759 @lilypond[ragged-right,quote]
1760 <<
1761   \relative c' \new Voice = "lahlah" {
1762     \set Staff.autoBeaming = ##f
1763     c4
1764     <<
1765       \new Voice = "alternative" {
1766         \voiceOne
1767         \times 2/3 {
1768           % show associations clearly.
1769           \override NoteColumn #'force-hshift = #-3
1770           f8 f g
1771         }
1772       }
1773       {
1774         \voiceTwo
1775         f8.[ g16]
1776         \oneVoice
1777       } >>
1778     a8( b) c
1779   }
1780   \new Lyrics \lyricsto "lahlah" {
1781     Ju -- ras -- sic Park
1782   }
1783   \new Lyrics \lyricsto "lahlah" {
1784     % Tricky: need to set associatedVoice
1785     % one syllable too soon!
1786     \set associatedVoice = alternative % applies to "ran"
1787     Ty --
1788     ran --
1789     no --
1790     \set associatedVoice = lahlah % applies to "rus"
1791     sau -- rus Rex
1792   } >>
1793 @end lilypond
1794
1795 @noindent
1796 the text for the first stanza is set to a melody called @q{lahlah},
1797
1798 @example
1799 \new Lyrics \lyricsto "lahlah" @{
1800   Ju -- ras -- sic Park
1801 @}
1802 @end example
1803
1804
1805 The second stanza initially is set to the @code{lahlah} context, but
1806 for the syllable @q{ran}, it switches to a different melody.
1807 This is achieved with
1808 @example
1809 \set associatedVoice = alternative
1810 @end example
1811
1812 @noindent
1813 Here, @code{alternative} is the name of the @code{Voice} context
1814 containing the triplet.
1815
1816 @c TODO: make this easier to understand -vv
1817 This command must be one syllable too early, before @q{Ty} in this
1818 case.  In other words, changing the associatedVoice happens one step
1819 later than expected.  This is for technical reasons, and it is not a
1820 bug.
1821
1822 @example
1823 \new Lyrics \lyricsto "lahlah" @{
1824   \set associatedVoice = alternative % applies to "ran"
1825   Ty --
1826   ran --
1827   no --
1828   \set associatedVoice = lahlah % applies to "rus"
1829   sau -- rus Rex
1830 @}
1831 @end example
1832
1833 @noindent
1834 The underlay is switched back to the starting situation by assigning
1835 @code{lahlah} to @code{associatedVoice}.
1836
1837
1838 @node Printing stanzas at the end
1839 @unnumberedsubsubsec Printing stanzas at the end
1840
1841 Sometimes it is appropriate to have one stanza set
1842 to the music, and the rest added in verse form at
1843 the end of the piece.  This can be accomplished by adding
1844 the extra verses into a @code{\markup} section outside
1845 of the main score block.  Notice that there are two
1846 different ways to force linebreaks when using
1847 @code{\markup}.
1848
1849 @lilypond[ragged-right,verbatim,quote]
1850 melody = \relative c' {
1851 e d c d | e e e e |
1852 d d e d | c1 |
1853 }
1854
1855 text = \lyricmode {
1856 \set stanza = #"1." Ma- ry had a lit- tle lamb,
1857 its fleece was white as snow.
1858 }
1859
1860 \score{ <<
1861   \new Voice = "one" { \melody }
1862   \new Lyrics \lyricsto "one" \text
1863 >>
1864   \layout { }
1865 }
1866 \markup { \column{
1867   \line{ Verse 2. }
1868   \line{ All the children laughed and played }
1869   \line{ To see a lamb at school. }
1870   }
1871 }
1872 \markup{
1873   \wordwrap-string #"
1874   Verse 3.
1875
1876   Mary took it home again,
1877
1878   It was against the rule."
1879 }
1880 @end lilypond
1881
1882
1883 @node Printing stanzas at the end in multiple columns
1884 @unnumberedsubsubsec Printing stanzas at the end in multiple columns
1885
1886 When a piece of music has many verses, they are often printed in
1887 multiple columns across the page.  An outdented verse number often
1888 introduces each verse.  The following example shows how to produce such
1889 output in LilyPond.
1890
1891 @lilypond[ragged-right,quote,verbatim]
1892 melody = \relative c' {
1893   c c c c | d d d d
1894 }
1895
1896 text = \lyricmode {
1897   \set stanza = #"1." This is verse one.
1898   It has two lines.
1899 }
1900
1901 \score{ <<
1902     \new Voice = "one" { \melody }
1903     \new Lyrics \lyricsto "one" \text
1904    >>
1905   \layout { }
1906 }
1907
1908 \markup {
1909   \fill-line {
1910     \hspace #0.1 % moves the column off the left margin;
1911         % can be removed if space on the page is tight
1912      \column {
1913       \line { \bold "2."
1914         \column {
1915           "This is verse two."
1916           "It has two lines."
1917         }
1918       }
1919       \hspace #0.1 % adds vertical spacing between verses
1920       \line { \bold "3."
1921         \column {
1922           "This is verse three."
1923           "It has two lines."
1924         }
1925       }
1926     }
1927     \hspace #0.1  % adds horizontal spacing between columns;
1928         % if they are still too close, add more " " pairs
1929         % until the result looks good
1930      \column {
1931       \line { \bold "4."
1932         \column {
1933           "This is verse four."
1934           "It has two lines."
1935         }
1936       }
1937       \hspace #0.1 % adds vertical spacing between verses
1938       \line { \bold "5."
1939         \column {
1940           "This is verse five."
1941           "It has two lines."
1942         }
1943       }
1944     }
1945   \hspace #0.1 % gives some extra space on the right margin;
1946       % can be removed if page space is tight
1947   }
1948 }
1949 @end lilypond
1950
1951
1952 @seealso
1953 Internals Reference:
1954 @rinternals{LyricText},
1955 @rinternals{StanzaNumber}.
1956
1957
1958 @node Songs
1959 @subsection Songs
1960
1961 @menu
1962 * References for songs::
1963 * Lead sheets::
1964 @end menu
1965
1966 @node References for songs
1967 @unnumberedsubsubsec References for songs
1968
1969 Songs are usually written on three staves with the melody for the
1970 singer on the top staff and two staves of piano accompaniment at
1971 the bottom.  The lyrics of the first stanza are printed immediately
1972 underneath the top staff.  If there are just a small number of
1973 further stanzas these can be printed immediately under the first
1974 one, but if there are more stanzas than can be easily accommodated
1975 there the second and subsequent stanzas are printed after the music
1976 as stand-alone text.
1977
1978 All the notational elements needed to write songs are fully described
1979 elsewhere:
1980
1981 @itemize
1982
1983 @item
1984 For constructing the staff layout, see @ref{Displaying staves}.
1985
1986 @item
1987 For writing piano music, see
1988 @ref{Keyboard and other multi-staff instruments}.
1989
1990 @item
1991 For writing the lyrics to a melody line, see
1992 @ref{Common notation for vocal music}.
1993
1994 @item
1995 For placing the lyrics, see @ref{Placing lyrics vertically}.
1996
1997 @item
1998 For entering stanzas, see @ref{Stanzas}.
1999
2000 @item
2001 Songs are frequently printed with the chording indicated by chord
2002 names above the staves.  This is described in
2003 @ref{Displaying chords}.
2004
2005 @item
2006 To print fret diagrams of the chords for guitar accompaniment or
2007 accompaniment by other fretted instruments, see @qq{Fret diagram
2008 markups} in @ref{Common notation for fretted strings}.
2009
2010 @end itemize
2011
2012 @seealso
2013 Learning Manual:
2014 @rlearning{Songs}.
2015
2016 Notation Reference:
2017 @ref{Common notation for vocal music},
2018 @ref{Displaying chords},
2019 @ref{Displaying staves},
2020 @ref{Keyboard and other multi-staff instruments},
2021 @ref{Placing lyrics vertically},
2022 @ref{Stanzas}.
2023
2024 @node Lead sheets
2025 @unnumberedsubsubsec Lead sheets
2026
2027 Lead sheets may be printed by combining vocal parts and @q{chord mode};
2028 this syntax is explained in @ref{Chord notation}.
2029
2030 @snippets
2031 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
2032 {simple-lead-sheet.ly}
2033
2034 @seealso
2035 Notation Reference:
2036 @ref{Chord notation}.
2037
2038
2039 @node Choral
2040 @subsection Choral
2041
2042 @cindex anthems
2043 @cindex part songs
2044 @cindex oratorio
2045 @cindex SATB
2046
2047 This section discusses notation issues that relate most directly
2048 to choral music.  This includes anthems, part songs, oratorio,
2049 etc.
2050
2051 @menu
2052 * References for choral::
2053 * Score layouts for choral::
2054 * Divided voices::
2055 @end menu
2056
2057 @node References for choral
2058 @unnumberedsubsubsec References for choral
2059
2060 Choral music is usually notated on two, three or four staves within
2061 a @code{ChoirStaff} group.  Accompaniment, if required, is placed
2062 beneath in a @code{PianoStaff} group, which is usually reduced in
2063 size for @emph{a capella} choral works.  The notes for each vocal
2064 part are placed in a @code{Voice} context, with each staff
2065 being given either a single vocal part (i.e., one @code{Voice}) or
2066 a pair of vocal parts (i.e., two @code{Voice}s).
2067
2068 Words are placed in @code{Lyrics} contexts, either underneath each
2069 corresponding music staff, or one above and one below the music
2070 staff if this contains the music for two parts.
2071
2072 Several common topics in choral music are described fully elsewhere:
2073
2074 @itemize
2075
2076 @item
2077 An introduction to creating an SATB vocal score can be found in
2078 the Learning Manual, see @rlearning{Four-part SATB vocal score}.
2079
2080 @item
2081 Several templates suitable for various styles of choral music can
2082 also be found in the Learning Manual, see
2083 @rlearning{Vocal ensembles}.
2084
2085 @item
2086 For information about @code{ChoirStaff} and @code{PianoStaff} see
2087 @ref{Grouping staves}.
2088
2089 @item
2090 Shape noteheads, as used in Sacred Harp and similar notation, are
2091 described in @ref{Shape note heads}.
2092
2093 @item
2094 When two vocal parts share a staff the stems, ties, slurs, etc., of
2095 the higher part will be directed up and those of the lower part
2096 down.  To do this, use @code{\voiceOne} and @code{\voiceTwo}.  See
2097 @ref{Single-staff polyphony}.
2098
2099 @end itemize
2100
2101 @predefined
2102 @code{\oneVoice},
2103 @code{\voiceOne},
2104 @code{\voiceTwo}.
2105
2106 @seealso
2107 Learning Manual:
2108 @rlearning{Four-part SATB vocal score},
2109 @rlearning{Vocal ensembles}.
2110
2111 Notation Reference:
2112 @ref{Context layout order},
2113 @ref{Grouping staves},
2114 @ref{Shape note heads},
2115 @ref{Single-staff polyphony}.
2116
2117 Internals Reference:
2118 @rinternals{ChoirStaff},
2119 @rinternals{Lyrics},
2120 @rinternals{PianoStaff}.
2121
2122 @node Score layouts for choral
2123 @unnumberedsubsubsec Score layouts for choral
2124
2125 Choral music containing four staves, with or without piano
2126 accompaniment, is usually laid out with two systems per page.
2127 Depending on the page size, achieving this may require changes
2128 to several default settings.  The following settings should be
2129 considered:
2130
2131 @itemize
2132
2133 @item
2134 The global staff size can be modified to change the overall size
2135 of the elements of the score.  See @ref{Setting the staff size}.
2136
2137 @item
2138 The distances between the systems, the staves and the lyrics can
2139 all be adjusted independently.  See @ref{Vertical spacing}.
2140
2141 @item
2142 The dimensions of the vertical layout variables can be displayed as
2143 an aid to adjusting the vertical spacing.  This and other
2144 possibilities for fitting the music onto fewer pages are described
2145 in @ref{Fitting music onto fewer pages}.
2146
2147 @item
2148 If the number of systems per page changes from one to two it is
2149 customary to indicate this with a system separator mark between
2150 the two systems.  See @ref{Separating systems}.
2151
2152 @item
2153 For details of other page formatting properties, see
2154 @ref{Page formatting}.
2155
2156 @end itemize
2157
2158
2159 Dynamic markings by default are placed below the staff, but in
2160 choral music they are usually placed above the staff in order to
2161 avoid the lyrics.  The predefined command @code{\dynamicUp} does
2162 this for the dynamic markings in a single @code{Voice} context.
2163 If there are many @code{Voice} contexts this predefined command
2164 would have to be placed in every one.  Alternatively its expanded
2165 form can be used to place all dynamic markings in the entire score
2166 above their respective staves, as shown here:
2167
2168 @lilypond[verbatim,quote]
2169 \score {
2170   \new ChoirStaff <<
2171     \new Staff {
2172       \new Voice {
2173         \relative c'' { g4\f g g g }
2174       }
2175     }
2176     \new Staff {
2177       \new Voice {
2178         \relative c' { d4 d d\p d }
2179       }
2180     }
2181   >>
2182   \layout {
2183     \context {
2184       \Score
2185       \override DynamicText #'direction = #UP
2186       \override DynamicLineSpanner #'direction = #UP
2187     }
2188   }
2189 }
2190 @end lilypond
2191
2192 @predefined
2193 @code{\dynamicUp}, @code{\dynamicDown}, @code{\dynamicNeutral}.
2194
2195 @seealso
2196 Notation Reference:
2197 @ref{Changing spacing},
2198 @ref{Displaying spacing},
2199 @ref{Fitting music onto fewer pages},
2200 @ref{Page formatting},
2201 @ref{Score layout},
2202 @ref{Separating systems},
2203 @ref{Setting the staff size},
2204 @ref{Using an extra voice for breaks},
2205 @ref{Vertical spacing}.
2206
2207 Internals Reference:
2208 @rinternals{VerticalAxisGroup},
2209 @rinternals{StaffGrouper}.
2210
2211
2212 @node Divided voices
2213 @unnumberedsubsubsec Divided voices
2214
2215 @cindex voices, divided
2216
2217 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
2218 {using-arpeggiobracket-to-make-divisi-more-visible.ly}
2219
2220 @seealso
2221 Notation Reference:
2222 @ref{Expressive marks as lines}.
2223
2224
2225 @node Opera and stage musicals
2226 @subsection Opera and stage musicals
2227
2228 The music, lyrics and dialogue to opera and stage musicals are
2229 usually set out in one or more of the following forms:
2230
2231 @itemize
2232
2233 @item
2234 A @emph{Conductors' Score} containing the full orchestral and vocal
2235 parts, together with libretto cues if there are spoken passages.
2236
2237 @item
2238 @emph{Orchestral Parts} containing the music for the individual
2239 instruments of the orchestra or band.
2240
2241 @item
2242 A @emph{Vocal Score} containing all vocal parts with piano
2243 accompaniment.  The accompaniment is usually an orchestral
2244 reduction, and if so the name of the original orchestral instrument
2245 is often indicated.  Vocal scores sometimes includes stage
2246 directions and libretto cues.
2247
2248 @item
2249 A @emph{Vocal Book} containing just the vocal parts
2250 (no accompaniment), sometimes combined with the libretto.
2251
2252 @item
2253 A @emph{Libretto} containing the extended passages of spoken
2254 dialogue usually found in musicals, together with the words to the
2255 sung parts.  Stage directions are usually included.  LilyPond can
2256 be used to typeset libretti but as they contain no music
2257 alternative methods may be preferable.
2258
2259 @end itemize
2260
2261 The sections in the LilyPond documentation which cover the topics
2262 needed to create scores in the styles commonly found in opera and
2263 musicals are indicated in the References below.  This is followed
2264 by sections covering those techniques which are peculiar to
2265 typesetting opera and musical scores.
2266
2267 @menu
2268 * References for opera and stage musicals::
2269 * Character names::
2270 * Musical cues::
2271 * Spoken music::
2272 * Dialogue over music::
2273 @end menu
2274
2275 @node References for opera and stage musicals
2276 @unnumberedsubsubsec References for opera and stage musicals
2277
2278 @itemize
2279
2280 @item
2281 A conductors' score contains many grouped staves and lyrics.  Ways
2282 of grouping staves is shown in @ref{Grouping staves}.  To nest
2283 groups of staves see @ref{Nested staff groups}.
2284
2285 @item
2286 The printing of empty staves in conductors' scores and vocal scores
2287 is often suppressed.  To create such a @qq{Frenched score} see
2288 @ref{Hiding staves}.
2289
2290 @item
2291 Writing orchestral parts is covered in @ref{Writing parts}.
2292 Other sections in the Specialist notation chapter may be relevant,
2293 depending on the orchestration used.  Many instruments are
2294 transposing instruments, see @ref{Instrument transpositions}.
2295
2296 @item
2297 If the number of systems per page changes from page to page it is
2298 customary to separate the systems with a system separator mark.
2299 See @ref{Separating systems}.
2300
2301 @item
2302 For details of other page formatting properties, see
2303 @ref{Page formatting}.
2304
2305 @item
2306 Dialogue cues and stage directions can be inserted with markup.
2307 See @ref{Text}.  Extensive stage directions can be inserted with
2308 a section of stand-alone markup between two @code{\score} blocks.
2309 See @ref{Separate text}.
2310
2311 @end itemize
2312
2313 @seealso
2314 Musical Glossary:
2315 @rglos{Frenched score},
2316 @rglos{Frenched staves},
2317 @rglos{transposing instrument}.
2318
2319 Notation Reference:
2320 @ref{Grouping staves},
2321 @ref{Hiding staves},
2322 @ref{Instrument transpositions},
2323 @ref{Nested staff groups},
2324 @ref{Page formatting},
2325 @ref{Separating systems},
2326 @ref{Transpose},
2327 @ref{Writing parts},
2328 @ref{Writing text}.
2329
2330
2331 @node Character names
2332 @unnumberedsubsubsec Character names
2333
2334 @cindex character names
2335 @cindex names, character
2336
2337 Character names are usually shown to the left of the staff when the
2338 staff is dedicated to that character alone.  The instrument name can
2339 be used for this purpose.
2340
2341 @lilypond[quote,verbatim,ragged-right]
2342 \score {
2343   <<
2344     \new Staff {
2345       \set Staff.instrumentName = #"Kaspar"
2346       \set Staff.shortInstrumentName = #"Kas"
2347       \relative c' {
2348         \clef "G_8"
2349         c4 c c c
2350         \break
2351         c4 c c c
2352       }
2353     }
2354     \new Staff {
2355       \set Staff.instrumentName = #"Melchior"
2356       \set Staff.shortInstrumentName = #"Mel"
2357       \clef "bass"
2358       \relative c' {
2359         a4 a a a
2360         a4 a a a
2361       }
2362     }
2363   >>
2364 }
2365 @end lilypond
2366
2367 When two or more characters share a staff the character's name is
2368 usually printed above the staff at the start of every section
2369 applying to that character.  This can be done with markup.  Often a
2370 specific font is used for this purpose.
2371
2372 @lilypond[quote,verbatim,relative=1]
2373 \clef "G_8"
2374 c4^\markup \fontsize #1 \smallCaps Kaspar
2375 c c c
2376 \clef "bass"
2377 a4^\markup \fontsize #1 \smallCaps Melchior
2378 a a a
2379 \clef "G_8"
2380 c4^\markup \fontsize #1 \smallCaps Kaspar
2381 c c c
2382 @end lilypond
2383
2384 Alternatively, if there are many character changes, it may be
2385 easier to set up @qq{instrument} definitions for each character at
2386 the top level so that @code{\instrumentSwitch} can be used to
2387 indicate each change.
2388
2389 @lilypond[quote,verbatim]
2390 \addInstrumentDefinition #"kaspar"
2391   #`((instrumentTransposition . ,(ly:make-pitch -1 0 0))
2392      (shortInstrumentName . "Kas.")
2393      (clefGlyph . "clefs.G")
2394      (clefOctavation . -7)
2395      (middleCPosition . 1)
2396      (clefPosition . -2)
2397      (instrumentCueName . ,(markup #:fontsize 1 #:smallCaps "Kaspar"))
2398      (midiInstrument . "voice oohs"))
2399
2400 \addInstrumentDefinition #"melchior"
2401   #`((instrumentTransposition . ,(ly:make-pitch 0 0 0))
2402      (shortInstrumentName . "Mel.")
2403      (clefGlyph . "clefs.F")
2404      (clefOctavation . 0)
2405      (middleCPosition . 6)
2406      (clefPosition . 2)
2407      (instrumentCueName . ,(markup #:fontsize 1 #:smallCaps "Melchior"))
2408      (midiInstrument . "voice aahs"))
2409
2410 \relative c' {
2411   \instrumentSwitch "kaspar"
2412   c4 c c c
2413   \instrumentSwitch "melchior"
2414   a4 a a a
2415   \instrumentSwitch "kaspar"
2416   c4 c c c
2417 }
2418 @end lilypond
2419
2420 @seealso
2421 Notation Reference:
2422 @ref{Instrument names},
2423 @ref{Scheme functions},
2424 @ref{Text},
2425 @ref{Text markup commands}.
2426
2427 Extending LilyPond:
2428 @rextend{Markup construction in Scheme}.
2429
2430 @node Musical cues
2431 @unnumberedsubsubsec Musical cues
2432
2433 @cindex musical cues
2434 @cindex cues, musical
2435
2436 Musical cues can be inserted in Vocal Scores, Vocal Books and
2437 Orchestral Parts to indicate what music in another part
2438 immediately precedes an entry.  Also, cues are often inserted in the
2439 piano reduction in Vocal Scores to indicate what each orchestral
2440 instrument is playing.  This aids the conductor when a full
2441 Conductors' Score is not available.
2442
2443 The basic mechanism for inserting cues is fully explained in the
2444 main text, see @ref{Quoting other voices} and
2445 @ref{Formatting cue notes}.  But when many cues have to be
2446 inserted, for example, as an aid to a conductor in a vocal score,
2447 the instrument name must be positioned carefully just before and
2448 close to the start of the cued notes.  The following example shows
2449 how this is done.  Note that the name of the grob for overriding
2450 the cued instrument name is @code{InstrumentSwitch}.
2451
2452 @lilypond[quote,verbatim]
2453 flute = \relative c'' {
2454   s4 s4 e g
2455 }
2456 \addQuote "flute" { \flute }
2457
2458 pianoRH = \relative c'' {
2459   c4. g8
2460   % position name of cued instrument just before the cued notes
2461   \once \override CueVoice.InstrumentSwitch
2462     #'self-alignment-X = #RIGHT
2463   % position name of cued instrument above the staff
2464   \once \override CueVoice.InstrumentSwitch #'direction = #UP
2465   \set CueVoice.instrumentCueName = "Flute"
2466   \cueDuring "flute" #UP { g4 bes4 }
2467 }
2468 pianoLH = \relative c { c4 <c' e> e, <g c> }
2469
2470 \score {
2471   \new PianoStaff <<
2472     \new Staff {
2473       \pianoRH
2474     }
2475     \new Staff {
2476       \clef "bass"
2477       \pianoLH
2478     }
2479   >>
2480 }
2481 @end lilypond
2482
2483 If a transposing instrument is being cued the instrument part should
2484 specify its key so the conversion of its cued notes will be done
2485 automatically.  The example below shows this transposition for a
2486 B-flat clarinet.  The notes in this example are low on the staff so
2487 @code{#DOWN} is specified in @code{\cueDuring} (so the stems are
2488 down) and the instrument name is positioned below the staff.  Note
2489 also that the piano right-hand voice is explicitly declared.  This
2490 is because the cued notes in this example begin at the start of the
2491 first bar and this would otherwise cause the entire piano right-hand
2492 notes to be placed in a @code{CueVoice} context.
2493
2494 @lilypond[quote,verbatim]
2495 clarinet = \relative c' {
2496   \transposition bes
2497   fis4 d d c
2498 }
2499 \addQuote "clarinet" { \clarinet }
2500
2501 pianoRH = \relative c'' {
2502   \transposition c'
2503   % position name of cued instrument just before the cued notes
2504   \once \override CueVoice.InstrumentSwitch
2505     #'self-alignment-X = #RIGHT
2506   % position name of cued instrument below the staff
2507   \once \override CueVoice.InstrumentSwitch #'direction = #DOWN
2508   \set CueVoice.instrumentCueName = "Clar."
2509   \cueDuring "clarinet" #DOWN { c4. g8 }
2510   g4 bes4
2511 }
2512 pianoLH = \relative c { c4 <c' e> e, <g c> }
2513
2514 \score {
2515   <<
2516     \new PianoStaff <<
2517       \new Staff {
2518         \new Voice {
2519           \pianoRH
2520         }
2521       }
2522       \new Staff {
2523         \clef "bass"
2524         \pianoLH
2525       }
2526     >>
2527   >>
2528 }
2529 @end lilypond
2530
2531 From these two examples it is clear that inserting many cues in a
2532 Vocal Score would be extremely tedious, and the notes of the piano
2533 part would be obscured by the many overrides.  However, as the
2534 following snippet shows, it is possible to define a music function
2535 to reduce the amount of typing and to make the piano notes clearer.
2536
2537 @snippets
2538 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
2539 {adding-orchestral-cues-to-a-vocal-score.ly}
2540
2541 @seealso
2542 Musical Glossary:
2543 @rglos{cue-notes}.
2544
2545 Notation Reference:
2546 @ref{Aligning objects},
2547 @ref{Direction and placement},
2548 @ref{Formatting cue notes},
2549 @ref{Quoting other voices},
2550 @ref{Using music functions}.
2551
2552 Snippets:
2553 @rlsr{vocal-music}.
2554
2555 Internals Reference:
2556 @rinternals{InstrumentSwitch},
2557 @rinternals{CueVoice}.
2558
2559 @knownissues
2560 @code{\cueDuring} automatically inserts a @code{CueVoice} context
2561 and all cue notes are placed in that context.  This means it is not
2562 possible to have two overlapping sequences of cued notes by this
2563 technique.  Overlapping sequences could be entered by explicitly
2564 declaring separate @code{CueVoice} contexts and using
2565 @code{\quoteDuring} to extract and insert the cued notes.
2566
2567
2568 @node Spoken music
2569 @unnumberedsubsubsec Spoken music
2570
2571 @cindex parlato
2572 @cindex Sprechgesang
2573 Such effects as @q{parlato} or @q{Sprechgesang} require performers to speak
2574 without pitch but still with rhythm; these are notated by cross
2575 note heads, as demonstrated in @ref{Special note heads}.
2576
2577 @c TODO add "marking-notes-on-spoken-parts" snippet -vv
2578 @c add "showing the rhythm of a melody" snip
2579 @c add "one staff-line notation"
2580 @c add "improvisation" ref
2581 @c add "lyrics independents of notes" ref
2582
2583 @node Dialogue over music
2584 @unnumberedsubsubsec Dialogue over music
2585
2586 Dialogue over music is usually printed over the staves in an italic
2587 font, with the start of each phrase keyed in to a particular music
2588 moment.
2589
2590 For short interjections a simple markup suffices.
2591
2592 @lilypond[quote,verbatim,relative=2]
2593 a4^\markup { \smallCaps { Alex - } \italic { He's gone } } a a a
2594 a4 a a^\markup { \smallCaps { Bethan - } \italic Where? } a
2595 a4 a a a
2596 @end lilypond
2597
2598 For longer phrases it may be necessary to expand the music to make
2599 the words fit neatly.  There is no provision in LilyPond to do this
2600 fully automatically, and some manual intervention to layout the
2601 page will be necessary.
2602
2603 For long phrases or for passages with a lot of closely packed
2604 dialogue, using a Lyrics context will give better results.  The
2605 Lyrics context should not be associated with a music Voice; instead
2606 each section of dialogue should be given an explicit duration.  If
2607 there is a gap in the dialogue, the final word should be separated
2608 from the rest and the duration split between them so that the
2609 underlying music spaces out smoothly.
2610
2611 If the dialogue extends for more than one line it will be necessary
2612 to manually insert @code{\break}s and adjust the placing of the
2613 dialogue to avoid running into the right margin.  The final word of
2614 the last measure on a line should also be separated out, as above.
2615
2616 Here is an example illustating how this might be done.
2617
2618 @c This should be a snippet, but it can't be as it needs to be
2619 @c manually adjusted to suit the imposed line length.  -td
2620
2621 @lilypond[quote,verbatim,ragged-right]
2622 music = \relative c'' {
2623   \repeat unfold 3 { a4 a a a }
2624 }
2625
2626 dialogue = \lyricmode {
2627   \markup {
2628     \fontsize #1 \upright \smallCaps Abe:
2629     "Say this over measures one and"
2630   }4*7
2631   "two"4 |
2632   \break
2633   "and this over measure"4*3
2634   "three"4 |
2635 }
2636
2637 \score {
2638   <<
2639     \new Lyrics \with {
2640       \override LyricText #'font-shape = #'italic
2641       \override LyricText #'self-alignment-X = #LEFT
2642     }
2643     { \dialogue }
2644     \new Staff {
2645       \new Voice { \music }
2646     }
2647   >>
2648 }
2649 @end lilypond
2650
2651 @c TODO show use of \column to produce dialogue on two lines
2652
2653 @seealso
2654 Notation Reference:
2655 @ref{Manual syllable durations},
2656 @ref{Text}.
2657
2658 Internal Reference:
2659 @rinternals{LyricText}.
2660
2661
2662 @node Chants psalms and hymns
2663 @subsection Chants psalms and hymns
2664
2665 @cindex chants
2666 @cindex psalms
2667 @cindex hymns
2668 @cindex religious music
2669
2670 The music and words for chants, psalms and hymns usually follow a
2671 well-established format in any particular church.  Although the
2672 formats may differ from church to church the type-setting problems
2673 which arise are broadly similar, and are covered in this section.
2674
2675 @menu
2676 * References for chants and psalms::
2677 * Setting a chant::
2678 * Pointing a psalm::
2679 * Partial measures in hymn tunes::
2680 @end menu
2681
2682 @node References for chants and psalms
2683 @unnumberedsubsubsec References for chants and psalms
2684
2685 Typesetting Gregorian chant in various styles of ancient notation
2686 is described in @ref{Ancient notation}.
2687
2688 @seealso
2689 Notation reference:
2690 @ref{Ancient notation}.
2691
2692
2693 @node Setting a chant
2694 @unnumberedsubsubsec Setting a chant
2695
2696 Modern chant settings use modern notation with varying numbers of
2697 elements taken from ancient notation.  Some of the elements and
2698 methods to consider are shown here.
2699
2700 Chants often use quarter notes without stems to indicate the pitch,
2701 with the rhythm being taken from the spoken rhythm of the words.
2702
2703 @lilypond[verbatim,quote]
2704 stemOff = { \override Staff.Stem #'transparent = ##t }
2705
2706 \relative c' {
2707   \stemOff
2708   a'4 b c2 |
2709 }
2710
2711 @end lilypond
2712
2713 Chants often omit the bar lines or use shortened or dotted bar
2714 lines to indicate pauses in the music.  To omit all bar lines from
2715 all staves remove the bar line engraver completely:
2716
2717 @lilypond[verbatim,quote]
2718 \score {
2719   \new StaffGroup <<
2720     \new Staff {
2721       \relative c'' {
2722         a4 b c2 |
2723         a4 b c2 |
2724         a4 b c2 |
2725       }
2726     }
2727     \new Staff {
2728       \relative c'' {
2729         a4 b c2 |
2730         a4 b c2 |
2731         a4 b c2 |
2732       }
2733     }
2734   >>
2735   \layout {
2736     \context {
2737       \Staff
2738       \remove Bar_engraver
2739     }
2740   }
2741 }
2742 @end lilypond
2743
2744 Bar lines can also be removed on a staff-by-staff basis:
2745
2746 @lilypond[verbatim, quote]
2747 \score {
2748   \new ChoirStaff <<
2749     \new Staff
2750     \with { \remove Bar_engraver } {
2751       \relative c'' {
2752         a4 b c2 |
2753         a4 b c2 |
2754         a4 b c2 |
2755       }
2756     }
2757     \new Staff {
2758       \relative c'' {
2759         a4 b c2 |
2760         a4 b c2 |
2761         a4 b c2 |
2762       }
2763     }
2764   >>
2765 }
2766 @end lilypond
2767
2768 To remove bar lines from just a section of music treat it as a
2769 cadenza.  If the section is long you may need to insert dummy
2770 barlines with @code{\bar ""} to show where the line should break.
2771
2772 @lilypond[verbatim,quote,relative=2]
2773 a4 b c2 |
2774 \cadenzaOn
2775 a4 b c2
2776 a4 b c2
2777 \bar ""
2778 a4 b c2
2779 a4 b c2
2780 \cadenzaOff
2781 a4 b c2 |
2782 a4 b c2 |
2783 @end lilypond
2784
2785 Rests or pauses in chants can be indicated by modified bar lines.
2786
2787 @lilypond[verbatim, quote,relative=2]
2788 a4
2789 \cadenzaOn
2790 b c2
2791 a4 b c2
2792 \bar "'"
2793 a4 b c2
2794 a4 b c2
2795 \bar ":"
2796 a4 b c2
2797 \bar "dashed"
2798 a4 b c2
2799 \bar "||"
2800 @end lilypond
2801
2802 Alternatively, the notation used in Gregorian chant for pauses or
2803 rests is sometimes used even though the rest of the notation is
2804 modern.  This uses a modified @code{\breathe} mark:
2805
2806 @lilypond[verbatim,quote]
2807 divisioMinima = {
2808   \once \override BreathingSign  #'stencil = #ly:breathing-sign::divisio-minima
2809   \once \override BreathingSign  #'Y-offset = #0
2810   \breathe
2811 }
2812 divisioMaior = {
2813   \once \override BreathingSign  #'stencil = #ly:breathing-sign::divisio-maior
2814   \once \override BreathingSign  #'Y-offset = #0
2815   \breathe
2816 }
2817 divisioMaxima = {
2818   \once \override BreathingSign  #'stencil = #ly:breathing-sign::divisio-maxima
2819   \once \override BreathingSign  #'Y-offset = #0
2820   \breathe
2821 }
2822 finalis = {
2823   \once \override BreathingSign  #'stencil = #ly:breathing-sign::finalis
2824   \once \override BreathingSign  #'Y-offset = #0
2825   \breathe
2826 }
2827
2828 \score {
2829   \relative c'' {
2830     g2 a4 g
2831     \divisioMinima
2832     g2 a4 g
2833     \divisioMaior
2834     g2 a4 g
2835     \divisioMaxima
2836     g2 a4 g
2837     \finalis
2838   }
2839   \layout {
2840     \context {
2841       \Staff
2842       \remove Bar_engraver
2843     }
2844   }
2845 }
2846 @end lilypond
2847
2848 Chants usually omit the time signature and often omit the clef too.
2849
2850 @lilypond[verbatim,quote]
2851 \score {
2852   \new Staff {
2853     \relative c'' {
2854       a4 b c2 |
2855       a4 b c2 |
2856       a4 b c2 |
2857     }
2858   }
2859   \layout {
2860     \context {
2861       \Staff
2862       \remove Bar_engraver
2863       \remove Time_signature_engraver
2864       \remove Clef_engraver
2865     }
2866   }
2867 }
2868 @end lilypond
2869
2870 Chants for psalms in the Anglican tradition are usually either
2871 @emph{single}, with 7 bars of music, or @emph{double}, with two lots
2872 of 7 bars.  Each group of 7 bars is divided into two halves,
2873 corresponding to the two halves of each verse, usually separated by
2874 a double bar line.  Only whole and half notes are used.  The 1st bar
2875 in each half always contains a single chord of whole notes.  This is
2876 the @qq{reciting note}.  Chants are usually centered on the page.
2877
2878 @lilypond[verbatim,quote]
2879 SopranoMusic = \relative g' {
2880   g1 | c2 b | a1 | \bar "||"
2881   a1 | d2 c | c b | c1 | \bar "||"
2882 }
2883
2884 AltoMusic = \relative c' {
2885   e1 | g2 g | f1 |
2886   f1 | f2 e | d d | e1 |
2887 }
2888
2889 TenorMusic = \relative a {
2890   c1 | c2 c | c1 |
2891   d1 | g,2 g | g g | g1 |
2892 }
2893
2894 BassMusic =  \relative c {
2895   c1 | e2 e | f1 |
2896   d1 | b2 c | g' g | c,1 |
2897 }
2898
2899 global = {
2900   \time 2/2
2901 }
2902
2903 % Use markup to center the chant on the page
2904 \markup {
2905   \fill-line {
2906     \score {  % centered
2907       <<
2908         \new ChoirStaff <<
2909           \new Staff <<
2910             \global
2911             \clef "treble"
2912             \new Voice = "Soprano" <<
2913               \voiceOne
2914               \SopranoMusic
2915             >>
2916             \new Voice = "Alto" <<
2917               \voiceTwo
2918               \AltoMusic
2919             >>
2920           >>
2921           \new Staff <<
2922             \clef "bass"
2923             \global
2924             \new Voice = "Tenor" <<
2925               \voiceOne
2926               \TenorMusic
2927             >>
2928             \new Voice = "Bass" <<
2929               \voiceTwo
2930               \BassMusic
2931             >>
2932           >>
2933         >>
2934       >>
2935       \layout {
2936         \context {
2937           \Score
2938           \override SpacingSpanner
2939           #'base-shortest-duration = #(ly:make-moment 1 2)
2940         }
2941         \context {
2942           \Staff
2943           \remove "Time_signature_engraver"
2944         }
2945       }
2946     }  % End score
2947   }
2948 }  % End markup
2949 @end lilypond
2950
2951 Some other approaches to setting such a chant are shown in the first
2952 of the following snippets.
2953
2954 @snippets
2955
2956 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
2957 {chant-or-psalms-notation.ly}
2958
2959 Canticles and other liturgical texts may be set more freely, and
2960 may use notational elements from ancient music.  Often the words
2961 are shown underneath and aligned with the notes.  If so, the notes
2962 are spaced in accordance with the syllables rather than the notes'
2963 durations.
2964
2965 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
2966 {ancient-notation-template----modern-transcription-of-gregorian-music.ly}
2967
2968 @seealso
2969 Learning Manual:
2970 @rlearning{Visibility and color of objects},
2971 @rlearning{Vocal ensembles}.
2972
2973 Notation Reference:
2974 @ref{Ancient notation},
2975 @ref{Bar lines},
2976 @ref{Modifying context plug-ins},
2977 @ref{Typesetting Gregorian chant},
2978 @ref{Unmetered music},
2979 @ref{Visibility of objects}.
2980
2981
2982 @node Pointing a psalm
2983 @unnumberedsubsubsec Pointing a psalm
2984
2985 The words to an Anglican psalm are usually printed in separate
2986 verses centered underneath the chant.
2987
2988 Single chants (with 7 bars) are repeated for every verse.  Double
2989 chants (with 14 bars) are repeated for every pair of verses.  Marks
2990 are inserted in the words to show how they should be fitted to the
2991 chant.  Each verse is divided into two halves.  A colon is usually
2992 used to indicate this division.  This corresponds to the double bar
2993 line in the music.  The words before the colon are sung to the first
2994 three bars of music; the words after the colon are sung to the last
2995 four bars.
2996
2997 Single bar lines (or in some psalters an inverted comma or similar
2998 symbol) are inserted between words to indicate where the bar lines
2999 in the music fall.  In markup mode a single bar line can be entered
3000 with the bar check symbol, @code{|}.
3001
3002 @lilypond[verbatim,quote]
3003 \markup {
3004   \fill-line {
3005     \column {
3006       \left-align {
3007         \line { O come let us sing | unto the | Lord : let }
3008         \line { us heartily rejoice in the | strength of | our }
3009         \line { sal- | -vation. }
3010       }
3011     }
3012   }
3013 }
3014 @end lilypond
3015
3016 Other symbols may require glyphs from the @code{fetaMusic} fonts.
3017 For details, see @ref{Fonts}.
3018
3019 @lilypond[verbatim,quote]
3020 tick = \markup {
3021   \raise #1 \fontsize #-5 \musicglyph #"scripts.rvarcomma"
3022 }
3023 \markup {
3024   \fill-line {
3025     \column {
3026       \left-align {
3027         \line { O come let us sing \tick unto the \tick Lord : let }
3028         \line {
3029           us heartily rejoice in the \tick strength of \tick our
3030         }
3031         \line { sal \tick vation. }
3032       }
3033     }
3034   }
3035 }
3036 @end lilypond
3037
3038 Where there is one whole note in a bar all the words corresponding
3039 to that bar are recited on that one note in speech rhythm.  Where
3040 there are two notes in a bar there will usually be only one or two
3041 corresponding syllables.  If there are more that two syllables a
3042 dot is usually inserted to indicate where the change in note occurs.
3043
3044 @lilypond[verbatim,quote]
3045 dot = \markup {
3046   \raise #0.7 \musicglyph #"dots.dot"
3047 }
3048 tick = \markup {
3049   \raise #1 \fontsize #-5 \musicglyph #"scripts.rvarcomma"
3050 }
3051 \markup {
3052   \fill-line {
3053     \column {
3054       \left-align {
3055         \line {
3056           O come let us sing \tick unto \dot the \tick Lord : let
3057         }
3058         \line {
3059           us heartily rejoice in the \tick strength of \tick our
3060         }
3061         \line { sal \tick vation. }
3062       }
3063     }
3064   }
3065 }
3066 @end lilypond
3067
3068 In some psalters an asterisk is used to indicate a break in a
3069 recited section instead of a comma, and stressed or slightly
3070 lengthened syllables are indicated in bold text.
3071
3072 @lilypond[verbatim,quote]
3073 dot = \markup {
3074   \raise #0.7 \musicglyph #"dots.dot"
3075 }
3076 tick = \markup {
3077   \raise #1 \fontsize #-5 \musicglyph #"scripts.rvarcomma"
3078 }
3079 \markup {
3080   \fill-line {
3081     \column {
3082       \left-align {
3083         \line { Today if ye will hear his voice * }
3084         \line {
3085           \concat { \bold hard en }
3086           | not your | hearts : as in the pro-
3087         }
3088         \line { vocation * and as in the \bold day of tempt- | }
3089         \line { -ation | in the | wilderness. }
3090       }
3091     }
3092   }
3093 }
3094 @end lilypond
3095
3096 In other psalters an accent is placed over the syllable to indicate
3097 stress.
3098
3099 @lilypond[verbatim,quote]
3100 tick = \markup {
3101   \raise #2 \fontsize #-5 \musicglyph #"scripts.rvarcomma"
3102 }
3103 \markup {
3104   \fill-line {
3105     \column {
3106       \left-align {
3107         \line {
3108           O come let us \concat {
3109             si \combine \tick ng
3110           }
3111           | unto the | Lord : let
3112         }
3113         \line {
3114           us heartily \concat {
3115             rejo \combine \tick ice
3116           }
3117           in the | strength of | our
3118         }
3119         \line { sal- | -vation. }
3120       }
3121     }
3122   }
3123 }
3124 @end lilypond
3125
3126 The use of markup to center text, and arrange lines in columns is
3127 described in @ref{Formatting text}.
3128
3129 Most of these elements are shown in one or other of the two verses
3130 in the template, see @qq{Psalms} in @rlearning{Vocal ensembles}.
3131
3132 @seealso
3133 Learning Manual:
3134 @rlearning{Vocal ensembles}.
3135
3136 Notation Reference:
3137 @ref{Fonts},
3138 @ref{Formatting text}.
3139
3140
3141 @node Partial measures in hymn tunes
3142 @unnumberedsubsubsec Partial measures in hymn tunes
3143
3144 Hymn tunes frequently start and end every line of music with
3145 partial measures so that each line of music corresponds exactly
3146 with a line of text.  This requires a @code{\partial} command at
3147 the start of the music and @code{\bar "|"} or @code{\bar "||"}
3148 commands at the end of each line.
3149
3150 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
3151 {hymn-template.ly}
3152
3153
3154 @node Ancient vocal music
3155 @subsection Ancient vocal music
3156
3157 Ancient vocal music is supported, as explained in @ref{Ancient notation}.
3158
3159 @c TODO
3160
3161 @c Add "Printing both the ancient and the modern clef in vocal music" snippet,
3162 @c and "Transcription of Ancient music with incipit" snippet. -vv
3163
3164 @seealso
3165 Notation Reference:
3166 @ref{Ancient notation}.
3167
3168
3169
3170