2 @c This file is part of lilypond.tely
4 @c A menu is needed before every deeper *section nesting of @node's; run
5 @c M-x texinfo-all-menus-update
6 @c to automatically fill in these menus before saving changes
8 @c FIXME: singular vs. plural: Beams/Beam
12 @chapter Notation manual
14 This chapter describes all the different types of notation supported
15 by LilyPond. It is intended as a reference for users that are already
16 somewhat familiar with using LilyPond.
20 * Easier music entry::
34 * Contemporary notation::
42 @c FIXME: Note entry vs Music entry at top level menu is confusing.
48 The basic elements of any piece of music are the notes. This section
49 is about basic notation elements notes, rests and related constructs,
50 such as stems, tuplets and ties.
55 * Chromatic alterations::
70 A note is printed by specifying its pitch and then its duration:
71 @footnote{Notes constitute the most basic elements of LilyPond input,
72 but they do not form valid input on their own without a @code{\score}
73 block. However, for the sake of brevity and simplicity we will
74 generally omit @code{\score} blocks and @code{\paper} declarations in
77 @lilypond[fragment,verbatim]
86 @cindex Note specification
88 @cindex entering notes
90 The most common syntax for pitch entry is used in @code{\chords} and
91 @code{\notes} mode. In Note and Chord mode, pitches may be designated
92 by names. The notes are specified by the letters @code{a} through
93 @code{g}, while the octave is formed with notes ranging from @code{c}
94 to @code{b}. The pitch @code{c} is an octave below middle C and the
95 letters span the octave above that C:
97 @lilypond[fragment,verbatim]
99 a,4 b, c d e f g a b c' d' e' \clef treble f' g' a' b' c''
102 @cindex note names, Dutch
104 A sharp is formed by adding @code{-is} to the end of a pitch name and
105 a flat is formed by adding @code{-es}. Double sharps and double flats
106 are obtained by adding @code{-isis} or @code{-eses}. These
107 names are the Dutch note names. In Dutch, @code{aes} is contracted to
108 @code{as}, but both forms are accepted. Similarly, both
109 @code{es} and @code{ees} are accepted.
111 Half-flats and half-sharps are formed by adding @code{-eh} and
112 @code{-ih}; the following is a series of Cs with increasing pitches:
114 @cindex quarter tones
115 @cindex semi-flats, semi-sharps
117 @lilypond[verbatim,relative=2]
129 There are predefined sets of note names for various other languages.
130 To use them, include the language specific init file. For
131 example: @code{\include "english.ly"}. The available language files
132 and the note names they define are:
137 Note Names sharp flat
138 nederlands.ly c d e f g a bes b -is -es
139 english.ly c d e f g a bf b -s/-sharp -f/-flat
141 deutsch.ly c d e f g a b h -is -es
142 norsk.ly c d e f g a b h -iss/-is -ess/-es
143 svenska.ly c d e f g a b h -iss -ess
144 italiano.ly do re mi fa sol la sib si -d -b
145 catalan.ly do re mi fa sol la sib si -d/-s -b
146 espanol.ly do re mi fa sol la sib si -s -b
155 The optional octave specification takes the form of a series of
156 single quote (`@code{'}') characters or a series of comma
157 (`@code{,}') characters. Each @code{'} raises the pitch by one
158 octave; each @code{,} lowers the pitch by an octave:
160 @lilypond[fragment,verbatim,center]
161 c' c'' es' g' as' gisis' ais'
167 Notes can be hidden and unhidden with the following commands:
169 @cindex @code{\hideNotes}
171 @cindex @code{\unHideNotes}
177 Internals: @internalsref{NoteEvent}, and @internalsref{NoteHead}.
179 @node Chromatic alterations
180 @subsection Chromatic alterations
182 Normally accidentals are printed automatically, but you may also
183 print them manually. A reminder accidental
184 @cindex reminder accidental
186 can be forced by adding an exclamation mark @code{!}
187 after the pitch. A cautionary accidental
188 @cindex cautionary accidental
189 @cindex parenthesized accidental
190 (i.e. an accidental within parentheses) can be obtained by adding the
191 question mark `@code{?}' after the pitch:
193 @lilypond[fragment,verbatim]
194 cis' cis' cis'! cis'?
198 The automatic production of accidentals can be tuned in many
199 ways. For more information, refer to @ref{Accidentals}.
204 A chord is formed by a enclosing a set of pitches in @code{<} and
205 @code{>}. A chord may be followed by a duration, and a set of
206 articulations, just like simple notes.
216 Rests are entered like notes, with the note name @code{r}:
218 @lilypond[raggedright,verbatim]
222 Whole bar rests, centered in middle of the bar,
223 must be done with multi measure rests. They are discussed in
224 @ref{Multi measure rests}.
227 A rest's vertical position may be explicitly specified by entering a
228 note with the @code{\rest} keyword appended. This makes manual
229 formatting in polyphonic music easier. Rest collision testing will
230 leave these rests alone:
232 @lilypond[raggedright,verbatim]
238 Internals: @internalsref{RestEvent}, and @internalsref{Rest}.
245 @cindex Invisible rest
248 An invisible rest (also called a `skip') can be entered like a note
249 with note name `@code{s}' or with @code{\skip @var{duration}}:
251 @lilypond[raggedright,verbatim]
255 The @code{s} syntax is only available in note mode and chord mode. In
256 other situations, you should use the @code{\skip} command:
258 @lilypond[raggedright,verbatim]
261 { \time 4/8 \skip 2 \time 4/4 }
262 \notes\relative c'' { a2 a1 }
267 The skip command is merely an empty musical placeholder. It does not
268 produce any output, not even transparent output.
270 The @code{s} skip command does create @internalsref{Staff} and
271 @internalsref{Voice} when necessary, similar to note and rest
272 commands. For example, the following results in an empty staff.
274 @lilypond[raggedright,verbatim]
275 \score { \notes { s4 } }
278 The same fragment using @code{\skip} results in an empty page.
282 Internals: @internalsref{SkipEvent}, @internalsref{SkipMusic}.
287 @subsection Durations
293 In Note, Chord, and Lyrics mode, durations are designated by numbers
294 and dots: durations are entered as their reciprocal values. For example,
295 a quarter note is entered using a @code{4} (since it is a 1/4 note), while
296 a half note is entered using a @code{2} (since it is a 1/2 note). For notes
297 longer than a whole you must use variables:
301 c'1 c'2 c'4 c'8 c'16 c'32 c'64 c'64
303 r1 r2 r4 r8 r16 r32 r64 r64
308 \notes \relative c'' {
310 a1 a2 a4 a8 a16 a32 a64 a64
312 r1 r2 r4 r8 r16 r32 r64 r64
317 \remove "Clef_engraver"
318 \override StaffSymbol #'transparent = ##t
319 \override TimeSignature #'transparent = ##t
320 \consists "Pitch_squash_engraver"
327 If the duration is omitted then it is set to the previously entered
328 duration. The default for the first note is a quarter note. The duration
329 can be followed by dots (`@code{.}') in order to obtain dotted note
333 @lilypond[fragment,verbatim,center]
334 a' b' c''8 b' a'4 a'4. b'4.. c'8.
339 You can alter the length of duration by a fraction @var{N/M}
340 appending `@code{*}@var{N/M}' (or `@code{*}@var{N}' if @var{M=1}). This
341 will not affect the appearance of the notes or rests produced.
342 In the following example, the first three notes take up exactly two
344 @lilypond[fragment,relative=2,verbatim]
346 a4*2/3 gis4*2/3 a4*2/3
353 Dots are normally moved up to avoid staff lines, except in polyphonic
354 situations. The following commands may be used to force a particular
357 @cindex @code{\dotsUp}
359 @cindex @code{\dotsDown}
361 @cindex @code{\dotsBoth}
366 Internals: @internalsref{Dots}, and @internalsref{DotColumn}.
371 Whenever a note is found, a @internalsref{Stem} object is created
372 automatically. For whole notes and rests, they are also created but
377 @cindex @code{\stemUp}
379 @cindex @code{\stemDown}
381 @cindex @code{\stemBoth}
392 A tie connects two adjacent note heads of the same pitch. The tie in
393 effect extends the length of a note. Ties should not be confused with
394 slurs, which indicate articulation, or phrasing slurs, which indicate
395 musical phrasing. A tie is entered using the tilde symbol `@code{~}':
397 @lilypond[fragment,verbatim,center]
398 e' ~ e' <c' e' g'> ~ <c' e' g'>
401 When a tie is applied to a chord, all note heads whose pitches match
402 are connected. When no note heads match, no ties will be created.
404 In its meaning a tie is just a way of extending a note duration, similar
405 to the augmentation dot; in the following example there are two ways of
406 notating exactly the same concept:
408 @lilypond[fragment,raggedright,quote]
409 \time 3/4 c'2. c'2 ~ c'4
411 If you need to tie a lot of notes over bars, it may be easier to use automatic
412 note splitting (see @ref{Automatic note splitting}).
417 @cindex @code{\tieUp}
419 @cindex @code{\tieDown}
421 @cindex @code{\tieBoth}
423 @cindex @code{\tieDotted}
425 @cindex @code{\tieSolid}
430 In this manual: @ref{Automatic note splitting}.
432 Internals: @internalsref{TieEvent}, @internalsref{Tie}.
434 For tying only a subset of the note heads of a pair of chords, see
435 @inputfileref{input/regression,tie-chord-partial.ly}.
440 Switching staves when a tie is active will not produce a slanted tie.
442 Formatting of ties is a difficult subject. The results are often not
452 @cindex @code{\times}
454 Tuplets are made out of a music expression by multiplying all durations
457 @cindex @code{\times}
459 \times @var{fraction} @var{musicexpr}
463 The duration of @var{musicexpr} will be multiplied by the fraction.
464 The fraction's denominator will be printed over the notes, optionally
465 with a bracket. The most common tuplet is the triplet in which 3
466 notes have the length of 2, so the notes are 2/3 of their written
469 @lilypond[fragment,verbatim,center]
470 g'4 \times 2/3 {c'4 c' c'} d'4 d'4
473 The property @code{tupletSpannerDuration} specifies how long each
474 bracket should last. With this, you can make lots of tuplets while
475 typing @code{\times} only once, saving lots of typing. In the next
476 example, there are two triplets shown, while @code{\times} was only
479 @lilypond[fragment,relative,raggedright,verbatim]
480 \set tupletSpannerDuration = #(ly:make-moment 1 4)
481 \times 2/3 { c'8 c c c c c }
484 The format of the number is determined by the property
485 @code{tupletNumberFormatFunction}. The default prints only the
486 denominator, but if it is set to the Scheme function
487 @code{fraction-tuplet-formatter}, @var{num}:@var{den} will be printed
491 @cindex @code{tupletNumberFormatFunction}
492 @cindex tuplet formatting
497 @cindex @code{\tupletUp}
499 @cindex @code{\tupletDown}
501 @cindex @code{\tupletBoth}
506 Internals: @internalsref{TupletBracket}, and @internalsref{TimeScaledMusic}.
508 Examples: @inputfileref{input/regression,tuplet-nest.ly}.
512 Nested tuplets are not formatted automatically. In this case, outer
513 tuplet brackets should be moved manually, which is demonstrated in
514 @inputfileref{input/regression,tuplet-nest.ly}.
518 @node Easier music entry
519 @section Easier music entry
522 When entering music it is easy to introduce errors. This section deals
523 with tricks and features of the input language that were added solely
524 to help entering music, and find and correct mistakes.
526 It is also possible to use external programs, for example GUI
527 interfaces, or MIDI transcription programs, to enter or edit
528 music. Refer to the website for more information. Finally, there are
529 tools make debugging easier, by linking the input file and the output
530 shown on screen. See @ref{Point and click} for more information.
537 * Skipping corrected music::
538 * Automatic note splitting::
544 @node Relative octaves
545 @subsection Relative octaves
547 @cindex relative octave specification
549 Octaves are specified by adding @code{'} and @code{,} to pitch names.
550 When you copy existing music, it is easy to accidentally put a pitch
551 in the wrong octave and hard to find such an error. The relative
552 octave mode prevents these errors: a single error puts the rest of the
553 piece off by one octave:
555 @cindex @code{\relative}
557 \relative @var{startpitch} @var{musicexpr}
560 The octave of notes that appear in @var{musicexpr} are calculated as
561 follows: If no octave changing marks are used, the basic interval
562 between this and the last note is always taken to be a fourth or less
563 (; this distance is determined without regarding alterations: a
564 @code{fisis} following a @code{ceses} will be put above the
567 The octave changing marks @code{'} and @code{,} can be added to raise
568 or lower the pitch by an extra octave. Upon entering relative mode,
569 an absolute starting pitch must be specified that will act as the
570 predecessor of the first note of @var{musicexpr}.
572 Here is the relative mode shown in action:
573 @lilypond[fragment,raggedright,verbatim,center]
579 Octave changing marks are used for intervals greater than a fourth:
580 @lilypond[fragment,verbatim,center]
585 If the preceding item is a chord, the first note of the chord is used
586 to determine the first note of the next chord:
588 @lilypond[fragment,verbatim,center]
595 @cindex @code{\notes}
597 The pitch after the @code{\relative} contains a note name. To parse
598 the pitch as a note name, you have to be in note mode, so there must
599 be a surrounding @code{\notes} keyword (which is not
602 The relative conversion will not affect @code{\transpose},
603 @code{\chords} or @code{\relative} sections in its argument. If you
604 want to use relative within transposed music, you must place an
605 additional @code{\relative} inside the @code{\transpose}.
608 @subsection Octave check
611 Octave checks make octave errors easier to correct: a note may be
612 followed by @code{=}@var{quotes} which indicates what its absolute
613 octave should be. In the following example,
615 \relative c'' @{ c='' b=' d,='' @}
619 @c take care with @code, adds confusing quotes.
620 the d will generate a warning, because a d'' is expected, but a d' is
621 found. In the output, the octave is corrected this and the following
626 There is also a syntax that is separate from the notes.
631 This checks that @var{pitch} (without octave) yields @var{pitch} (with
632 octave) in \relative mode. If not, a warning is printed, and the
633 octave is corrected, for example, the first check is passed
634 successfully. The second check fails with an error message. The
635 octave is adjusted so the following notes are in the correct octave
646 The octave of a note following an octave check is determined with
647 respect to the note preceding it. In the next fragment, the last note
648 is a @code{a'}, above middle C. Hence, the @code{\octave} check may
649 be deleted without changing the meaning of the piece.
651 @lilypond[verbatim,fragment]
660 @subsection Bar check
664 @cindex @code{barCheckSynchronize}
667 Bar checks help detect errors in the durations. A bar check is
668 entered using the bar symbol, `@code{|}'. Whenever it is encountered
669 during interpretation, it should fall on a measure boundary. If it
670 does not, a warning is printed. Depending on the value of
671 @code{barCheckSynchronize}, the beginning of the measure will be
674 In the next example, the second bar check will signal an error:
676 \time 3/4 c2 e4 | g2 |
679 Bar checks can also be used in lyrics, for example
684 Twin -- kle | Twin -- kle
689 @cindex skipTypesetting
691 Failed bar checks are caused by entering incorrect
692 durations. Incorrect durations often completely garble up the score,
693 especially if it is polyphonic, so you should start correcting the
694 score by scanning for failed bar checks and incorrect durations. To
695 speed up this process, you can use @code{skipTypesetting}, described
698 @node Skipping corrected music
699 @subsection Skipping corrected music
701 The property @code{Score.skipTypesetting} can be used to switch on and
702 off typesetting completely during the interpretation phase. When
703 typesetting is switched off, the music is processed much more quickly.
704 This can be used to skip over the parts of a score that have already
705 been checked for errors:
707 @lilypond[fragment,raggedright,verbatim]
709 \set Score.skipTypesetting = ##t
711 \set Score.skipTypesetting = ##f
715 @node Automatic note splitting
716 @subsection Automatic note splitting
718 Long notes can be converted automatically to tied notes. This is done
719 by replacing the @internalsref{Note_heads_engraver} by the
720 @internalsref{Completion_heads_engraver}.
721 In the following examples, notes crossing the bar line are split and tied.
724 @lilypond[noindent,verbatim,relative=1]
726 \remove "Note_heads_engraver"
727 \consists "Completion_heads_engraver"
729 c2. c8 d4 e f g a b c8 c2 b4 a g16 f4 e d c8. c2
733 This engraver splits all running notes at the bar line, and inserts
734 ties. One of its uses is to debug complex scores: if the measures are
735 not entirely filled, then the ties exactly show how much each measure
740 Not all durations (especially those containing tuplets) can be
741 represented exactly; the engraver will not insert tuplets.
745 Examples: @inputfileref{input/regression,completion-heads.ly}.
747 Internals: @internalsref{Completion_heads_engraver}.
751 @section Staff notation
753 This section describes music notation that occurs on staff level,
754 such as keys, clefs and time signatures.
756 @cindex Staff notation
770 @subsection Staff symbol
772 @cindex adjusting staff symbol
774 Notes, dynamic signs, etc. are grouped
775 with a set of horizontal lines, into a staff (plural `staves'). In our
776 system, these lines are drawn using a separate layout object called
780 @cindex staff lines, setting number of
781 @cindex staff lines, setting thickness of
782 @cindex thickness of staff lines, setting
783 @cindex number of staff lines, setting
787 Internals: @internalsref{StaffSymbol}.
789 Examples: @inputfileref{input/test,staff-lines.ly},
790 @inputfileref{input/test,staff-size.ly}.
794 If a staff is ended halfway a piece, the staff symbol may not end
795 exactly on the bar line.
799 @subsection Key signature
800 @cindex Key signature
804 The key signature indicates the scale in which a piece is played. It
805 is denoted by a set of alterations (flats or sharps) at the start of
810 Setting or changing the key signature is done with the @code{\key}
813 @code{\key} @var{pitch} @var{type}
816 @cindex @code{\minor}
817 @cindex @code{\major}
818 @cindex @code{\minor}
819 @cindex @code{\ionian}
820 @cindex @code{\locrian}
821 @cindex @code{\aeolian}
822 @cindex @code{\mixolydian}
823 @cindex @code{\lydian}
824 @cindex @code{\phrygian}
825 @cindex @code{\dorian}
827 Here, @var{type} should be @code{\major} or @code{\minor} to get
828 @var{pitch}-major or @var{pitch}-minor, respectively.
829 The standard mode names @code{\ionian},
830 @code{\locrian}, @code{\aeolian}, @code{\mixolydian}, @code{\lydian},
831 @code{\phrygian}, and @code{\dorian} are also defined.
833 This command sets the context property
834 @internalsref{Staff}.@code{keySignature}. Non-standard key signatures
835 can be specified by setting this property directly.
837 Accidentals and key signatures often confuse new users, because
838 unaltered notes get natural signs depending on the key signature. The
839 tutorial explains why this is so in @ref{More about pitches}.
843 The ordering of a key cancellation is wrong when it is combined with
844 repeat bar lines. The cancellation is also printed after a line break.
848 Internals: @internalsref{KeyChangeEvent}, and @internalsref{KeySignature}.
850 @cindex @code{keySignature}
857 The clef indicates which lines of the staff correspond to which
862 The clef can be set or changed with the @code{\clef} command:
863 @lilypond[fragment,verbatim]
864 \key f\major c''2 \clef alto g'2
867 Supported clef-names include:
868 @c Moved standard clefs to the top /MB
872 @item treble, violin, G, G2
885 G clef on 1st line, so-called French violin clef
890 @cindex mezzosoprano clef
893 @cindex baritone clef
896 @cindex varbaritone clef
905 By adding @code{_8} or @code{^8} to the clef name, the clef is
906 transposed one octave down or up, respectively, and @code{_15} and
907 @code{^15} transposes by two octaves. The argument @var{clefname}
908 must be enclosed in quotes when it contains underscores or digits. For
912 @cindex choral tenor clef
913 @lilypond[verbatim,fragment,relative]
917 This command is equivalent to setting @code{clefGlyph},
918 @code{clefPosition} (which controls the Y position of the clef),
919 @code{centralCPosition} and @code{clefOctavation}. A clef is printed
920 when any of these properties are changed.
924 Internals: the object for this symbol is @internalsref{Clef}.
928 @node Ottava brackets
929 @subsection Ottava brackets
931 ``Ottava'' brackets introduce an extra transposition of an octave for
932 the staff. They are created by invoking the function
933 @code{set-octavation}:
939 @lilypond[verbatim,fragment]
948 The @code{set-octavation} function also takes -1 (for 8va bassa) and 2
949 (for 15ma) as arguments. Internally the function sets the properties
950 @code{ottavation} (e.g. to @code{"8va"}) and
951 @code{centralCPosition}. For overriding the text of the bracket, set
952 @code{ottavation} after invoking @code{set-octavation}, i.e.,
956 \set Staff.ottavation = #"8"
961 Internals: @internalsref{OttavaBracket}.
963 Examples: @inputfileref{input/regression,ottava.ly},
964 @inputfileref{input/regression,ottava-broken.ly}.
968 @code{set-octavation} will get confused when clef changes happen
969 during an octavation bracket.
972 @subsection Time signature
973 @cindex Time signature
977 Time signature indicates the metrum of a piece: a regular pattern of
978 strong and weak beats. It is denoted by a fraction at the start of the
983 The time signature is set or changed by the @code{\time}
985 @lilypond[fragment,verbatim]
986 \time 2/4 c'2 \time 3/4 c'2.
989 The symbol that is printed can be customized with the @code{style}
990 property. Setting it to @code{#'()} uses fraction style for 4/4 and
991 2/2 time. There are many more options for its layout. See
992 @inputfileref{input/test,time.ly} for more examples.
995 This command sets the property @code{timeSignatureFraction},
996 @code{beatLength} and @code{measureLength} in the @code{Timing}
997 context, which is normally aliased to @internalsref{Score}. The
998 property @code{measureLength} determines where bar lines should be
999 inserted, and how automatic beams should be generated. Changing the
1000 value of @code{timeSignatureFraction} also causes the symbol to be
1003 More options are available through the Scheme function
1004 @code{set-time-signature}. In combination with the
1005 @internalsref{Measure_grouping_engraver}, it will create
1006 @internalsref{MeasureGrouping} signs. Such signs ease reading
1007 rhythmically complex modern music. In the following example, the 9/8
1008 measure is subdivided in 2, 2, 2 and 3. This is passed to
1009 @code{set-time-signature} as the third argument @code{(2 2 2 3)}:
1012 \score { \notes \relative c'' {
1013 #(set-time-signature 9 8 '(2 2 2 3))
1014 g8[ g] d[ d] g[ g] a8[( bes g]) |
1015 #(set-time-signature 5 8 '(3 2))
1020 \translator { \StaffContext
1021 \consists "Measure_grouping_engraver"
1027 Internals: @internalsref{TimeSignature}, and @internalsref{Timing_engraver}.
1032 Automatic beaming does not use measure grouping specified with
1033 @code{set-time-signature}.
1035 @node Partial measures
1036 @subsection Partial measures
1039 @cindex partial measure
1040 @cindex measure, partial
1041 @cindex shorten measures
1042 @cindex @code{\partial}
1044 Partial measures, for example in upsteps, are entered using the
1045 @code{\partial} command:
1046 @lilypond[fragment,verbatim,relative=1]
1047 \partial 16*5 c16 cis d dis e | a2. c,4 | b2
1050 The syntax for this command is
1052 \partial @var{duration}
1054 This is internally translated into
1056 \set Timing.measurePosition = -@var{length of duration}
1059 The property @code{measurePosition} contains a rational number
1060 indicating how much of the measure has passed at this point.
1062 @node Unmetered music
1063 @subsection Unmetered music
1065 Bar lines and bar numbers are calculated automatically. For unmetered
1066 music (e.g. cadenzas), this is not desirable. By setting
1067 @code{Score.timing} to false, this automatic timing can be switched
1073 @cindex @code{\cadenzaOn}
1075 @cindex @code{\cadenzaOff}
1079 @subsection Bar lines
1083 @cindex measure lines
1087 Bar lines delimit measures, but are also used to indicate repeats.
1088 Normally, they are inserted automatically. Line breaks may only
1089 happen on bar lines.
1094 of bar lines can be forced with the @code{\bar} command:
1096 @lilypond[relative=1,fragment,verbatim]
1100 The following bar types are available:
1101 @lilypond[fragment,relative,raggedright,verbatim]
1114 For allowing line breaks, there is a special command,
1118 This will insert an invisible bar line, and allow line breaks at this
1121 In scores with many staves, a @code{\bar} command in one staff is
1122 automatically applied to all staves. The resulting bar lines are
1123 connected between different staves of a @internalsref{StaffGroup}:
1125 @lilypond[fragment,verbatim]
1126 << \context StaffGroup <<
1130 \new Staff { \clef bass c4 g e g } >>
1131 \new Staff { \clef bass c2 c2 } >>
1135 The command @code{\bar @var{bartype}} is a short cut for doing
1136 @code{\set Score.whichBar = @var{bartype}} Whenever
1137 @code{whichBar} is set to a string, a bar line of that type is
1138 created. At the start of a measure it is set to
1139 @code{defaultBarType}. The contents of @code{repeatCommands} are used
1140 to override default measure bars.
1142 Property @code{whichBar} can also be set directly, using @code{\set}
1143 or @code{\bar}. These settings take precedence over the automatic
1144 @code{whichBar} settings.
1147 @cindex repeatCommands
1148 @cindex defaultBarType
1150 You are encouraged to use @code{\repeat} for repetitions. See
1157 In this manual: @ref{Repeats}.
1160 Internals: the bar line objects that are created at
1161 @internalsref{Staff} level are called @internalsref{BarLine}, the bar
1162 lines that span staves are @internalsref{SpanBar}s.
1164 @cindex bar lines at start of system
1165 @cindex start of system
1167 The bar lines at the start of each system are
1168 @internalsref{SystemStartBar}, @internalsref{SystemStartBrace}, and
1169 @internalsref{SystemStartBracket}. Only one of these types is created
1170 in every context, and that type is determined by the property
1171 @code{systemStartDelimiter}.
1173 Examples: @inputfileref{input/test,bar-lines.ly},
1179 The easiest way to enter fragments with more than one voice on a staff
1180 is to split chords using the separator @code{\\}. You can use it for
1181 small, short-lived voices or for single chords:
1183 @lilypond[verbatim,fragment]
1184 \context Staff \relative c'' {
1185 c4 << { f d e } \\ { b c2 } >>
1186 c4 << g' \\ b, \\ f' \\ d >>
1190 The separator causes @internalsref{Voice} contexts@footnote{Polyphonic
1191 voices are sometimes called "layers" other notation packages}
1193 to be instantiated. They bear the names @code{"1"}, @code{"2"}, etc. In
1194 each of these contexts, vertical direction of slurs, stems, etc. is set
1197 @cindex @code{\voiceOne}
1198 @cindex @code{\voiceFour}
1200 This can also be done by instantiating @internalsref{Voice} contexts
1201 by hand, and using @code{\voiceOne}, up to @code{\voiceFour} to assign
1202 a stem directions and horizontal shift for each part:
1205 @lilypond[raggedright,verbatim]
1207 \context Staff << \new Voice { \voiceOne cis2 b }
1208 \new Voice { \voiceThree b4 ais ~ ais4 gis4 }
1209 \new Voice { \voiceTwo fis4~ fis4 f ~ f } >>
1213 The command @code{\oneVoice} will revert back to the normal setting.
1214 @cindex @code{\oneVoice}
1217 Normally, note heads with a different number of dots are not merged, but
1218 when the object property @code{merge-differently-dotted} is set in
1219 the @internalsref{NoteCollision} object, they are merged:
1220 @lilypond[verbatim,fragment,raggedright]
1221 \relative c'' \context Voice << {
1223 \override Staff.NoteCollision
1224 #'merge-differently-dotted = ##t
1226 } \\ { g8.[ f16] g8.[ f16] }
1230 Similarly, you can merge half note heads with eighth notes, by setting
1231 @code{merge-differently-headed}:
1232 @lilypond[fragment,relative=2,verbatim]
1235 \override Staff.NoteCollision
1236 #'merge-differently-headed = ##t
1237 c8 c4. } \\ { c2 c2 } >>
1240 LilyPond also vertically shifts rests that are opposite of a stem:
1243 @lilypond[raggedright,fragment,verbatim]
1244 \context Voice << c''4 \\ r4 >>
1252 @cindex @code{\oneVoice}
1254 @cindex @code{\voiceOne}
1256 @cindex @code{\voiceTwo}
1258 @cindex @code{\voiceThree}
1260 @cindex @code{\voiceFour}
1264 The following commands specify in what chords of the current voice
1265 should be shifted: the outer voice has @code{\shiftOff}, and the inner
1266 voices have @code{\shiftOn}, @code{\shiftOnn}, etc.
1269 @cindex @code{\shiftOn}
1271 @cindex @code{\shiftOnn}
1273 @cindex @code{\shiftOnnn}
1275 @cindex @code{\shiftOff}
1282 Internals: the objects responsible for resolving collisions are
1283 @internalsref{NoteCollision} and @internalsref{RestCollision}.
1285 Examples: See also example files
1286 @inputfileref{input/regression,collision-dots.ly},
1287 @inputfileref{input/regression,collision-head-chords.ly},
1288 @inputfileref{input/regression,collision-heads.ly},
1289 @inputfileref{input/regression,collision-mesh.ly}, and
1290 @inputfileref{input/regression,collisions.ly}.
1295 Resolving collisions is a intricate subject, and only a few situations
1296 are handled. When LilyPond cannot cope, the @code{force-hshift}
1297 property of the @internalsref{NoteColumn} object and pitched rests can
1298 be used to override typesetting decisions.
1300 When using @code{merge-differently-headed} with an upstem 8th or a shorter
1301 note, and a downstem half note, the 8th note gets the wrong offset.
1303 There is no support for clusters where the same note occurs with
1304 different accidentals in the same chord. In this case, it is
1305 recommended to use enharmonic transcription, or to use special cluster
1306 notation (see @ref{Clusters}).
1311 Beams are used to group short notes into chunks that are aligned with
1312 the metrum. They are inserted automatically in most cases:
1314 @lilypond[fragment,verbatim,relative=2]
1315 \time 2/4 c8 c c c \time 6/8 c c c c8. c16 c8
1318 When these automatic decisions are not good enough, beaming can be
1319 entered explicitly. It is also possible to define beaming patterns
1320 that differ from the defaults.
1322 Individual notes may be marked with @code{\noBeam}, to prevent them
1325 @lilypond[fragment,verbatim,relative=2]
1326 \time 2/4 c8 c\noBeam c c
1332 Internals: @internalsref{Beam}.
1335 @cindex Automatic beams
1338 * Setting automatic beam behavior::
1342 @subsection Manual beams
1343 @cindex beams, manual
1347 In some cases it may be necessary to override the automatic beaming
1348 algorithm. For example, the autobeamer will not put beams over rests
1349 or bar lines. Such beams are specified by manually: the begin and end
1350 point are marked with @code{[} and @code{]}:
1352 @lilypond[fragment,relative,verbatim]
1354 r4 r8[ g' a r8] r8 g[ | a] r8
1358 @cindex @code{stemLeftBeamCount}
1360 Normally, beaming patterns within a beam are determined automatically.
1361 When this mechanism fouls up, the properties
1362 @code{stemLeftBeamCount} and @code{stemRightBeamCount} can
1363 be used to control the beam subdivision on a stem. If either property
1364 is set, its value will be used only once, and then it is erased:
1366 @lilypond[fragment,relative,verbatim]
1369 f8[ r16 \set stemLeftBeamCount = #1 f g a]
1372 @cindex @code{stemRightBeamCount}
1375 The property @code{subdivideBeams} can be set in order to subdivide
1376 all 16th or shorter beams at beat positions, as defined by the
1377 @code{beatLength} property. This accomplishes the same effect as
1378 twiddling with @code{stemLeftBeamCount} and @code{stemRightBeamCount},
1379 but it take less typing:
1382 @lilypond[relative=1,verbatim,noindent]
1384 \set subdivideBeams = ##t
1386 \set Score.beatLength = #(ly:make-moment 1 8)
1389 @cindex subdivideBeams
1391 Kneed beams are inserted automatically, when a large gap is detected
1392 between the note heads. This behavior can be tuned through the object
1393 property @code{auto-knee-gap}.
1395 Normally, line breaks are forbidden when beams cross bar lines. This
1396 behavior can be changed by setting @code{allowBeamBreak}.
1398 @cindex @code{allowBeamBreak}
1399 @cindex beams and line breaks
1401 @cindex beams, kneed
1403 @cindex auto-knee-gap
1409 @cindex Frenched staves
1411 Automatically kneed beams cannot be used together with hidden staves.
1416 @node Setting automatic beam behavior
1417 @subsection Setting automatic beam behavior
1419 @cindex @code{autoBeamSettings}
1420 @cindex @code{(end * * * *)}
1421 @cindex @code{(begin * * * *)}
1422 @cindex automatic beams, tuning
1423 @cindex tuning automatic beaming
1425 @c [TODO: use \applycontext]
1427 In normal time signatures, automatic beams can start on any note but can
1428 only end in a few positions within the measure: beams can end on a beat,
1429 or at durations specified by the properties in
1430 @code{autoBeamSettings}. The defaults for @code{autoBeamSettings}
1431 are defined in @file{scm/auto-beam.scm}.
1433 The value of @code{autoBeamSettings} is changed with two functions:
1435 #(override-auto-beam-setting
1436 '(@var{be} @var{p} @var{q} @var{n} @var{m}) @var{a} @var{b}
1438 #(revert-auto-beam-setting '(@var{be} @var{p} @var{q} @var{n} @var{m}))
1440 Here, @var{be} is the symbol @code{begin} or @code{end}. It determines
1441 whether the rule applies to begin or end-points. The quantity
1442 @var{p}/@var{q} refers to the length of the beamed notes (and `@code{*
1443 *}' designates notes of any length), @var{n}/@var{M} refers to a time
1444 signature (wildcards `@code{* *}' may be entered to designate all time
1445 signatures), @var{a}/@var{b} is a duration. By default, this command
1446 changes settings for the current voice. It is also possible to adjust
1447 settings at higher contexts, by adding a @var{context} argument.
1449 For example, if automatic beams should end on every quarter note, use
1452 #(override-auto-beam-setting '(end * * * *) 1 4)
1454 Since the duration of a quarter note is 1/4 of a whole note, it is
1455 entered as @code{(ly:make-moment 1 4)}.
1457 The same syntax can be used to specify beam starting points. In this
1458 example, automatic beams can only end on a dotted quarter note:
1460 #(override-auto-beam-setting '(end * * * *) 3 8)
1462 In 4/4 time signature, this means that automatic beams could end only on
1463 3/8 and on the fourth beat of the measure (after 3/4, that is 2 times
1464 3/8, has passed within the measure).
1466 Rules can also be restricted to specific time signatures. A rule that
1467 should only be applied in @var{N}/@var{M} time signature is formed by
1468 replacing the second asterisks by @var{N} and @var{M}. For example, a
1469 rule for 6/8 time exclusively looks like
1471 #(override-auto-beam-setting '(begin * * 6 8) @dots{})
1474 If a rule should be to applied only to certain types of beams, use the
1475 first pair of asterisks. Beams are classified according to the
1476 shortest note they contain. For a beam ending rule that only applies
1477 to beams with 32nd notes (and no shorter notes), use @code{(end 1 32 *
1480 If a score ends while an automatic beam has not been ended and is still
1481 accepting notes, this last beam will not be typeset at all.
1483 @cindex automatic beam generation
1485 @cindex @code{autoBeaming}
1488 For melodies that have lyrics, you may want to switch off
1489 automatic beaming. This is done by setting @code{autoBeaming} to
1494 @cindex @code{\autoBeamOff}
1495 @code{\autoBeamOff},
1496 @cindex @code{\autoBeamOn}
1502 The rules for ending a beam depend on the shortest note in a beam.
1503 So, while it is possible to have different ending rules for eight
1504 beams and sixteenth beams, a beam that contains both eight and
1505 sixteenth notes will use the rules for the sixteenth beam.
1507 In the example below, the autobeamer makes eight beams and sixteenth
1508 end at 3 eights; the third beam can only be corrected by specifying
1511 @lilypond[raggedright,fragment,relative,noverbatim,quote]
1512 #(override-auto-beam-setting '(end * * * *) 3 8)
1513 % rather show case where it goes wrong
1514 %\time 12/8 c'8 c c c16 c c c c c c[ c c c] c8[ c] c4
1515 \time 12/8 c'8 c c c16 c c c c c c c c c c8 c c4
1517 It is not possible to specify beaming parameters that act differently in
1518 different parts of a measure. This means that it is not possible to use
1519 automatic beaming in irregular meters such as @code{5/8}.
1522 @section Accidentals
1525 This section describes how to change the way that accidentals are
1526 inserted automatically before the running notes.
1530 * Using the predefined accidental variables::
1531 * Customized accidental rules::
1534 @node Using the predefined accidental variables
1535 @subsection Using the predefined accidental variables
1538 Common rules for typesetting macros have been canned in a
1539 function. This function is called as follows:
1541 @cindex @code{set-accidental-style}
1543 #(set-accidental-style 'modern 'Voice)
1546 The function takes two arguments: a symbol that denotes the style (in
1547 the example, @code{modern}), and another symbol that denotes the
1548 context name (in this example, @code{Staff}). If no context name is
1549 supplied, @code{Staff} is the default.
1551 The following styles are supported:
1554 This is the default typesetting behavior. It should correspond
1555 to 18th century common practice: Accidentals are
1556 remembered to the end of the measure in which they occur and
1557 only on their own octave.
1561 The normal behavior is to remember the accidentals on
1562 Staff-level. This variable, however, typesets accidentals
1563 individually for each voice. Apart from that, the rule is similar to
1566 This leads to some weird and often unwanted results
1567 because accidentals from one voice do not get canceled in other
1569 @lilypond[raggedright,relative,fragment,verbatim,quote]
1571 #(set-accidental-style 'voice)
1577 Hence you should only use @code{voice} if the voices
1578 are to be read solely by individual musicians. If the staff is to be
1579 used by one musician (e.g. a conductor) then you use
1580 @code{modern} or @code{modern-cautionary}
1584 @cindex @code{modern} style accidentals
1585 This rule corresponds to the common practice in the 20th
1587 This rule prints the same accidentals as @code{default}, but temporary
1588 accidentals also are canceled in other octaves. Furthermore,
1589 in the same octave, they also get canceled in the following
1592 @lilypond[raggedright,fragment,verbatim]
1593 #(set-accidental-style 'modern)
1594 cis' c'' cis'2 | c'' c'
1597 @item @code{modern-cautionary}
1598 @cindex @code{modern-cautionary}
1599 This rule is similar to @code{modern}, but the
1600 ``extra'' accidentals (the ones not typeset by
1601 @code{default}) are typeset as cautionary accidentals.
1602 They are printed in reduced size or with parentheses:
1603 @lilypond[raggedright,fragment,verbatim]
1604 #(set-accidental-style 'modern-cautionary)
1605 cis' c'' cis'2 | c'' c'
1608 @cindex @code{modern-voice}
1610 is used for multivoice accidentals to be read both by musicians
1611 playing one voice and musicians playing all voices. Accidentals are
1612 typeset for each voice, but they @emph{are} canceled across voices in
1613 the same @internalsref{Staff}.
1615 @cindex @code{modern-voice-cautionary}
1616 @item modern-voice-cautionary
1617 is the same as @code{modern-voice}, but with the extra
1618 accidentals (the ones not typeset by @code{voice}) typeset
1619 as cautionaries. Even though all accidentals typeset by
1620 @code{default} @emph{are} typeset by this variable then
1621 some of them are typeset as cautionaries.
1624 @cindex @code{piano} accidentals
1625 20th century practice for piano notation. Very similar to
1626 @code{modern} but accidentals also get canceled
1627 across the staves in the same @internalsref{GrandStaff} or
1628 @internalsref{PianoStaff}.
1630 @item piano-cautionary
1631 @cindex @code{#(set-accidental-style 'piano-cautionary)}
1632 As @code{#(set-accidental-style 'piano)' , str)} but with the extra accidentals
1633 typeset as cautionaries.
1636 @cindex @code{no-reset} accidental style
1637 Same as @code{default} but with accidentals lasting
1638 ``forever'' and not only until the next measure:
1639 @lilypond[raggedright,fragment,verbatim,relative]
1640 #(set-accidental-style 'no-reset)
1645 This is sort of the opposite of @code{no-reset}: Accidentals
1646 are not remembered at all---and hence all accidentals are
1647 typeset relative to the key signature, regardless of what was
1648 before in the music:
1650 @lilypond[raggedright,fragment,verbatim,relative]
1651 #(set-accidental-style 'forget)
1652 \key d\major c4 c cis cis d d dis dis
1656 @node Customized accidental rules
1657 @subsection Customized accidental rules
1659 For determining when to print an accidental, several different rules
1660 are tried. The rule that gives the highest number of accidentals is
1661 used. Each rule consists of
1664 In which context is the rule applied. For example, if
1665 @var{context} is @internalsref{Score} then all staves share
1666 accidentals, and if @var{context} is @internalsref{Staff} then all
1667 voices in the same staff share accidentals, but staves do not.
1670 Whether the accidental changes all octaves or only the current
1671 octave. Valid choices are
1675 This is the default algorithm. Accidentals are typeset if the note changes
1676 the accidental of that note in that octave. Accidentals lasts to the end of the measure
1677 and then as many measures as specified in the value. I.e. 1 means to the end
1678 of next measure, -1 means to the end of previous measure (that is: no duration at all), etc. #t means forever.
1680 Accidentals are typeset if the note is different from
1681 the previous note on the same pitch in any octave. The value has same meaning as in
1687 Over how many bar lines the accidental lasts.
1688 If @var{laziness} is @code{-1} then the accidental is forget
1689 immediately, and if @var{laziness} is @code{#t} then the accidental
1696 Internals: @internalsref{Accidental_engraver},
1697 @internalsref{Accidental}, and @internalsref{AccidentalPlacement}.
1702 Currently the simultaneous notes are considered to be entered in
1703 sequential mode. This means that in a chord the accidentals are
1704 typeset as if the notes in the chord happened once at a time - in the
1705 order in which they appear in the input file.
1707 This is only a problem when there are simultaneous notes whose
1708 accidentals depend on each other. The problem only occurs when using
1709 non-default accidentals. In the default scheme, accidentals only
1710 depend on other accidentals with the same pitch on the same staff, so
1711 no conflicts possible.
1713 This example shows two examples of the same music giving different
1714 accidentals depending on the order in which the notes occur in the
1717 @lilypond[raggedright,fragment,verbatim]
1718 \set Staff.autoAccidentals = #'( Staff (any-octave . 0) )
1719 cis'4 <c'' c'> r2 | cis'4 <c' c''> r2
1720 | <cis' c''> r | <c'' cis'> r |
1723 This problem can be solved by manually inserting @code{!} and @code{?}
1724 for the problematic notes.
1726 @node Expressive marks
1727 @section Expressive marks
1730 @c todo: should change ordering
1731 @c where to put text spanners, metronome marks,
1740 * Analysis brackets::
1742 * Fingering instructions::
1753 A slur indicates that notes are to be played bound or @emph{legato}.
1757 They are entered using parentheses:
1758 @lilypond[relative=1,fragment,verbatim,center]
1759 f( g)( a) a8 b( a4 g2 f4)
1764 @c TODO: should explain that ^( and _( set directions
1765 @c should set attachments with ^ and _ ?
1767 Slurs avoid crossing stems, and are generally attached to note heads.
1768 However, in some situations with beams, slurs may be attached to stem
1769 ends. If you want to override this layout you can do this through the
1770 object property @code{attachment} of @internalsref{Slur} in
1771 @internalsref{Voice} context. Its value is a pair of symbols, specifying
1772 the attachment type of the left and right end points:
1774 @lilypond[fragment,relative,verbatim]
1776 \override Stem #'length = #5.5
1778 \override Slur #'attachment = #'(stem . stem)
1782 If a slur would strike through a stem or beam, the slur will be moved
1783 away upward or downward. If this happens, attaching the slur to the
1784 stems might look better:
1786 @lilypond[fragment,relative,verbatim]
1789 \override Slur #'attachment = #'(stem . stem)
1796 @cindex @code{\slurUp}
1798 @cindex @code{\slurDown}
1800 @cindex @code{\slurBoth}
1802 @cindex @code{\slurDotted}
1804 @cindex @code{\slurSolid}
1809 Internals: @seeinternals{Slur}, and @internalsref{SlurEvent}.
1814 Producing nice slurs is a difficult problem, and LilyPond currently
1815 uses a simple, empiric method to produce slurs. In some cases, its
1819 @cindex Adjusting slurs
1821 @node Phrasing slurs
1822 @subsection Phrasing slurs
1824 @cindex phrasing slurs
1825 @cindex phrasing marks
1827 A phrasing slur (or phrasing mark) connects chords and is used to
1828 indicate a musical sentence. It is started using @code{\(} and @code{\)}
1831 @lilypond[fragment,verbatim,center,relative]
1832 \time 6/4 c'\( d( e) f( e) d\)
1835 Typographically, the phrasing slur behaves almost exactly like a
1836 normal slur. However, they are treated as different objects. A
1837 @code{\slurUp} will have no effect on a phrasing slur; instead, you
1838 should use @code{\phrasingSlurUp}, @code{\phrasingSlurDown}, and
1839 @code{\phrasingSlurBoth}.
1841 The commands @code{\slurUp}, @code{\slurDown}, and @code{\slurBoth}
1842 will only affect normal slurs and not phrasing slurs.
1846 @cindex @code{\phrasingSlurUp}
1847 @code{\phrasingSlurUp},
1848 @cindex @code{\phrasingSlurDown}
1849 @code{\phrasingSlurDown},
1850 @cindex @code{\phrasingSlurBoth}
1851 @code{\phrasingSlurBoth}.
1855 Internals: see also @internalsref{PhrasingSlur}, and
1856 @internalsref{PhrasingSlurEvent}.
1860 Phrasing slurs have the same limitations in their formatting as normal
1861 slurs. Putting phrasing slurs over rests leads to spurious warnings.
1864 @subsection Breath marks
1866 Breath marks are entered using @code{\breathe}:
1869 @lilypond[fragment,relative,verbatim]
1873 The glyph of the breath mark can be tweaked by overriding the
1874 @code{text} property of the @code{BreathingSign} layout object with
1875 any markup text. For example,
1876 @lilypond[fragment,verbatim,relative]
1878 \override BreathingSign #'text
1879 = #(make-musicglyph-markup "scripts-rvarcomma")
1886 Internals: @internalsref{BreathingSign},
1887 @internalsref{BreathingSignEvent}.
1889 Examples: @inputfileref{input/regression,breathing-sign.ly}.
1892 @node Metronome marks
1893 @subsection Metronome marks
1896 @cindex beats per minute
1897 @cindex metronome marking
1899 Metronome settings can be entered as follows:
1901 \tempo @var{duration} = @var{per-minute}
1904 In the MIDI output, they are interpreted as a tempo change, and in the
1905 paper output, a metronome marking is printed:
1906 @cindex @code{\tempo}
1907 @lilypond[fragment,verbatim]
1913 Internals: @internalsref{MetronomeChangeEvent}.
1918 @subsection Text spanners
1919 @cindex Text spanners
1921 Some performance indications, e.g. @i{rallentando} or @i{accelerando},
1922 are written as texts, and extended over many measures with dotted
1923 lines. You can create such texts using text spanners: attach
1924 @code{\startTextSpan} and @code{\stopTextSpan} to the
1925 start and ending note of the spanner.
1927 The string to be printed, as well as the style, is set through object
1930 @lilypond[fragment,relative,verbatim]
1932 \override TextSpanner #'direction = #-1
1933 \override TextSpanner #'edge-text = #'("rall " . "")
1934 c2\startTextSpan b c\stopTextSpan a }
1940 Internals @internalsref{TextSpanEvent},
1941 @internalsref{TextSpanner}.
1943 Examples: @inputfileref{input/regression,text-spanner.ly}.
1946 @node Analysis brackets
1947 @subsection Analysis brackets
1949 @cindex phrasing brackets
1950 @cindex musicological analysis
1951 @cindex note grouping bracket
1953 Brackets are used in musical analysis to indicate structure in musical
1954 pieces. LilyPond supports a simple form of nested horizontal brackets.
1955 To use this, add the @internalsref{Horizontal_bracket_engraver} to
1956 @internalsref{Staff} context. A bracket is started with
1957 @code{\startGroup} and closed with @code{\stopGroup}:
1959 @lilypond[raggedright,verbatim]
1960 \score { \notes \relative c'' {
1961 c4\startGroup\startGroup
1964 c4\stopGroup\stopGroup
1966 \paper { \translator {
1967 \StaffContext \consists "Horizontal_bracket_engraver"
1973 Internals: @internalsref{HorizontalBracket},
1974 @internalsref{NoteGroupingEvent}.
1976 Examples: @inputfileref{input/regression,note-group-bracket.ly}.
1980 @subsection Articulations
1981 @cindex Articulations
1983 @cindex articulations
1987 A variety of symbols can appear above and below notes to indicate
1988 different characteristics of the performance. They are added to a note
1989 by adding a dash and the character signifying the
1990 articulation. They are demonstrated here:
1992 @lilypondfile[]{script-abbreviations.ly}
1994 The meanings of these shorthands can be changed: see
1995 @file{ly/script-init.ly} for examples.
1998 The script is automatically placed, but if you need to force
1999 directions, you can use @code{_} to force them down, or @code{^} to
2001 @lilypond[fragment,verbatim]
2005 Other symbols can be added using the syntax
2006 @var{note}@code{\}@var{name}, e.g. @code{c4\fermata}. Again, they
2007 can be forced up or down using @code{^} and @code{_},
2010 @lilypond[verbatim,fragment,relative=2]
2011 c\fermata c^\fermata c_\fermata
2018 @cindex staccatissimo
2027 @cindex organ pedal marks
2036 @cindex prallmordent
2040 @cindex thumb marking
2045 @lilypondfile[]{script-chart.ly}
2050 @cindex @code{\scriptUp}
2052 @cindex @code{\scriptDown}
2054 @cindex @code{\scriptBoth}
2059 Internals: @internalsref{ScriptEvent}, and @internalsref{Script}.
2063 These note ornaments appear in the printed output but have no
2064 effect on the MIDI rendering of the music.
2067 @node Fingering instructions
2068 @subsection Fingering instructions
2072 Fingering instructions can be entered using
2074 @var{note}-@var{digit}
2076 For finger changes, use markup texts:
2078 @lilypond[verbatim,raggedright,fragment]
2079 c'4-1 c'4-2 c'4-3 c'4-4
2080 c'^\markup { \fontsize #-3 \number "2-3" }
2083 @cindex finger change
2088 You can use the thumb-script to indicate that a note should be
2089 played with the thumb (e.g. in cello music):
2091 @lilypond[verbatim,raggedright,fragment]
2092 <a' a''-3>8(_\thumb <b' b''-3>)_\thumb
2093 <c'' c'''-3>(_\thumb <d'' d'''-3>)_\thumb
2096 Fingerings for chords can also be added to individual notes
2097 of the chord by adding them after the pitches:
2098 @lilypond[verbatim,raggedright,fragment,relative=1]
2099 < c-1 e-2 g-3 b-5 > 4
2103 In this case, setting @code{fingeringOrientations} will put fingerings next
2106 @lilypond[verbatim,raggedright,fragment,relative=1]
2107 \set fingeringOrientations = #'(left down)
2108 <c-1 es-2 g-4 bes-5 > 4
2109 \set fingeringOrientations = #'(up right down)
2110 <c-1 es-2 g-4 bes-5 > 4
2113 By using single note chords, fingering instructions can be put close
2114 to note heads in monophonic music.
2118 Internals: @internalsref{FingerEvent}, and @internalsref{Fingering}.
2120 Examples: @inputfileref{input/regression,finger-chords.ly}.
2123 @subsection Text scripts
2124 @cindex Text scripts
2126 @cindex text items, non-empty
2127 @cindex non-empty texts
2129 It is possible to place arbitrary strings of text or markup text (see
2130 @ref{Text markup}) above or below notes by using a string:
2131 @code{c^"text"}. By default, these indications do not influence the
2132 note spacing, but by using the command @code{\fatText}, the widths
2133 will be taken into account:
2135 @lilypond[fragment,raggedright,verbatim] \relative c' {
2136 c4^"longtext" \fatText c4_"longlongtext" c4 }
2139 It is possible to use @TeX{} commands in the strings, but this should
2140 be avoided because the exact dimensions of the string can then no
2145 @cindex @code{\fatText}
2147 @cindex @code{\emptyText}
2152 In this manual: @ref{Text markup}.
2154 Internals: @internalsref{TextScriptEvent}, @internalsref{TextScript}.
2160 @subsection Grace notes
2163 @c should have blurb about accaciatura / appogiatura
2165 @cindex @code{\grace}
2169 Grace notes are ornaments that are written out. The most common ones
2170 are acciaccatura, which should be played as very short. It is denoted
2171 by a slurred small note with a slashed stem. The appoggiatura is a
2172 grace note that takes a fixed fraction of the main note, is and
2173 denoted as a slurred note in small print without a slash.
2174 They are entered with the commands @code{\acciaccatura} and
2175 @code{\appoggiatura}, as demonstrated in the following example:
2178 @cindex appoggiatura
2179 @cindex acciaccatura
2181 @lilypond[relative=2,verbatim,fragment]
2182 b4 \acciaccatura d8 c4 \appoggiatura e8 d4
2183 \acciaccatura { g16[ f] } e4
2186 Both are special forms of the @code{\grace} command. By prefixing this
2187 keyword to a music expression, a new one is formed, which will be
2188 printed in a smaller font and takes up no logical time in a measure.
2189 @lilypond[relative=2,verbatim,fragment]
2191 \grace { c16[ d16] } c2 c4
2195 Unlike @code{\acciaccatura} and @code{\appoggiatura}, the
2196 @code{\grace} command does not start a slur.
2198 Internally, timing for grace notes is done using a second, `grace'
2199 time. Every point in time consists of two rational numbers: one
2200 denotes the logical time, one denotes the grace timing. The above
2201 example is shown here with timing tuples:
2203 @lilypond[raggedright]
2206 c4 \grace c16 c4 \grace {
2209 \new Lyrics \lyrics {
2212 ( \fraction 1 4 , \fraction -1 16 ) } 16 }
2213 \markup { (\fraction 1 4 , 0 ) } 4
2215 \markup { (\fraction 2 4 , \fraction "-1" 8 ) } 16
2216 \markup { (\fraction 2 4 , \fraction "-1" 16 ) } 16
2218 \markup { ( \fraction 2 4 , 0 ) }
2223 The placement of grace notes is synchronized between different staves.
2224 In the following example, there are two sixteenth graces notes for
2225 every eighth grace note:
2227 @lilypond[relative=2,verbatim,fragment]
2228 << \new Staff { e4 \grace { c16[ d e f] } e4 }
2229 \new Staff { c'4 \grace { g8[ b] } c4 } >>
2234 If you want to end a note with a grace, then the standard trick
2235 is to put the grace notes after a ``space note'', e.g.
2236 @lilypond[fragment,verbatim,relative=2]
2239 { s2 \grace { c16[ d] } } >>
2245 By adjusting the duration of the skip note (here it is a half-note),
2246 the space between the main-note and the grace is adjusted.
2249 A @code{\grace} section will introduce special typesetting settings,
2250 for example, to produce smaller type, and set directions. Hence, when
2251 introducing layout tweaks, they should be inside the grace section,
2253 @lilypond[fragment,verbatim,relative=1]
2256 \override Stem #'direction = #-1
2258 \revert Stem #'direction
2265 The overrides should also be reverted inside the grace section.
2267 If the layout of grace sections must be changed throughout the music,
2268 then this can be accomplished through the function
2269 @code{add-grace-property}. The following example
2270 undefines the Stem direction grace section, so stems do not always
2275 #(add-grace-property "Voice" Stem direction '())
2281 Another option is to change the variables @code{startGraceMusic},
2282 @code{stopGraceMusic}, @code{startAccacciaturaMusic},
2283 @code{stopAccacciaturaMusic}, @code{startAppoggiaturaMusic},
2284 @code{stopAppoggiaturaMusic}. More information is in the file
2285 @file{ly/grace-init.ly}.
2290 Internals: @internalsref{GraceMusic}.
2294 A score that starts with an @code{\grace} section needs an explicit
2295 @code{\context Voice} declaration, otherwise the main note and grace
2296 note end up on different staves.
2298 Grace note synchronization can also lead to surprises. Staff notation,
2299 such as key signatures, bar lines, etc. are also synchronized. Take
2300 care when you mix staves with grace notes and staves without, for example,
2302 @lilypond[relative=2,verbatim,fragment]
2303 << \new Staff { e4 \bar "|:" \grace c16 d4 }
2304 \new Staff { c4 \bar "|:" d4 } >>
2307 Grace sections should only be used within sequential music
2308 expressions. Nesting or juxtaposing grace sections is not supported,
2309 and might produce crashes or other errors.
2313 @subsection Glissando
2316 @cindex @code{\glissando}
2318 A glissando is a smooth change in pitch. It is denoted by a line or a
2319 wavy line between two notes.
2323 A glissando line can be requested by attaching a @code{\glissando} to
2326 @lilypond[fragment,relative,verbatim]
2332 Internals: @internalsref{Glissando}, and @internalsref{GlissandoEvent}.
2337 Adding additional texts (such as @emph{gliss.}) is not supported.
2341 @subsection Dynamics
2354 @cindex @code{\ffff}
2364 Absolute dynamic marks are specified using a command after a note:
2365 @code{c4\ff}. The available dynamic marks are @code{\ppp},
2366 @code{\pp}, @code{\p}, @code{\mp}, @code{\mf}, @code{\f}, @code{\ff},
2367 @code{\fff}, @code{\fff}, @code{\fp}, @code{\sf}, @code{\sff},
2368 @code{\sp}, @code{\spp}, @code{\sfz}, and @code{\rfz}:
2370 @lilypond[verbatim,raggedright,fragment,relative]
2371 c'\ppp c\pp c \p c\mp c\mf c\f c\ff c\fff
2377 @cindex @code{\decr}
2378 @cindex @code{\rced}
2385 A crescendo mark is started with @code{\<} and terminated with
2386 @code{\!}. A decrescendo is started with @code{\>} and also terminated
2387 with @code{\!}. Because these marks are bound to notes, if you must
2388 use spacer notes if multiple marks during one note are needed:
2390 @lilypond[fragment,verbatim,center,quote]
2391 c''\< c''\! d''\decr e''\rced
2392 << f''1 { s4 s4\< s4\! \> s4\! } >>
2394 This may give rise to very short hairpins. Use @code{minimum-length}
2395 in @internalsref{Voice}.@internalsref{Hairpin} to lengthen them, for
2399 \override Staff.Hairpin #'minimum-length = #5
2402 You can also use a text saying @emph{cresc.} instead of hairpins. Here
2403 is an example how to do it:
2405 @lilypond[fragment,relative=2,verbatim]
2406 c4 \cresc c4 c c c \endcresc c4
2412 You can also supply your own texts:
2413 @lilypond[fragment,relative,verbatim]
2415 \set crescendoText = \markup { \italic "cresc. poco" }
2416 \set crescendoSpanner = #'dashed-line
2426 @cindex @code{\dynamicUp}
2428 @cindex @code{\dynamicDown}
2429 @code{\dynamicDown},
2430 @cindex @code{\dynamicBoth}
2431 @code{\dynamicBoth}.
2433 @cindex direction, of dynamics
2437 Internals: @internalsref{CrescendoEvent}, @internalsref{DecrescendoEvent}, and
2438 @internalsref{AbsoluteDynamicEvent}.
2440 Dynamics are objects of @internalsref{DynamicText} and
2441 @internalsref{Hairpin}. Vertical positioning of these symbols is
2442 handled by the @internalsref{DynamicLineSpanner} object.
2444 If you want to adjust padding or vertical direction of the dynamics, you
2445 must set properties for the @internalsref{DynamicLineSpanner} object.
2453 @cindex @code{\repeat}
2456 Repetition is a central concept in music, and multiple notations exist
2457 for repetitions. In LilyPond, most of these notations can be captured
2458 in a uniform syntax. One of the advantages is that they can be
2459 rendered in MIDI accurately.
2461 The following types of repetition are supported:
2465 Repeated music is fully written (played) out. Useful for MIDI
2466 output, and entering repetitive music.
2469 This is the normal notation: Repeats are not written out, but
2470 alternative endings (volte) are printed, left to right.
2474 Alternative endings are written stacked. This has limited use but may be
2475 used to typeset two lines of lyrics in songs with repeats, see
2476 @inputfileref{input,star-spangled-banner.ly}.
2484 Make beat or measure repeats. These look like percent signs.
2490 * Repeats and MIDI::
2491 * Manual repeat commands::
2493 * Tremolo subdivisions::
2498 @subsection Repeat syntax
2502 LilyPond has one syntactic construct for specifying different types of
2503 repeats. The syntax is
2506 \repeat @var{variant} @var{repeatcount} @var{repeatbody}
2509 If you have alternative endings, you may add
2510 @cindex @code{\alternative}
2512 \alternative @code{@{} @var{alternative1}
2514 @var{alternative3} @dots{} @code{@}}
2516 where each @var{alternative} is a music expression. If you do not
2517 give enough alternatives for all of the repeats, then the first
2518 alternative is assumed to be played more than once.
2520 Normal notation repeats are used like this:
2521 @lilypond[fragment,verbatim,relative=1]
2523 \repeat volta 2 { c4 d e f }
2524 \repeat volta 2 { f e d c }
2527 With alternative endings:
2528 @lilypond[fragment,verbatim,relative=1]
2530 \repeat volta 2 {c4 d e f}
2531 \alternative { {d2 d} {f f,} }
2535 @lilypond[fragment,verbatim,relative=1]
2538 \repeat volta 4 { e | c2 d2 | e2 f2 | }
2539 \alternative { { g4 g g } { a | a a a a | b2. } }
2545 If you do a nested repeat like
2554 then it is ambiguous to which @code{\repeat} the @code{\alternative}
2555 belongs. This ambiguity is resolved by always having the
2556 @code{\alternative} belong to the inner @code{\repeat}. For clarity,
2557 it is advisable to use braces in such situations.
2560 @node Repeats and MIDI
2561 @subsection Repeats and MIDI
2563 @cindex expanding repeats
2565 For instructions on how to unfold repeats for MIDI output, see the
2566 example file @inputfileref{input/test,unfold-all-repeats.ly}.
2571 Timing information is not remembered at the start of an alternative,
2572 so after a repeat timing information must be reset by hand, for
2573 example by setting @code{Score.measurePosition} or entering
2574 @code{\partial}. Similarly, slurs or ties are also not repeated.
2577 @node Manual repeat commands
2578 @subsection Manual repeat commands
2580 @cindex @code{repeatCommands}
2582 The property @code{repeatCommands} can be used to control the layout of
2583 repeats. Its value is a Scheme list of repeat commands, where each repeat
2587 @item the symbol @code{start-repeat},
2588 which prints a @code{|:} bar line,
2589 @item the symbol @code{end-repeat},
2590 which prints a @code{:|} bar line,
2591 @item the list @code{(volta @var{text})},
2592 which prints a volta bracket saying @var{text}: The text can be specified as
2593 a text string or as a markup text, see @ref{Text markup}. Do not
2594 forget to change the font, as the default number font does not contain
2595 alphabetic characters. Or,
2596 @item the list @code{(volta #f)}, which
2597 stops a running volta bracket:
2600 @lilypond[verbatim,fragment,relative=2]
2602 \set Score.repeatCommands = #'((volta "93") end-repeat)
2604 \set Score.repeatCommands = #'((volta #f))
2611 Internals: @internalsref{VoltaBracket}, @internalsref{RepeatedMusic},
2612 @internalsref{VoltaRepeatedMusic},
2613 @internalsref{UnfoldedRepeatedMusic}, and
2614 @internalsref{FoldedRepeatedMusic}.
2616 @node Tremolo repeats
2617 @subsection Tremolo repeats
2618 @cindex tremolo beams
2620 To place tremolo marks between notes, use @code{\repeat} with tremolo
2622 @lilypond[verbatim,raggedright]
2624 \context Voice \notes\relative c' {
2625 \repeat "tremolo" 8 { c16 d16 }
2626 \repeat "tremolo" 4 { c16 d16 }
2627 \repeat "tremolo" 2 { c16 d16 }
2632 Tremolo marks can also be put on a single note. In this case, the
2633 note should not be surrounded by braces.
2634 @lilypond[verbatim,raggedright]
2635 \repeat "tremolo" 4 c16
2638 A similar mechanism is the tremolo subdivision, described in
2639 @ref{Tremolo subdivisions}.
2643 In this manual: @ref{Tremolo subdivisions}, @ref{Repeats}.
2645 Internals: tremolo beams are @internalsref{Beam} objects. Single stem
2646 tremolos are @internalsref{StemTremolo} objects. The music expression is
2647 @internalsref{TremoloEvent}.
2649 Example files: @inputfileref{input/regression,chord-tremolo.ly},
2650 @inputfileref{input/regression,stem-tremolo.ly}.
2652 @node Tremolo subdivisions
2653 @subsection Tremolo subdivisions
2654 @cindex tremolo marks
2655 @cindex @code{tremoloFlags}
2657 Tremolo marks can be printed on a single note by adding
2658 `@code{:}[@var{length}]' after the note. The length must be at least 8.
2659 A @var{length} value of 8 gives one line across the note stem. If the
2660 length is omitted, then then the last value (stored in
2661 @code{tremoloFlags}) is used:
2663 @lilypond[verbatim,fragment,center]
2664 c'2:8 c':32 | c': c': |
2667 @c [TODO : stok is te kort bij 32en]
2671 Tremolos in this style do not carry over into the MIDI output.
2675 In this manual: @ref{Tremolo repeats}.
2677 Elsewhere: @internalsref{StemTremolo}, @internalsref{TremoloEvent}.
2679 @node Measure repeats
2680 @subsection Measure repeats
2682 @cindex percent repeats
2683 @cindex measure repeats
2685 In the @code{percent} style, a note pattern can be repeated. It is
2686 printed once, and then the pattern is replaced with a special sign.
2687 Patterns of a one and two measures are replaced by percent-like signs,
2688 patterns that divide the measure length are replaced by slashes:
2690 @lilypond[verbatim,raggedright]
2691 \context Voice { \repeat "percent" 4 { c'4 }
2692 \repeat "percent" 2 { c'2 es'2 f'4 fis'4 g'4 c''4 }
2698 Internals: @internalsref{RepeatSlash}, @internalsref{PercentRepeat},
2699 @internalsref{PercentRepeatedMusic}, and
2700 @internalsref{DoublePercentRepeat}.
2704 @node Rhythmic music
2705 @section Rhythmic music
2709 * Showing melody rhythms::
2710 * Entering percussion::
2711 * Percussion staves::
2715 @node Showing melody rhythms
2716 @subsection Showing melody rhythms
2718 Sometimes you might want to show only the rhythm of a melody. This
2719 can be done with the rhythmic staff. All pitches of notes on such a
2720 staff are squashed, and the staff itself has a single line:
2722 @lilypond[fragment,relative,verbatim]
2723 \context RhythmicStaff {
2725 c4 e8 f g2 | r4 g r2 | g1:32 | r1 |
2731 Internals: @internalsref{RhythmicStaff}.
2733 Examples: @inputfileref{input/regression,rhythmic-staff.ly}.
2736 @node Entering percussion
2737 @subsection Entering percussion
2744 Percussion notes may be entered in @code{\drums} mode, which is
2745 similar to @code{notes}. Each piece of percussion has a full name and
2746 an abbreviated name, and both be used in input files:
2748 @lilypond[raggedright]
2749 \drums { hihat4 hh4 }
2752 The complete list of drum names is in the init file
2753 @file{ly/drumpitch-init.ly}.
2754 @c TODO: properly document this.
2758 Internals: @internalsref{DrumNoteEvent}.
2760 @node Percussion staves
2761 @subsection Percussion staves
2765 A percussion part for more than one instrument typically uses a
2766 multiline staff where each position in the staff refers to one piece
2770 To typeset the music, the notes must be interpreted in a
2771 @internalsref{DrumStaff} and @internalsref{DrumVoice} contexts:
2774 @lilypond[raggedright,verbatim,quote]
2775 up = \drums { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
2776 down = \drums { bassdrum4 snare8 bd r bd sn4 }
2779 << \new DrumVoice { \voiceOne \up }
2780 \new DrumVoice { \voiceTwo \down }
2784 The above example shows verbose polyphonic notation. The short
2785 polyphonic notation, described in @ref{Polyphony}, can also be used if
2786 the @internalsref{DrumVoices} are instantiated by hand first. For example,
2789 \drums \new DrumStaff <<
2790 \context DrumVoice = "1" { s1 *2 }
2791 \context DrumVoice = "2" { s1 *2 }
2795 { \repeat unfold 16 hh16 }
2804 There are also other layout possibilities. To use these, set the
2805 property @code{drumStyleTable} in context @internalsref{DrumVoice}.
2806 The following variables have been predefined:
2810 is the default. It typesets a typical drum kit on a five-line staff
2813 nam = \lyrics { cymc cyms cymr hh hhc hho hhho hhp cb hc
2814 bd sn ss tomh tommh tomml toml tomfh tomfl }
2815 mus = \drums { cymc cyms cymr hh | hhc hho hhho hhp | \break cb hc
2816 bd sn ss tomh tommh tomml toml tomfh tomfl s16 }
2818 << \new DrumStaff\with {
2819 \remove Bar_engraver
2820 \remove Time_signature_engraver
2821 \override Stem #'transparent = ##t
2822 \override Stem #'Y-extent-callback = ##f
2823 minimumVerticalExtent = #'(-4.0 . 5.0)
2825 \context Lyrics \nam
2828 %% need to do this, because of indented @itemize
2830 \translator { \ScoreContext
2831 \override BarNumber #'transparent =##T
2835 The drum scheme supports six different toms. When there fewer toms, simply
2836 select the toms that produce the desired result, i.e. to get toms on
2837 the three middle lines you use @code{tommh}, @code{tomml} and
2840 @item timbales-style
2841 to typeset timbales on a two line staff:
2843 @lilypond[raggedright]
2844 nam = \lyrics { timh ssh timl ssl cb }
2845 mus = \drums { timh ssh timl ssl cb s16 }
2848 \context DrumStaff \with {
2849 \remove Bar_engraver
2850 \remove Time_signature_engraver
2851 \override Stem #'transparent = ##t
2852 \override Stem #'Y-extent-callback = ##f
2853 \override StaffSymbol #'line-count = #2
2854 \override StaffSymbol #'staff-space = #2
2855 minimumVerticalExtent = #'(-3.0 . 4.0)
2856 drumStyleTable = #timbales-style
2858 \context Lyrics \nam
2863 to typeset congas on a two line staff:
2865 @lilypond[raggedright]
2866 nam = \lyrics { cgh cgho cghm ssh cgl cglo cglm ssl }
2867 mus = \drums { cgh cgho cghm ssh cgl cglo cglm ssl s16 }
2870 \context DrumStaff\with {
2871 \remove Bar_engraver
2872 \remove Time_signature_engraver
2873 drumStyleTable = #congas-style
2874 \override StaffSymbol #'line-count = #2
2876 %% this sucks; it will lengthen stems.
2877 \override StaffSymbol #'staff-space = #2
2878 \override Stem #'transparent = ##t
2879 \override Stem #'Y-extent-callback = ##f
2881 \context Lyrics \nam
2886 to typeset bongos on a two line staff:
2888 @lilypond[raggedright]
2889 nam = \lyrics { boh boho bohm ssh bol bolo bolm ssl }
2890 mus = \drums { boh boho bohm ssh bol bolo bolm ssl s16 }
2893 \context DrumStaff\with {
2894 \remove Bar_engraver
2895 \remove Time_signature_engraver
2896 \override StaffSymbol #'line-count = #2
2897 drumStyleTable = #bongos-style
2899 %% this sucks; it will lengthen stems.
2900 \override StaffSymbol #'staff-space = #2
2901 \override Stem #'transparent = ##t
2902 \override Stem #'Y-extent-callback = ##f
2904 \context Lyrics \nam
2909 @item percussion-style
2910 to typeset all kinds of simple percussion on one line staves:
2911 @lilypond[raggedright]
2912 nam = \lyrics { tri trio trim gui guis guil cb cl tamb cab mar hc }
2913 mus = \drums { tri trio trim gui guis guil cb cl tamb cab mar hc s16 }
2916 \context DrumStaff\with{
2917 \remove Bar_engraver
2918 drumStyleTable = #percussion-style
2919 \override StaffSymbol #'line-count = #1
2920 \remove Time_signature_engraver
2921 \override Stem #'transparent = ##t
2922 \override Stem #'Y-extent-callback = ##f
2924 \context Lyrics \nam
2930 If you do not like any of the predefined lists you can define your own
2931 list at the top of your file:
2933 @lilypond[raggedright,verbatim]
2935 (bassdrum default #f -1)
2936 (snare default #f 0)
2938 (pedalhihat xcircle "stopped" 2)
2939 (lowtom diamond #f 3)
2941 up = \drums { hh8 hh hh hh hhp4 hhp }
2942 down = \drums { bd4 sn bd toml8 toml }
2945 \set DrumStaff.drumStyleTable
2946 = #(alist->hash-table mydrums)
2947 \new DrumVoice { \voiceOne \up }
2948 \new DrumVoice { \voiceTwo \down }
2956 Init files: @file{ly/drumpitch-init.ly}.
2958 Internals: @internalsref{DrumStaff}, @internalsref{DrumVoice}.
2962 Short polyphonic notation, @code{<< @dots{} \\ @dots{} >>}, does not
2963 work for @internalsref{DrumVoices}.
2965 Because general MIDI does not contain rim shots, the sidestick is used
2966 for this purpose instead.
2969 @section Piano music
2971 Piano staves are two normal staves coupled with a brace. The staves
2972 are largely independent, but sometimes voices can cross between the
2973 two staves. The same notation is also used for harps and other key
2974 instruments. The @internalsref{PianoStaff} is especially built to
2975 handle this cross-staffing behavior. In this section we discuss the
2976 @internalsref{PianoStaff} and some other pianistic peculiarities.
2980 * Automatic staff changes::
2981 * Manual staff switches::
2984 * Staff switch lines::
2989 There is no support for putting chords across staves. You can get
2990 this result by increasing the length of the stem in the lower stave so
2991 it reaches the stem in the upper stave, or vice versa. An example is
2992 included with the distribution as
2993 @inputfileref{input/test,stem-cross-staff.ly}.
2995 Dynamics are not centered, but kludges do exist. See
2996 @inputfileref{input/template,piano-dynamics.ly}.
2998 @cindex cross staff stem
2999 @cindex stem, cross staff
3001 The distance between the two staves is normally fixed across the
3002 entire score. It is possible to tune this per system, but it does
3003 require arcane command incantations. See
3004 @inputfileref{input/test,piano-staff-distance.ly}.
3011 @node Automatic staff changes
3012 @subsection Automatic staff changes
3013 @cindex Automatic staff changes
3015 Voices can switch automatically between the top and the bottom
3016 staff. The syntax for this is
3018 \autochange \context Voice @{ @dots{}@var{music}@dots{} @}
3020 The two staffs of the piano staff must be named @code{up} and
3023 The autochanger switches on basis of pitch (middle C is the turning
3024 point), and it looks ahead skipping over rests to switch in
3025 advance. Here is a practical example:
3027 @lilypond[verbatim,raggedright,quote]
3028 \score { \notes \context PianoStaff <<
3029 \context Staff = "up" {
3030 \autochange \new Voice \relative c' {
3031 g4 a b c d r4 a g } }
3032 \context Staff = "down" {
3039 In this example, spacer rests are used to prevent the bottom staff from
3040 terminating too soon.
3045 In this manual: @ref{Manual staff switches}.
3047 Internals: @internalsref{AutoChangeMusic}.
3053 The staff switches often do not end up in optimal places. For high
3054 quality output, staff switches should be specified manually.
3058 @node Manual staff switches
3059 @subsection Manual staff switches
3061 @cindex manual staff switches
3062 @cindex staff switch, manual
3064 Voices can be switched between staves manually, using the following command:
3066 \change Staff = @var{staffname} @var{music}
3070 The string @var{staffname} is the name of the staff. It switches the
3071 current voice from its current staff to the Staff called
3072 @var{staffname}. Typically @var{staffname} is @code{"up"} or
3081 Pianos have pedals that alter the way sound are produced. Generally, a
3082 piano has three pedals, sustain, una corda, and sostenuto.
3086 Piano pedal instruction can be expressed by attaching
3087 @code{\sustainDown}, @code{\sustainUp}, @code{\unaCorda},
3088 @code{\treCorde}, @code{\sostenutoDown} and @code{\sostenutoUp} to a
3091 @lilypond[fragment,verbatim]
3092 c'4\sustainDown c'4\sustainUp
3095 What is printed can be modified by setting @code{pedal@var{X}Strings},
3096 where @var{X} is one of the pedal types: @code{Sustain},
3097 @code{Sostenuto} or @code{UnaCorda}. Refer to the generated
3098 documentation of @internalsref{SustainPedal} for more information.
3100 Pedals can also be indicated by a sequence of brackets, by setting the
3101 @code{pedalSustainStyle} property to @code{bracket} objects:
3103 @lilypond[fragment,verbatim]
3104 \set Staff.pedalSustainStyle = #'bracket
3105 c''4\sustainDown d''4 e''4
3106 a'4\sustainUp\sustainDown
3107 f'4 g'4 a'4\sustainUp
3110 A third style of pedal notation is a mixture of text and brackets,
3111 obtained by setting the @code{pedalSustainStyle} style property to
3114 @lilypond[fragment,verbatim]
3115 \set Staff.pedalSustainStyle = #'mixed
3116 c''4\sustainDown d''4 e''4
3117 c'4\sustainUp\sustainDown
3118 f'4 g'4 a'4\sustainUp
3121 The default `*Ped.' style for sustain and damper pedals corresponds to
3122 style @code{#'text}. The sostenuto pedal uses @code{mixed} style by
3125 @lilypond[fragment,verbatim]
3126 c''4\sostenutoDown d''4 e''4 c'4 f'4 g'4 a'4\sostenutoUp
3129 For fine-tuning of the appearance of a pedal bracket, the properties
3130 @code{edge-width}, @code{edge-height}, and @code{shorten-pair} of
3131 @code{PianoPedalBracket} objects (see
3132 @internalsref{PianoPedalBracket} in the Program reference) can be modified. For example, the
3133 bracket may be extended to the end of the note head:
3135 @lilypond[fragment,verbatim]
3136 \override Staff.PianoPedalBracket
3137 #'shorten-pair = #'(0 . -1.0)
3138 c''4\sostenutoDown d''4 e''4 c'4
3139 f'4 g'4 a'4\sostenutoUp
3143 @subsection Arpeggio
3146 @cindex broken arpeggio
3147 @cindex @code{\arpeggio}
3149 You can specify an arpeggio sign on a chord by attaching an
3150 @code{\arpeggio} to a chord:
3153 @lilypond[fragment,relative,verbatim]
3157 When an arpeggio crosses staves, you attach an arpeggio to the chords
3158 in both staves, and set
3159 @internalsref{PianoStaff}.@code{connectArpeggios}:
3161 @lilypond[fragment,relative,verbatim]
3162 \context PianoStaff <<
3163 \set PianoStaff.connectArpeggios = ##t
3164 \new Staff { <c' e g c>\arpeggio }
3165 \new Staff { \clef bass <c,, e g>\arpeggio }
3169 The direction of the arpeggio is sometimes denoted by adding an
3170 arrowhead to the wiggly line:
3172 @lilypond[fragment,relative,verbatim]
3181 A square bracket on the left indicates that the player should not
3182 arpeggiate the chord:
3184 @lilypond[fragment,relative,verbatim]
3191 @cindex @code{\arpeggio}
3193 @cindex @code{\arpeggioUp}
3195 @cindex @code{\arpeggioDown}
3197 @cindex @code{\arpeggioBoth}
3198 @code{\arpeggioBoth},
3199 @cindex @code{\arpeggioBracket}
3200 @code{\arpeggioBracket}.
3204 Internals: @internalsref{ArpeggioEvent} music expressions lead to
3205 @internalsref{Arpeggio} objects. Cross staff arpeggios are
3206 @internalsref{PianoStaff}.@internalsref{Arpeggio}.
3210 It is not possible to mix connected arpeggios and unconnected
3211 arpeggios in one @internalsref{PianoStaff} at the same time.
3213 @node Staff switch lines
3214 @subsection Staff switch lines
3217 @cindex follow voice
3218 @cindex staff switching
3221 @cindex @code{followVoice}
3223 Whenever a voice switches to another staff a line connecting the notes
3224 can be printed automatically. This is enabled if the property
3225 @code{PianoStaff.followVoice} is set to true:
3227 @lilypond[fragment,relative,verbatim]
3228 \context PianoStaff <<
3229 \set PianoStaff.followVoice = ##t
3230 \context Staff \context Voice {
3235 \context Staff=two { \clef bass \skip 1*2 }
3239 The associated object is @internalsref{VoiceFollower}.
3243 @cindex @code{\showStaffSwitch}
3244 @code{\showStaffSwitch},
3245 @cindex @code{\hideStaffSwitch}
3246 @code{\hideStaffSwitch}.
3250 @section Vocal music
3252 This section discusses how to enter and print lyrics.
3256 * The Lyrics context::
3261 @node Entering lyrics
3262 @subsection Entering lyrics
3266 @cindex @code{\lyrics}
3269 Lyrics are entered in a special input mode. This mode is is introduced
3270 by the keyword @code{\lyrics}. In this mode you can enter lyrics, with
3271 punctuation and accents without any hassle. Syllables are entered like
3272 notes, but with pitches replaced by text. For example,
3274 \lyrics @{ Twin-4 kle4 twin- kle litt- le star2 @}
3277 A word in Lyrics mode begins with: an alphabetic character, @code{_},
3278 @code{?}, @code{!}, @code{:}, @code{'}, the control characters @code{^A}
3279 through @code{^F}, @code{^Q} through @code{^W}, @code{^Y}, @code{^^},
3280 any 8-bit character with ASCII code over 127, or a two-character
3281 combination of a backslash followed by one of @code{`}, @code{'},
3282 @code{"}, or @code{^}.
3284 Subsequent characters of a word can be any character that is not a digit
3285 and not white space. One important consequence of this is that a word
3286 can end with @code{@}}. The following example is usually a bug. The
3287 syllable includes a @code{@}}, and hence the opening brace is not balanced:
3289 \lyrics @{ twinkle@}
3292 @cindex @code{\property}, in @code{\lyrics}
3293 Similarly, a period following a alphabetic sequence, is included in
3294 the resulting string. As a consequence, spaces must be inserted around
3297 \override Score . LyricText #'font-shape = #'italic
3301 @cindex spaces, in lyrics
3302 @cindex quotes, in lyrics
3304 Any @code{_} character which appears in an unquoted word is converted
3305 to a space. This provides a mechanism for introducing spaces into words
3306 without using quotes. Quoted words can also be used in Lyrics mode to
3307 specify words that cannot be written with the above rules:
3310 \lyrics @{ He said: "\"Let" my peo ple "go\"" @}
3314 Hyphens can be entered as ordinary hyphens at the end of a syllable, i.e.
3319 These will be attached to the end of the first syllable.
3321 Centered hyphens are entered using the special `@code{-}@code{-}' lyric
3322 as a separate word between syllables. The hyphen will have variable
3323 length depending on the space between the syllables and it will be
3324 centered between the syllables.
3329 When a lyric is sung over many notes (this is called a melisma), this is
3330 indicated with a horizontal line centered between a syllable and the
3331 next one. Such a line is called an extender line, and it is entered as
3336 Internals: @internalsref{LyricEvent}, @internalsref{HyphenEvent}, and
3337 @internalsref{ExtenderEvent}.
3339 Examples: @inputfileref{input/test,lyric-hyphen-retain.ly}.
3343 The definition of lyrics mode is too complex.
3347 @node The Lyrics context
3348 @subsection The Lyrics context
3350 Lyrics are printed by interpreting them in a @internalsref{Lyrics} context:
3352 \context Lyrics \lyrics @dots{}
3355 @cindex automatic syllable durations
3356 @cindex @code{\lyricsto}
3357 @cindex lyrics and melodies
3359 This will place the lyrics according to the durations that were
3360 entered. The lyrics can also be aligned under a given melody
3361 automatically. In this case, it is no longer necessary to enter the
3362 correct duration for each syllable. This is achieved by combining the
3363 melody and the lyrics with the @code{\lyricsto} expression:
3365 \lyricsto @var{name} \new Lyrics @dots{}
3368 This aligns the lyrics to the
3370 notes of the @internalsref{Voice} context called @var{name}, which has
3371 to exist. Therefore, normally the @code{Voice} is specified first, and
3372 then the lyrics are specified with @code{\lyricsto}.
3374 For different or more complex orderings, the best way is to setup the
3375 hierarchy of staves and lyrics first, e.g.
3377 \context ChoirStaff \notes <<
3378 \context Lyrics = sopranoLyrics @{ s1 @}
3379 \context Voice = soprano @{ @emph{music} @}
3380 \context Lyrics = tenorLyrics @{ s1 @}
3381 \context Voice = tenor @{ @emph{music} @}
3384 and then combine the appropriate melodies and lyric lines:
3386 \lyricsto "soprano" \new Lyrics @emph{the lyrics}
3390 The final input would resemble
3393 << \context ChoirStaff \notes << @emph{setup the music} >>
3394 \lyricsto "soprano" @emph{etc}
3395 \lyricsto "alto" @emph{etc}
3401 The @code{\lyricsto} command detects melismata: it only puts one
3402 syllable under a tied or slurred group of notes. If you want to force
3403 an unslurred group of notes to be a melisma, then insert
3404 @code{\melisma} after the first note of the group, and
3405 @code{\melismaEnd} after the last one, e.g.
3407 @lilypond[relative=1,raggedright,fragment,verbatim]
3408 << \context Voice = "lala" { \time 3/4
3414 \lyricsto "lala" \new Lyrics \lyrics {
3419 In addition, notes are considered a melisma if they are manually
3420 beamed, and automatic beaming (see @ref{Setting automatic beam
3421 behavior}) is switched off. The criteria for deciding melismata
3422 can be tuned with the property @code{melismaBusyProperties}. See
3423 @internalsref{Melisma_translator} for more information.
3425 When multiple stanzas are put on the same melody, it can happen that
3426 two stanzas have melismata in different locations. This can be
3427 remedied by switching off melismata for one
3428 @internalsref{Lyrics}. This is achieved by setting
3429 the @code{ignoreMelismata} property to @code{#t}. An example is shown
3430 in @inputfileref{input/regression,lyric-combine-new.ly}.
3433 @cindex choral score
3435 A complete example of a SATB score setup is in the file
3436 @inputfileref{input/template,satb.ly}.
3441 @code{\melisma}, @code{\melismaEnd}
3442 @cindex @code{\melismaEnd}
3443 @cindex @code{\melisma}
3447 Internals: Music expressions: @internalsref{LyricCombineMusic},
3448 Contexts: @internalsref{Lyrics}, @internalsref{Melisma_translator}.
3450 Examples: @inputfileref{input/template,satb.ly},
3451 @inputfileref{input/regression,lyric-combine-new.ly}.
3455 Melismata are not detected automatically, and extender lines must be
3459 For proper processing of extender lines, the
3460 @internalsref{Lyrics} and @internalsref{Voice} should be
3461 linked. This can be achieved either by using @code{\lyricsto} or by
3462 setting corresponding names for both contexts. The latter is explained
3463 in @ref{More stanzas}.
3466 @subsection More stanzas
3468 @cindex phrasing, in lyrics
3471 The lyrics should be aligned with the note heads of the melody. To
3472 achieve this, each line of lyrics should be marked to correspond with
3473 the melodic line. This is done automatically when @code{\lyricsto},
3474 but it can also be done manually.
3476 To this end, give the @internalsref{Voice} context an identity:
3478 \context Voice = duet @{
3483 Then set the @internalsref{Lyrics} contexts to names starting with
3484 that identity followed by a dash. In the preceding example, the
3485 @internalsref{Voice} identity is @code{duet}, so the identities of the
3486 @internalsref{Lyrics}s are marked @code{duet-1} and @code{duet-2}:
3488 \context Lyrics = "duet-1" @{
3489 Hi, my name is bert. @}
3490 \context Lyrics = "duet-2" @{
3491 Ooooo, ch\'e -- ri, je t'aime. @}
3494 The complete example is shown here:
3495 @lilypond[raggedright,verbatim]
3497 << \notes \relative c'' \context Voice = duet { \time 3/4
3499 \lyrics << \lyricsto "duet" \new Lyrics {
3501 \set vocNam = "Bert"
3502 Hi, my name is bert. }
3503 \lyricsto "duet" \new Lyrics {
3505 \set vocNam = "Ernie"
3506 Ooooo, ch\'e -- ri, je t'aime.
3512 @cindex stanza number
3513 @cindex singer's names
3514 @cindex name of singer
3516 Stanza numbers can be added by setting @code{stanza}, e.g.
3524 Notice how dots are surrounded with spaces in @code{\lyrics} mode, to
3525 prevent @code{stanza} being interpreted as a single
3528 This example also demonstrates how names of the singers can be added
3529 using @code{vocalName} analogous to instrument annotations for staves.
3530 A short version may be entered as @code{vocNam}.
3532 To make empty spaces in lyrics, use @code{\skip}.
3537 Internals: Layout objects @internalsref{LyricText} and
3538 @internalsref{VocalName}. Music expressions:
3539 @internalsref{LyricEvent}.
3545 Input for lyrics introduces a syntactical ambiguity:
3552 is interpreted as assigning a string identifier @code{\foo} such that
3553 it contains @code{"bar"}. However, it could also be interpreted as
3554 making or a music identifier @code{\foo} containing the syllable
3555 `bar'. The force the latter interpretation, use
3565 The term @emph{ambitus} (plural: ambituses) denotes a range of pitches
3566 for a given voice in a part of music. It also may denote the pitch
3567 range that a musical instrument is capable of playing. Most musical
3568 instruments have their ambitus standardized (or at least there is
3569 agreement upon the minimal ambitus of a particular type of
3570 instrument), such that a composer or arranger of a piece of music can
3571 easily meet the ambitus constraints of the targeted instrument.
3572 However, the ambitus of the human voice depends on individual
3573 physiological state, including education and training of the voice.
3574 Therefore, a singer potentially has to check for each piece of music
3575 if the ambitus of that piece meets his individual capabilities. This
3576 is why the ambitus of a piece may be of particular value to vocal
3579 The ambitus is typically notated on a per-voice basis at the very
3580 beginning of a piece, e.g. nearby the initial clef or time signature of
3581 each staff. The range is graphically specified by two note heads, that
3582 represent the minimum and maximum pitch. Some publishers use a textual
3583 notation: they put the range in words in front of the corresponding
3584 staff. LilyPond only supports the graphical ambitus notation.
3586 To apply, add the @internalsref{Ambitus_engraver} to the
3587 @internalsref{Voice} context, i.e.
3593 \consists Ambitus_engraver
3598 This results in the following output:
3600 @lilypond[raggedright]
3601 upper = \notes \relative c {
3604 as'' c e2 bes f cis d4 e f2 g
3606 lower = \notes \relative c {
3609 e'4 b g a c es fis a cis b a g f e d2
3612 \context ChoirStaff {
3614 \new Staff { \upper }
3615 \new Staff { \lower }
3621 \consists Ambitus_engraver
3627 If you have multiple voices in a single staff, and you want a single
3628 ambitus per staff rather than per each voice, then add the
3629 @internalsref{Ambitus_engraver} to the @internalsref{Staff} context
3630 rather than to the @internalsref{Voice} context.
3632 It is possible to tune individual ambituses for multiple voices on a
3633 single staff, for example by erasing or shifting them horizontally. An
3634 example is in @inputfileref{input/test,ambitus-mixed.ly}.
3638 Internals: @internalsref{Ambitus}.
3640 Examples: @inputfileref{input/regression,ambitus.ly},
3641 @inputfileref{input/test,ambitus-mixed.ly}.
3645 There is no collision handling in the case of multiple per-voice
3651 Tablature notation is used for notating music for plucked string
3652 instruments. It notates pitches not by using note heads, but by
3653 indicating on which string and fret a note must be played. LilyPond
3654 offers limited support for tablature.
3657 * Tablatures basic::
3658 * Non-guitar tablatures::
3661 @node Tablatures basic
3662 @subsection Tablatures basic
3663 @cindex Tablatures basic
3665 The string number associated to a note is given as a backslash
3666 followed by a number, e.g. @code{c4\3} for a C quarter on the third
3667 string. By default, string 1 is the highest one, and the tuning
3668 defaults to the standard guitar tuning (with 6 strings). The notes
3669 are printed as tablature, by using @internalsref{TabStaff} and
3670 @internalsref{TabVoice} contexts:
3672 @lilypond[fragment,verbatim]
3673 \notes \context TabStaff {
3681 When no string is specified, the first string that does not give a
3682 fret number less than @code{minimumFret} is selected. The default
3683 value for @code{minimumFret} is 0:
3687 e8 fis gis a b cis' dis' e'
3688 \set TabStaff.minimumFret = #8
3689 e8 fis gis a b cis' dis' e'
3694 e8 fis gis a b cis' dis' e'
3695 \set TabStaff.minimumFret = #8
3696 e8 fis gis a b cis' dis' e'
3699 \context StaffGroup <<
3700 \context Staff { \clef "G_8" \frag }
3701 \context TabStaff { \frag }
3708 Internals: @internalsref{TabStaff}, @internalsref{TabVoice}, and
3709 @internalsref{StringNumberEvent}.
3713 Chords are not handled in a special way, and hence the automatic
3714 string selector may easily select the same string to two notes in a
3718 @node Non-guitar tablatures
3719 @subsection Non-guitar tablatures
3720 @cindex Non-guitar tablatures
3722 You can change the number of strings, by setting the number of lines
3723 in the @internalsref{TabStaff}.
3725 You can change the tuning of the strings. A string tuning is given as
3726 a Scheme list with one integer number for each string, the number
3727 being the pitch (measured in semitones relative to middle C) of an
3728 open string. The numbers specified for @code{stringTuning} are the
3729 numbers of semitones to subtract or add, starting the specified pitch
3730 by default middle C, in string order. Thus, the notes are e, a, d, and
3733 @lilypond[fragment,verbatim]
3734 \context TabStaff <<
3735 \set TabStaff.stringTunings = #'(-5 -10 -15 -20)
3738 a,4 c' a e' e c' a e'
3743 It is possible to change the Scheme function to format the tablature
3744 note text. The default is @code{fret-number-tablature-format}, which
3745 uses the fret number. For instruments that do not use this notation,
3746 you can create a special tablature formatting function. This function
3747 takes three argument: string number, string tuning and note pitch.
3751 No guitar special effects have been implemented.
3756 @section Chord names
3759 LilyPond has support for both printing chord names. Chords may be
3760 entered in musical chord notation, i.e. @code{< .. >}, but they can
3761 also be entered by name. Internally, the chords are represented as a
3762 set of pitches, so they can be transposed:
3765 @lilypond[verbatim,raggedright]
3766 twoWays = \notes \transpose c c' {
3776 << \context ChordNames \twoWays
3777 \context Voice \twoWays >> }
3780 This example also shows that the chord printing routines do not try to
3781 be intelligent. The last chord (@code{f bes d}) is not interpreted as
3787 * Printing chord names::
3792 @subsection Chords mode
3795 Chord mode is a mode where you can input sets of pitches using common
3796 names. It is introduced by the keyword @code{\chords}.
3797 In chords mode, a chord is entered by the root, which is entered
3798 like a common pitch:
3799 @lilypond[fragment,verbatim,quote,relative=1]
3800 \chords { es4. d8 c2 }
3805 Other chords may be entered by suffixing a colon, and introducing a
3806 modifier, and optionally, a number:
3808 @lilypond[fragment,verbatim,quote]
3809 \chords { e1:m e1:7 e1:m7 }
3811 The first number following the root is taken to be the `type' of the
3812 chord, thirds are added to the root until it reaches the specified
3814 @lilypond[fragment,verbatim]
3815 \chords { c:3 c:5 c:6 c:7 c:8 c:9 c:10 c:11 }
3818 @cindex root of chord
3819 @cindex additions, in chords
3820 @cindex removals, in chords
3822 More complex chords may also be constructed adding separate steps
3823 to a chord. Additions are added after the number following
3824 the colon, and are separated by dots:
3826 @lilypond[verbatim,fragment,quote]
3827 \chords { c:5.6 c:3.7.8 c:3.6.13 }
3829 Chord steps can be altered by suffixing a @code{-} or @code{+} sign
3831 @lilypond[verbatim,fragment,quote]
3832 \chords { c:7+ c:5+.3- c:3-.5-.7- }
3834 Removals are specified similarly, and are introduced by a caret. They
3835 must come after the additions:
3836 @lilypond[verbatim,fragment]
3837 \chords { c^3 c:7^5 c:9^3.5 }
3840 Modifiers can be used to change pitches. The following modifiers are
3844 is the minor chord. This modifier lowers the 3rd and (if present) the 7th step.
3846 is the diminished chord. This modifier lowers the 3rd, 5th and (if present)
3849 is the augmented chord. This modifier raises the 5th step.
3851 is the major 7th chord. This modifier raises the 7th step if present.
3853 is the suspended 4th or 2nd. This modifier removes the 3rd
3854 step. Append either @code{2} or @code{4} to add the 2nd or 4th step to
3857 Modifiers can be mixed with additions:
3858 @lilypond[verbatim,fragment]
3859 \chords { c:sus4 c:7sus4 c:dim7 c:m6 }
3862 @cindex modifiers, in chords.
3869 Since an unaltered 11 does not sound good when combined with an
3870 unaltered 13, the 11 is removed in this case (unless it is added
3873 @lilypond[fragment,verbatim]
3874 \chords { c:13 c:13.11 c:m13 }
3879 An inversion (putting one pitch of the chord on the bottom), as well
3880 as bass notes, can be specified by appending
3881 @code{/}@var{pitch} to the chord:
3882 @lilypond[fragment,verbatim,center]
3883 \chords { c1 c/g c/f }
3887 A bass note can be added instead of transposed out of the chord,
3888 by using @code{/+}@var{pitch}.
3890 @lilypond[fragment,verbatim,center]
3891 \chords { c1 c/+g c/+f }
3894 Chords is a mode similar to @code{\lyrics}, @code{\notes} etc. Most
3895 of the commands continue to work, for example, @code{r} and
3896 @code{\skip} can be used to insert rests and spaces, and property
3897 commands may be used to change various settings.
3903 Each step can only be present in a chord once. The following
3904 simply produces the augmented chord, since @code{5+} is interpreted
3907 @lilypond[verbatim,fragment]
3908 \chords { c:5.5-.5+ }
3912 @node Printing chord names
3913 @subsection Printing chord names
3915 @cindex printing chord names
3919 For displaying printed chord names, use the @internalsref{ChordNames} context.
3920 The chords may be entered either using the notation
3921 described above, or directly using @code{<} and @code{>}:
3923 @lilypond[verbatim,raggedright]
3925 \chords {a1 b c} <d' f' a'> <e' g' b'>
3929 \context ChordNames \scheme
3930 \context Staff \scheme
3935 You can make the chord changes stand out by setting
3936 @internalsref{ChordNames}.@code{chordChanges} to true. This will only
3937 display chord names when there is a change in the chords scheme and at
3938 the start of a new line:
3940 @lilypond[verbatim,linewidth=9\cm]
3942 c1:m c:m \break c:m c:m d
3946 \context ChordNames {
3947 \set chordChanges = ##t
3949 \context Staff \transpose c c' \scheme
3954 The default chord name layout is a system for Jazz music, proposed by
3955 Klaus Ignatzek (see @ref{Literature list}). It can be tuned through the
3956 following properties:
3959 @cindex chordNameExceptions
3960 @item chordNameExceptions
3961 This is a list that contains the chords that have special formatting.
3963 @inputfileref{input/regression,chord-name-exceptions.ly}.
3964 @cindex exceptions, chord names.
3967 @cindex majorSevenSymbol
3968 @item majorSevenSymbol
3969 This property contains the markup object used for the 7th step, when
3970 it is major. Predefined options are @code{whiteTriangleMarkup} and
3971 @code{blackTriangleMarkup}. See
3972 @inputfileref{input/regression,chord-name-major7.ly} for an example.
3974 @cindex chordNameSeparator
3975 @item chordNameSeparator
3976 Different parts of a chord name are normally separated by a
3977 slash. By setting @code{chordNameSeparator}, you can specify other
3979 @lilypond[fragment,verbatim]
3980 \context ChordNames \chords {
3982 \set chordNameSeparator
3983 = \markup { \typewriter "|" }
3987 @cindex chordRootNamer
3988 @item chordRootNamer
3989 The root of a chord is usually printed as a letter with an optional
3990 alteration. The transformation from pitch to letter is done by this
3991 function. Special note names (for example, the German ``H'' for a
3992 B-chord) can be produced by storing a new function in this property.
3994 The predefined variables @code{\germanChords},
3995 @code{\semiGermanChords} set these variables.
3998 @cindex chordNoteNamer
3999 @item chordNoteNamer
4000 The default is to print single pitch, e.g. the bass note, using the
4001 @code{chordRootNamer}. The @code{chordNoteNamer} property can be set
4002 to a specialized function to change this behavior. For example, the
4003 base can be printed in lower case.
4008 There are also two other chord name schemes implemented: an alternate
4009 Jazz chord notation, and a systematic scheme called Banter chords. The
4010 alternate jazz notation is also shown on the chart in @ref{Chord name
4011 chart}. Turning on these styles is described in the input file
4012 @inputfileref{input/test,chord-names-jazz.ly}.
4016 @cindex chords, jazz
4021 @cindex @code{\germanChords}
4022 @code{\germanChords},
4023 @cindex @code{\semiGermanChords}
4024 @code{\semiGermanChords}.
4031 Examples: @inputfileref{input/regression,chord-name-major7.ly},
4032 @inputfileref{input/regression,chord-name-exceptions.ly},
4033 @inputfileref{input/test,chord-names-jazz.ly},
4034 @inputfileref{input/test,chord-names-german.ly}.
4036 Init files: @file{scm/chords-ignatzek.scm}, and @file{scm/chord-entry.scm}.
4041 Chord names are determined solely from the list of pitches. Chord
4042 inversions are not identified, and neither are added bass notes. This
4043 may result in strange chord names when chords are entered with the
4044 @code{< .. >} syntax.
4049 @node Orchestral music
4050 @section Orchestral music
4052 @cindex Writing parts
4054 Orchestral music involves some special notation, both in the full
4055 score and the individual parts. This section explains how to tackle
4056 some common problems in orchestral music.
4061 * Multiple staff contexts::
4064 * Instrument names::
4066 * Instrument transpositions::
4067 * Multi measure rests::
4068 * Automatic part combining::
4070 * Different editions from one source::
4071 * Quoting other voices::
4074 @node Multiple staff contexts
4075 @subsection Multiple staff contexts
4077 Polyphonic scores consist of many staves. These staves can be
4078 constructed in three different ways:
4080 @item The group is started with a brace at the left. This is done with the
4081 @internalsref{GrandStaff} context.
4082 @item The group is started with a bracket. This is done with the
4083 @internalsref{StaffGroup} context
4084 @item The group is started with a vertical line. This is the default
4088 @cindex Staff, multiple
4089 @cindex bracket, vertical
4090 @cindex brace, vertical
4097 @node Rehearsal marks
4098 @subsection Rehearsal marks
4099 @cindex Rehearsal marks
4101 @cindex @code{\mark}
4103 To print a rehearsal mark, use the @code{\mark} command:
4104 @lilypond[fragment,verbatim]
4115 (The letter I is skipped in accordance with engraving traditions.)
4117 The mark is incremented automatically if you use @code{\mark
4118 \default}, but you can also use an integer argument to set the mark
4119 manually. The value to use is stored in the property
4120 @code{rehearsalMark}.
4122 The style is defined by the property @code{markFormatter}. It is a
4123 function taking the current mark (an integer) and the current context
4124 as argument. It should return a markup object. In the following
4125 example, @code{markFormatter} is set to a canned procedure. After a
4126 few measures, it is set to function that produces a boxed number.
4128 @lilypond[verbatim,fragment,relative=1]
4129 \set Score.markFormatter = #format-mark-numbers
4132 \set Score.markFormatter
4133 = #(lambda (mark context)
4134 (make-bold-markup (make-box-markup (number->string mark))))
4139 The file @file{scm/translation-functions.scm} contains the definitions
4140 of @code{format-mark-numbers} (the default format) and
4141 @code{format-mark-letters}. They can be used as inspiration for other
4142 formatting functions.
4145 @cindex coda on bar line
4146 @cindex segno on bar line
4147 @cindex fermata on bar line
4148 @cindex bar lines, symbols on
4150 The @code{\mark} command can also be used to put signs like coda,
4151 segno and fermatas on a bar line. Use @code{\markup} to
4152 to access the appropriate symbol:
4154 @lilypond[fragment,verbatim,relative=1]
4155 c1 \mark \markup { \musicglyph #"scripts-ufermata" }
4159 In this case, during line breaks, marks must also be printed at the
4160 end of the line, and not at the beginning. Use the following to force
4163 \override Score.RehearsalMark
4164 #'break-visibility = #begin-of-line-invisible
4170 @cindex bar lines, putting symbols on
4174 Internals: @internalsref{MarkEvent}, @internalsref{RehearsalMark}.
4176 Init files: @file{scm/translation-functions.scm} contains the
4177 definition of @code{format-mark-numbers} and
4178 @code{format-mark-letters}. They can be used as inspiration for other
4179 formatting functions.
4181 Examples: @inputfileref{input/regression,rehearsal-mark-letter.ly},
4182 @inputfileref{input/regression,rehearsal-mark-number.ly}.
4186 @subsection Bar numbers
4190 @cindex measure numbers
4191 @cindex currentBarNumber
4193 Bar numbers are printed by default at the start of the line. The
4194 number itself is stored in the
4195 @code{currentBarNumber} property,
4196 which is normally updated automatically for every measure.
4198 Bar numbers can be typeset at regular intervals instead of at the
4199 beginning of each line. This is illustrated in the following example,
4200 whose source is available as
4201 @inputfileref{input/test,bar-number-regular-interval.ly}:
4203 @lilypondfile[]{bar-number-regular-interval.ly}
4208 Internals: @internalsref{BarNumber}.
4210 Examples: @inputfileref{input/test,bar-number-every-five-reset.ly},
4211 and @inputfileref{input/test,bar-number-regular-interval.ly}.
4215 Bar numbers can collide with the @internalsref{StaffGroup} bracket, if
4216 there is one at the top. To solve this, the
4217 @code{padding} property of @internalsref{BarNumber} can be
4218 used to position the number correctly.
4220 @node Instrument names
4221 @subsection Instrument names
4223 In an orchestral score, instrument names are printed left side of the
4226 This can be achieved by setting @internalsref{Staff}.@code{instrument}
4227 and @internalsref{Staff}.@code{instr}. This will print a string before
4228 the start of the staff. For the first start, @code{instrument} is
4229 used, for the next ones @code{instr} is used:
4232 @lilypond[verbatim,raggedright]
4233 \set Staff.instrument = "ploink " { c''4 }
4237 You can also use markup texts to construct more complicated instrument
4241 @lilypond[fragment,verbatim,raggedright]
4243 \set Staff.instrument = \markup {
4244 \column < "Clarinetti"
4257 Internals: @internalsref{InstrumentName}.
4261 When you put a name on a grand staff or piano staff the width of the
4262 brace is not taken into account. You must add extra spaces to the end of
4263 the name to avoid a collision.
4266 @subsection Transpose
4268 @cindex transposition of pitches
4269 @cindex @code{\transpose}
4271 A music expression can be transposed with @code{\transpose}. The syntax
4274 \transpose @var{from} @var{to} @var{musicexpr}
4277 This means that @var{musicexpr} is transposed by the interval between
4278 the pitches @var{from} and @var{to}: any note with pitch @code{from}
4279 is changed to @code{to}.
4282 For example, consider a piece written in the key of D major. If
4283 this piece is a little too low for its performer, it can be
4284 transposed up to E major with
4286 \transpose d e @dots{}
4289 Consider a part written for violin (a C instrument). If
4290 this part is to be played on the A clarinet, the following
4291 transposition will produce the appropriate part
4294 \transpose a c @dots{}
4297 Since @var{from} and @var{to} are pitches, @code{\transpose} must be
4298 inside a @code{\notes} section. @code{\transpose} distinguishes
4299 between enharmonic pitches: both @code{\transpose c cis} or
4300 @code{\transpose c des} will transpose up half a tone. The first
4301 version will print sharps and the second version will print flats:
4303 @lilypond[raggedright,verbatim]
4304 mus =\notes { \key d \major cis d fis g }
4305 \score { \notes \context Staff {
4308 \transpose c g' \mus
4309 \transpose c f' \mus
4316 Internals: @internalsref{TransposedMusic}, and
4317 @internalsref{UntransposableMusic}.
4321 If you want to use both @code{\transpose} and @code{\relative}, then
4322 you must put @code{\transpose} outside of @code{\relative}, since
4323 @code{\relative} will have no effect music that appears inside a
4326 @node Instrument transpositions
4327 @subsection Instrument transpositions
4329 The key of a transposing instrument can also be specified. This
4330 applies to many wind instruments, for example, clarinets (B-flat, A and
4331 E-flat), horn (F) and trumpet (B-flat, C, D and E-flat).
4335 The transposition is entered after the keyword @code{\transposition}:
4338 \transposition bes %% B-flat clarinet
4341 This command sets the property @code{instrumentTuning}. The value of
4342 this property is used for MIDI output and quotations. It does not
4343 affect how notes are printed in the current staff.
4345 @cindex transposition, MIDI
4346 @cindex transposition, instrument
4349 @node Multi measure rests
4350 @subsection Multi measure rests
4351 @cindex multi measure rests
4352 @cindex Rests, multi measure
4356 Multi measure rests are entered using `@code{R}'. It is specifically
4357 meant for full bar rests and for entering parts: the rest can expand
4358 to fill a score with rests, or it can be printed as a single
4359 multimeasure rest. This expansion is controlled by the property
4360 @code{Score.skipBars}. If this is set to true, empty measures will not
4361 be expanded, and the appropriate number is added automatically:
4363 @lilypond[fragment,verbatim]
4364 \time 4/4 r1 | R1 | R1*2
4365 \set Score.skipBars = ##t R1*17 R1*4
4368 The @code{1} in @code{R1} is similar to the duration notation used for
4369 notes. Hence, for time signatures other than 4/4, you must enter other
4370 durations. This can be done with augmentation dots or fractions:
4372 @lilypond[fragment,verbatim]
4373 \set Score.skipBars = ##t
4381 An @code{R} spanning a single measure is printed as either a whole rest
4382 or a breve, centered in the measure regardless of the time signature.
4384 @cindex text on multi-measure rest
4385 @cindex script on multi-measure rest
4386 @cindex fermata on multi-measure rest
4388 Texts can be added to multi-measure rests by using the
4389 @var{note}-@code{markup} syntax (see @ref{Text markup}). In this case, the number is
4390 replaced. If you need both texts and the number, you must add the
4391 number by hand. A variable (@code{\fermataMarkup}) is provided for
4395 @lilypond[verbatim,fragment]
4397 R2._\markup { "Ad lib" }
4401 If you want to have a text on the left end of a multi-measure rest,
4402 attach the text to a zero-length skip note, i.e.
4410 @cindex whole rests for a full measure
4414 Internals: @internalsref{MultiMeasureRestEvent},
4415 @internalsref{MultiMeasureTextEvent},
4416 @internalsref{MultiMeasureRestMusicGroup}, and
4417 @internalsref{MultiMeasureRest}.
4419 The layout object @internalsref{MultiMeasureRestNumber} is for the
4420 default number, and @internalsref{MultiMeasureRestText} for user
4425 It is not possible to use fingerings (e.g. @code{R1-4}) to put numbers
4426 over multi-measure rests.
4428 @cindex condensing rests
4430 There is no way to automatically condense multiple rests into a single
4431 multimeasure rest. Multi measure rests do not take part in rest
4434 Be careful when entering multimeasure rests followed by whole
4435 notes. The following will enter two notes lasting four measures each:
4439 When @code{skipBars} is set, then the result will look OK, but the
4440 bar numbering will be off.
4442 @node Automatic part combining
4443 @subsection Automatic part combining
4444 @cindex automatic part combining
4445 @cindex part combiner
4448 Automatic part combining is used to merge two parts of music onto a
4449 staff. It is aimed at typesetting orchestral scores. When the two
4450 parts are identical for a period of time, only one is shown. In
4451 places where the two parts differ, they are typeset as separate
4452 voices, and stem directions are set automatically. Also, solo and
4453 @emph{a due} parts are identified and can be marked.
4457 The syntax for part combining is
4460 \partcombine @var{musicexpr1} @var{musicexpr2}
4463 The music expressions will be interpreted as @internalsref{Voice} contexts.
4465 The following example demonstrates the basic functionality of the part
4466 combiner: putting parts on one staff, and setting stem directions and
4469 @lilypond[verbatim,raggedright,fragment,relative=1]
4470 \new Staff \partcombine
4479 The first @code{g} appears only once, although it was
4480 specified twice (once in each part). Stem, slur and tie directions are
4481 set automatically, depending whether there is a solo or unisono. The
4482 first part (with context called @code{one}) always gets up stems, and
4483 `solo', while the second (called @code{two}) always gets down stems and
4486 If you just want the merging parts, and not the textual markings, you
4487 may set the property @var{soloADue} to false:
4489 @lilypond[verbatim,raggedright,fragment,relative=1]
4491 \set Staff.soloADue = ##f
4503 Internals: @internalsref{PartCombineMusic},
4504 @internalsref{SoloOneEvent}, and
4505 @internalsref{SoloTwoEvent}, and
4506 @internalsref{UnisonoEvent}.
4510 In @code{soloADue} mode, when the two voices play the same notes on and
4511 off, the part combiner may typeset @code{a2} more than once in a
4514 @code{\partcombine} can not be inside @code{\times}.
4516 Internally, the @code{\partcombine} interprets both arguments as
4517 @code{Voice}s named @code{one} and @code{two}, and then decides when
4518 the parts can be combined. Consequently, if the arguments switch to
4519 differently named @internalsref{Voice} contexts, then the events in
4520 those will be ignored.
4523 @subsection Hiding staves
4525 @cindex Frenched scores
4526 @cindex Hiding staves
4528 In orchestral scores, staff lines that only have rests are usually
4529 removed. This saves some space. This style is called `French Score'.
4530 For @internalsref{Lyrics},
4531 @internalsref{ChordNames} and @internalsref{FiguredBass}, this is
4532 switched on by default. When these line of these contexts turn out
4533 empty after the line-breaking process, they are removed.
4535 For normal staves, a specialized @internalsref{Staff} context is
4536 available, which does the same: staves containing nothing (or only
4537 multi measure rests) are removed. The context definition is stored in
4538 @code{\RemoveEmptyStaffContext} variable. Observe how the second staff
4539 in this example disappears in the second line:
4544 \notes \relative c' <<
4545 \new Staff { e4 f g a \break c1 }
4546 \new Staff { c4 d e f \break R1 }
4550 \translator { \RemoveEmptyStaffContext }
4555 The first page shows all staffs in full. If they should be removed
4556 from the first page too, set @code{remove-first} to false
4557 in @internalsref{RemoveEmptyVerticalGroup}.
4559 Another application is making ossia sections, i.e. alternative
4560 melodies on a separate piece of staff, with help of a Frenched
4561 staff. See @inputfileref{input/test,ossia.ly} for an example.
4564 @node Different editions from one source
4565 @subsection Different editions from one source
4567 The @code{\tag} command marks music expressions with a name. These
4568 tagged expressions can be filtered out later. With this mechanism it
4569 is possible to make different versions of the same music source.
4571 In the following example, we see two versions of a piece of music, one
4572 for the full score, and one with cue notes for the instrumental part:
4588 The same can be applied to articulations, texts, etc.: they are
4591 -\tag #@var{your-tag}
4593 to an articulation, for example,
4598 This defines a note with a conditional fingering indication.
4600 By applying the @code{remove-tag} function, tagged expressions can be
4601 filtered. For example,
4605 \apply #(remove-tag 'score) @var{the music}
4606 \apply #(remove-tag 'part) @var{the music}
4611 @lilypondfile[]{tag-filter.ly}
4613 The argument of the @code{\tag} command should be a symbol, or a list
4614 of symbols, for example,
4616 \tag #'(original-part transposed-part) @dots{}
4621 Examples: @inputfileref{input/regression,tag-filter.ly}.
4624 @node Quoting other voices
4625 @subsection Quoting other voices
4627 With quotations, fragments of other parts can be inserted into a part
4628 directly. Before a part can be quoted, it must be marked especially as
4629 quotable. This is done with code @code{\addquote} command. The
4630 quotation may then be done with @code{\quote}
4633 \addquote @var{name} @var{music}
4634 \quote @var{name} @var{duration}
4639 Here, @var{name} is an identifying string. The @var{music} is any kind
4640 of music. This is an example of @code{\addquote}:
4643 \addquote clarinet \notes\relative c' {
4648 During a part, a piece of music can be quoted with the @code{\quote}
4655 This would cite 3 quarter notes (a dotted half note) of the previously
4656 added clarinet voice.
4658 Quotations take into account the transposition both source and target
4659 instruments, if they are specified using the @code{\transposition} command.
4661 @lilypond[verbatim fragment]
4662 \addquote clarinet \notes\relative c' {
4668 e'8 f'8 \quote clarinet 2
4674 Only the contents of the first @internalsref{Voice} occurring in an
4675 @code{\addquote} command will be considered for quotation, so
4676 @var{music} can not contain @code{\new} and @code{\context Voice}
4677 statements that would switch to a different Voice.
4682 In this manual: @ref{Instrument transpositions}.
4684 Examples: @inputfileref{input/regression,quote.ly}
4685 @inputfileref{input/regression,quote-transposition.ly}
4687 Internals: @internalsref{QuoteMusic}.
4693 @node Ancient notation
4694 @section Ancient notation
4696 @cindex Vaticana, Editio
4697 @cindex Medicaea, Editio
4702 @c [TODO: write more comprehensive introduction on ancient notation]
4704 Support for ancient notation is still under heavy development.
4705 Regardless of all of the current limitations (see the bugs section
4706 below for details), it includes features for mensural
4707 notation and Gregorian Chant notation. There is also limited support
4708 for figured bass notation.
4710 Many graphical objects provide a @code{style} property, see
4711 @ref{Ancient note heads}, @ref{Ancient accidentals}, @ref{Ancient
4712 rests}, @ref{Ancient clefs}, @ref{Ancient flags} and @ref{Ancient time
4713 signatures}. By manipulating such a grob property, the typographical
4714 appearance of the affected graphical objects can be accommodated for a
4715 specific notation flavor without need for introducing any new
4719 Other aspects of ancient notation can not that easily be expressed as
4720 in terms of just changing a style property of a graphical object.
4721 Therefore, some notational concepts are introduced specifically for
4722 ancient notation, see @ref{Custodes}, @ref{Divisiones},
4723 @ref{Ligatures}, and @ref{Figured bass}.
4727 * Ancient note heads::
4728 * Ancient accidentals::
4732 * Ancient time signatures::
4737 * Vaticana style contexts::
4740 If this all is way too much of documentation for you, and you just
4741 want to dive into typesetting without worrying too much about the
4742 details on how to customize a context, then you may have a look at the
4743 predefined contexts (see @ref{Vaticana style contexts}). Use them to
4744 set up predefined style-specific voice and staff contexts, and
4745 directly go ahead with the note entry.
4749 Ligatures need special spacing that has not yet been implemented. As
4750 a result, there is too much space between ligatures most of the time,
4751 and line breaking often is unsatisfactory. Also, lyrics do not
4752 correctly align with ligatures.
4754 Accidentals must not be printed within a ligature, but instead need to
4755 be collected and printed in front of it.
4757 Augmentum dots within ligatures are not handled correctly.
4760 @node Ancient note heads
4761 @subsection Ancient note heads
4767 For ancient notation, a note head style other than the @code{default}
4768 style may be chosen. This is accomplished by setting the @code{style}
4769 property of the NoteHead object to the desired value (@code{baroque},
4770 @code{neo_mensural} or @code{mensural}). The @code{baroque} style
4771 differs from the @code{default} style only in using a square shape for
4772 @code{\breve} note heads. The @code{neo_mensural} style differs from
4773 the @code{baroque} style in that it uses rhomboidal heads for whole
4774 notes and all smaller durations. Stems are centered on the note
4775 heads. This style is in particular useful when transcribing mensural
4776 music, e.g. for the incipit. The @code{mensural} style finally
4777 produces note heads that mimic the look of note heads in historic
4778 printings of the 16th century.
4780 The following example demonstrates the @code{neo_mensural} style:
4782 @lilypond[fragment,raggedright,verbatim]
4783 \override NoteHead #'style = #'neo_mensural
4784 a'\longa a'\breve a'1 a'2 a'4 a'8 a'16
4787 When typesetting a piece in Gregorian Chant notation, a Gregorian
4788 ligature engraver will automatically select the proper note heads,
4789 such there is no need to explicitly set the note head style. Still,
4790 the note head style can be set e.g. to @code{vaticana_punctum} to
4791 produce punctum neumes. Similarly, a mensural ligature engraver is
4792 used to automatically assemble mensural ligatures. See
4793 @ref{Ligatures} for how ligature engravers work.
4798 @ref{Percussion staves} use note head styles of their own that are
4799 frequently used in contemporary music notation.
4801 Examples: @inputfileref{input/regression,note-head-style.ly} gives an
4802 overview over all available note head styles.
4805 @node Ancient accidentals
4806 @subsection Ancient accidentals
4812 Use the @code{style} property of grob @internalsref{Accidental} to
4813 select ancient accidentals. Supported styles are
4814 @code{mensural}, @code{vaticana}, @code{hufnagel} and @code{medicaea}.
4816 @lilypond[raggedright,staffsize=26]
4824 { " " \musicglyph #"accidentals-vaticana-1"
4825 " " \musicglyph #"accidentals-vaticana0" }
4829 { " " \musicglyph #"accidentals-medicaea-1" }
4833 { " " \musicglyph #"accidentals-hufnagel-1" }
4837 { " " \musicglyph #"accidentals-mensural-1"
4838 " " \musicglyph #"accidentals-mensural1" }
4847 \remove "Bar_number_engraver"
4851 \remove "Clef_engraver"
4852 \remove "Key_engraver"
4853 \remove "Time_signature_engraver"
4854 \remove "Staff_symbol_engraver"
4855 minimumVerticalExtent = ##f
4861 As shown, not all accidentals are supported by each style. When
4862 trying to access an unsupported accidental, LilyPond will switch to a
4863 different style, as demonstrated in
4864 @inputfileref{input/test,ancient-accidentals.ly}.
4866 Similarly to local accidentals, the style of the key signature can be
4867 controlled by the @code{style} property of the
4868 @internalsref{KeySignature} grob.
4872 In this manual: @ref{Pitches}, @ref{Chromatic alterations} and
4873 @ref{Accidentals} give a general introduction into the use of
4874 accidentals. @ref{Key signature} gives a general introduction into
4875 the use of key signatures.
4877 Internals: @internalsref{KeySignature}.
4879 Examples: @inputfileref{input/test,ancient-accidentals.ly}.
4882 @subsection Ancient rests
4888 Use the @code{style} property of grob @internalsref{Rest} to select
4889 ancient accidentals. Supported styles are @code{classical},
4890 @code{neo_mensural} and @code{mensural}. @code{classical} differs
4891 from the @code{default} style only in that the quarter rest looks like
4892 a horizontally mirrored 8th rest. The @code{neo_mensural} style suits
4893 well for e.g. the incipit of a transcribed mensural piece of music.
4894 The @code{mensural} style finally mimics the appearance of rests as
4895 in historic prints of the 16th century.
4897 The following example demonstrates the @code{neo_mensural} style:
4899 @lilypond[fragment,raggedright,verbatim]
4900 \override Rest #'style = #'neo_mensural
4901 r\longa r\breve r1 r2 r4 r8 r16
4904 There are no 32th and 64th rests specifically for the mensural or
4905 neo-mensural style. Instead, the rests from the default style will be
4906 taken. See @inputfileref{input/test,rests.ly} for a chart of all
4909 There are no rests in Gregorian Chant notation; instead, it uses
4914 In this manual: @ref{Rests} gives a general introduction into the use of rests.
4918 @subsection Ancient clefs
4924 LilyPond supports a variety of clefs, many of them ancient.
4926 The following table shows all ancient clefs that are supported via the
4927 @code{\clef} command. Some of the clefs use the same glyph, but
4928 differ only with respect to the line they are printed on. In such
4929 cases, a trailing number in the name is used to enumerate these clefs.
4930 Still, you can manually force a clef glyph to be typeset on an
4931 arbitrary line, as described in @ref{Clef}. The note printed to the
4932 right side of each clef in the example column denotes the @code{c'}
4933 with respect to that clef.
4935 @multitable @columnfractions .3 .3 .3 .1
4939 @b{Description} @tab
4940 @b{Supported Clefs} @tab
4944 @code{clefs-neo_mensural_c} @tab
4945 modern style mensural C clef @tab
4946 @code{neo_mensural_c1}, @code{neo_mensural_c2},
4947 @code{neo_mensural_c3}, @code{neo_mensural_c4} @tab
4948 @lilypond[relative,notime]
4949 \override Staff.TimeSignature #'transparent = ##t
4950 \clef "neo_mensural_c2" c
4954 @code{clefs-petrucci_c1}
4955 @code{clefs-petrucci_c2}
4956 @code{clefs-petrucci_c3}
4957 @code{clefs-petrucci_c4}
4958 @code{clefs-petrucci_c5}
4961 petrucci style mensural C clefs, for use on different staff lines
4962 (the examples shows the 2nd staff line C clef).
4972 @lilypond[relative,notime]
4973 \override Staff.TimeSignature #'transparent = ##t
4974 \clef "petrucci_c2" c
4978 @code{clefs-petrucci_f} @tab
4979 petrucci style mensural F clef @tab
4980 @code{petrucci_f} @tab
4981 @lilypond[relative,notime]
4982 \override Staff.TimeSignature #'transparent = ##t
4983 \clef "petrucci_f" c
4987 @code{clefs-petrucci_g} @tab
4988 petrucci style mensural G clef @tab
4989 @code{petrucci_g} @tab
4990 @lilypond[relative,notime]
4991 \override Staff.TimeSignature #'transparent = ##t
4992 \clef "petrucci_g" c
4996 @code{clefs-mensural_c} @tab
4997 historic style mensural C clef @tab
4998 @code{mensural_c1}, @code{mensural_c2}, @code{mensural_c3},
4999 @code{mensural_c4} @tab
5000 @lilypond[relative,notime]
5001 \override Staff.TimeSignature #'transparent = ##t
5002 \clef "mensural_c2" c
5006 @code{clefs-mensural_f} @tab
5007 historic style mensural F clef @tab
5008 @code{mensural_f} @tab
5009 @lilypond[relative,notime]
5010 \override Staff.TimeSignature #'transparent = ##t
5011 \clef "mensural_f" c
5015 @code{clefs-mensural_g} @tab
5016 historic style mensural G clef @tab
5017 @code{mensural_g} @tab
5018 @lilypond[relative,notime]
5019 \override Staff.TimeSignature #'transparent = ##t
5020 \clef "mensural_g" c
5024 @code{clefs-vaticana_do} @tab
5025 Editio Vaticana style do clef @tab
5026 @code{vaticana_do1}, @code{vaticana_do2}, @code{vaticana_do3} @tab
5027 @lilypond[relative,notime]
5028 \override Staff.StaffSymbol #'line-count = #4
5029 \override Staff.TimeSignature #'transparent = ##t
5030 \clef "vaticana_do2" c
5034 @code{clefs-vaticana_fa} @tab
5035 Editio Vaticana style fa clef @tab
5036 @code{vaticana_fa1}, @code{vaticana_fa2} @tab
5037 @lilypond[relative,notime]
5038 \override Staff.StaffSymbol #'line-count = #4
5039 \override Staff.TimeSignature #'transparent = ##t
5040 \clef "vaticana_fa2" c
5044 @code{clefs-medicaea_do} @tab
5045 Editio Medicaea style do clef @tab
5046 @code{medicaea_do1}, @code{medicaea_do2}, @code{medicaea_do3} @tab
5047 @lilypond[relative,notime]
5048 \override Staff.StaffSymbol #'line-count = #4
5049 \override Staff.TimeSignature #'transparent = ##t
5050 \clef "medicaea_do2" c
5054 @code{clefs-medicaea_fa} @tab
5055 Editio Medicaea style fa clef @tab
5056 @code{medicaea_fa1}, @code{medicaea_fa2} @tab
5057 @lilypond[relative,notime]
5058 \override Staff.StaffSymbol #'line-count = #4
5059 \override Staff.TimeSignature #'transparent = ##t
5060 \clef "medicaea_fa2" c
5064 @code{clefs-hufnagel_do} @tab
5065 historic style hufnagel do clef @tab
5066 @code{hufnagel_do1}, @code{hufnagel_do2}, @code{hufnagel_do3} @tab
5067 @lilypond[relative,notime]
5068 \override Staff.StaffSymbol #'line-count = #4
5069 \override Staff.TimeSignature #'transparent = ##t
5070 \clef "hufnagel_do2" c
5074 @code{clefs-hufnagel_fa} @tab
5075 historic style hufnagel fa clef @tab
5076 @code{hufnagel_fa1}, @code{hufnagel_fa2} @tab
5077 @lilypond[relative,notime]
5078 \override Staff.StaffSymbol #'line-count = #4
5079 \override Staff.TimeSignature #'transparent = ##t
5080 \clef "hufnagel_fa2" c
5084 @code{clefs-hufnagel_do_fa} @tab
5085 historic style hufnagel combined do/fa clef @tab
5086 @code{hufnagel_do_fa} @tab
5087 @lilypond[relative,notime]
5088 \override Staff.TimeSignature #'transparent = ##t
5089 \clef "hufnagel_do_fa" c
5094 @c --- This should go somewhere else: ---
5095 @c @item modern style percussion clef (glyph: @code{clefs-percussion})
5098 @c @code{percussion}
5100 @c @lilypond{\override Staff.TimeSignature #'transparent = ##t \clef "percussion" c'}
5102 @c @item modern style tab clef (glyph: @code{clefs-tab})
5107 @c @lilypond{\context Staff \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #6 \override Staff.TimeSignature #'transparent = ##t \clef "tab" c'}
5109 @emph{Modern style} means ``as is typeset in contemporary editions of
5110 transcribed mensural music''.
5112 @emph{Petrucci style} means ``inspired by printings published by the
5113 famous engraver Petrucci (1466-1539)''.
5115 @emph{Historic style} means ``as was typeset or written in historic
5116 editions (other than those of Petrucci)''.
5118 @emph{Editio XXX style} means ``as is/was printed in Editio XXX''.
5120 Petrucci used C clefs with differently balanced left-side vertical
5121 beams, depending on which staff line it is printed.
5125 In this manual: for the percussion clef, see @ref{Percussion staves}.
5126 For the @code{TAB} clef, see @ref{Tablatures}.
5128 Internals: for modern clefs, see @ref{Clef}.
5132 The mensural g clef is temporarily mapped to the Petrucci g clef,
5133 until a new mensural g clef will have been implemented.
5138 @subsection Ancient flags
5144 Use the @code{flag-style} property of grob @internalsref{Stem} to
5145 select ancient flags. Besides the @code{default} flag style,
5146 only @code{mensural} style is supported:
5148 @lilypond[fragment,raggedright,verbatim]
5149 \override Stem #'flag-style = #'mensural
5150 \override Stem #'thickness = #1.0
5151 \override NoteHead #'style = #'mensural
5153 c'8 d'8 e'8 f'8 c'16 d'16 e'16 f'16 c'32 d'32 e'32 f'32 s8
5154 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5157 Note that the innermost flare of each mensural flag always is
5158 vertically aligned with a staff line. If you do not like this
5159 behavior, you can set the @code{adjust-if-on-staffline} property of
5160 grob @internalsref{Stem} to @code{##f}. Then, the vertical position
5161 of the end of each flare is different between notes on staff lines and
5162 notes between staff lines:
5164 @lilypond[fragment,raggedright]
5165 \override Stem #'flag-style = #'mensural
5166 \override Stem #'thickness = #1.0
5167 \override Stem #'adjust-if-on-staffline = ##f
5168 \override NoteHead #'style = #'mensural
5170 c'8 d'8 e'8 f'8 c'16 d'16 e'16 f'16 c'32 d'32 e'32 f'32 s8
5171 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5174 There is no particular flag style for neo-mensural notation. Hence,
5175 when typesetting e.g. the incipit of a transcribed piece of mensural
5176 music, the default flag style should be used. There are no flags in
5177 Gregorian Chant notation.
5180 @node Ancient time signatures
5181 @subsection Ancient time signatures
5183 @cindex time signatures
5187 There is limited support for mensural time signatures. The
5188 glyphs are hard-wired to particular time fractions. In other words,
5189 to get a particular mensural signature glyph with the @code{\time n/m}
5190 command, @code{n} and @code{m} have to be chosen according to the
5196 \set Score.timing = ##f
5197 \set Score.barAlways = ##t
5198 s_\markup { "$\\backslash$time 4/4" }
5199 ^\markup { " " \musicglyph #"timesig-neo_mensural4/4" }
5201 s_\markup { "$\\backslash$time 2/2" }
5202 ^\markup { " " \musicglyph #"timesig-neo_mensural2/2" }
5204 s_\markup { "$\\backslash$time 6/4" }
5205 ^\markup { " " \musicglyph #"timesig-neo_mensural6/4" }
5207 s_\markup { "$\\backslash$time 6/8" }
5208 ^\markup { " " \musicglyph #"timesig-neo_mensural6/8" }
5210 s_\markup { "$\\backslash$time 3/2" }
5211 ^\markup { " " \musicglyph #"timesig-neo_mensural3/2" }
5213 s_\markup { "$\\backslash$time 3/4" }
5214 ^\markup { " " \musicglyph #"timesig-neo_mensural3/4" }
5216 s_\markup { "$\\backslash$time 9/4" }
5217 ^\markup { " " \musicglyph #"timesig-neo_mensural9/4" }
5219 s_\markup { "$\\backslash$time 9/8" }
5220 ^\markup { " " \musicglyph #"timesig-neo_mensural9/8" }
5222 s_\markup { "$\\backslash$time 4/8" }
5223 ^\markup { " " \musicglyph #"timesig-neo_mensural4/8" }
5225 s_\markup { "$\\backslash$time 2/4" }
5226 ^\markup { " " \musicglyph #"timesig-neo_mensural2/4" }
5234 \remove Staff_symbol_engraver
5235 \remove Clef_engraver
5236 \remove Time_signature_engraver
5242 Use the @code{style} property of grob @internalsref{TimeSignature} to
5243 select ancient time signatures. Supported styles are
5244 @code{neo_mensural} and @code{mensural}. The above table uses the
5245 @code{neo_mensural} style. This style is appropriate e.g. for the
5246 incipit of transcriptions of mensural pieces. The @code{mensural}
5247 style mimics the look of historical printings of the 16th century.
5249 @inputfileref{input/test,time.ly} gives an overview over all available
5250 ancient and modern styles.
5254 Internals: @ref{Time signature} gives a general introduction into the use of time
5259 Mensural signature glyphs are mapped to time fractions in a
5260 hard-wired way. This mapping is sensible, but still arbitrary: given
5261 a mensural time signature, the time fraction represents a modern meter
5262 that usually will be a good choice when transcribing a mensural piece
5263 of music. For a particular piece of mensural music, however, the
5264 mapping may be unsatisfactory. In particular, the mapping assumes a
5265 fixed transcription of durations (e.g. brevis = half note in 2/2,
5266 i.e. 4:1). Some glyphs (such as the alternate glyph for 6/8 meter)
5267 are not at all accessible through the @code{\time} command.
5269 Mensural time signatures are supported typographically, but not yet
5270 musically. The internal representation of durations is
5271 based on a purely binary system; a ternary division such as 1 brevis =
5272 3 semibrevis (tempus perfectum) or 1 semibrevis = 3 minima (cum
5273 prolatione maiori) is not correctly handled: event times in ternary
5274 modes will be badly computed, resulting e.g. in horizontally
5275 misaligned note heads, and bar checks are likely to erroneously fail.
5277 The syntax and semantics of the @code{\time} command for mensural
5278 music is subject to change.
5281 @subsection Custodes
5286 A @emph{custos} (plural: @emph{custodes}; Latin word for `guard') is a
5287 symbol that appears at the end of a staff. It anticipates the pitch
5288 of the first note(s) of the following line and thus helps the player
5289 or singer to manage line breaks during performance, thus enhancing
5290 readability of a score.
5292 Custodes were frequently used in music notation until the 17th
5293 century. Nowadays, they have survived only in a few particular forms
5294 of musical notation such as contemporary editions of Gregorian chant
5295 like the @emph{editio vaticana}. There are different custos glyphs
5296 used in different flavors of notational style.
5300 For typesetting custodes, just put a @internalsref{Custos_engraver} into the
5301 @internalsref{Staff} context when declaring the @code{\paper} block,
5302 as shown in the following example:
5308 \consists Custos_engraver
5309 Custos \override #'style = #'mensural
5314 The result looks like this:
5320 \override Staff.Custos #'style = #'mensural
5327 \consists Custos_engraver
5334 The custos glyph is selected by the @code{style} property. The styles
5335 supported are @code{vaticana}, @code{medicaea}, @code{hufnagel} and
5336 @code{mensural}. They are demonstrated in the following fragment:
5346 { " " \musicglyph #"custodes-vaticana-u0" }
5350 { " " \musicglyph #"custodes-medicaea-u0" }
5354 { " " \musicglyph #"custodes-hufnagel-u0" }
5358 { " " \musicglyph #"custodes-mensural-u0" }
5367 \remove "Bar_number_engraver"
5371 \remove "Clef_engraver"
5372 \remove "Key_engraver"
5373 \remove "Time_signature_engraver"
5374 \remove "Staff_symbol_engraver"
5375 minimumVerticalExtent = ##f
5381 If the boolean property @code{adjust-if-on-staffline} is set to
5382 @code{#t} (which it is by default), lily typesets slightly different
5383 variants of the custos glyph, depending on whether the custos, is
5384 typeset on or between staff lines. The glyph will
5385 optically fit well into the staff, with the appendage on the right of
5386 the custos always ending at the same vertical position between two
5387 staff lines regardless of the pitch. If you set
5388 @code{adjust-if-on-staffline} to @code{#f}, then
5389 a compromise between both forms is used.
5391 Just like stems can be attached to note heads in two directions
5392 @emph{up} and @emph{down}, each custos glyph is available with its
5393 appendage pointing either up or down. If the pitch of a custos is
5394 above a selectable position, the appendage will point downwards; if
5395 the pitch is below this position, the appendage will point upwards.
5396 Use property @code{neutral-position} to select this position. By
5397 default, it is set to @code{0}, such that the neutral position is the
5398 center of the staff. Use property @code{neutral-direction} to control
5399 what happens if a custos is typeset on the neutral position itself.
5400 By default, this property is set to @code{-1}, such that the appendage
5401 will point downwards. If set to @code{1}, the appendage will point
5402 upwards. Other values such as @code{0} are reserved for future
5403 extensions and should not be used.
5407 Internals: @internalsref{Custos}.
5409 Examples: @inputfileref{input/regression,custos.ly}.
5413 @subsection Divisiones
5419 A @emph{divisio} (plural: @emph{divisiones}; Latin word for
5420 `division') is a staff context symbol that is used to structure
5421 Gregorian music into phrases and sections. The musical meaning of
5422 @emph{divisio minima}, @emph{divisio maior} and @emph{divisio maxima}
5423 can be characterized as short, medium and long pause, somewhat like
5424 @ref{Breath marks}. The @emph{finalis} sign not only marks the end of
5425 a chant, but is also frequently used within a single
5426 antiphonal/responsorial chant to mark the end of each section.
5430 To use divisiones, include the file @code{gregorian-init.ly}. It
5431 contains definitions that you can apply by just inserting
5432 @code{\divisioMinima}, @code{\divisioMaior}, @code{\divisioMaxima},
5433 and @code{\finalis} at proper places in the input. Some editions use
5434 @emph{virgula} or @emph{caesura} instead of divisio minima.
5435 Therefore, @code{gregorian-init.ly} also defines @code{\virgula} and
5438 @lilypondfile[]{divisiones.ly}
5442 @cindex @code{\virgula}
5444 @cindex @code{\caesura}
5446 @cindex @code{\divisioMinima}
5447 @code{\divisioMinima},
5448 @cindex @code{\divisioMaior}
5449 @code{\divisioMaior},
5450 @cindex @code{\divisioMaxima}
5451 @code{\divisioMaxima},
5452 @cindex @code{\finalis}
5457 In this manual: @ref{Breath marks}.
5459 Internals: @internalsref{BreathingSign}, @internalsref{BreathingSignEvent}.
5461 Examples: @inputfileref{input/test,divisiones.ly}.
5464 @subsection Ligatures
5468 @c TODO: Should double check if I recalled things correctly when I wrote
5469 @c down the following paragraph by heart.
5471 In musical terminology, a ligature is a coherent graphical symbol that
5472 represents at least two distinct notes. Ligatures originally appeared
5473 in the manuscripts of Gregorian chant notation roughly since the 9th
5474 century as an allusion to the accent symbols of Greek lyric poetry to
5475 denote ascending or descending sequences of notes. Both, the shape
5476 and the exact meaning of ligatures changed tremendously during the
5477 following centuries: In early notation, ligatures were used for
5478 monophonic tunes (Gregorian chant) and very soon denoted also the way
5479 of performance in the sense of articulation. With upcoming
5480 multiphony, the need for a metric system arised, since multiple voices
5481 of a piece have to be synchronized some way. New notation systems
5482 were invented that used the manifold shapes of ligatures to now denote
5483 rhythmical patterns (e.g. black mensural notation, mannered notation,
5484 ars nova). With the invention of the metric system of the white
5485 mensural notation, the need for ligatures to denote such patterns
5486 disappeared. Nevertheless, ligatures were still in use in the
5487 mensural system for a couple of decades until they finally disappeared
5488 during the late 16th / early 17th century. Still, ligatures have
5489 survived in contemporary editions of Gregorian chant such as the
5490 Editio Vaticana from 1905/08.
5494 Syntactically, ligatures are simply enclosed by @code{\[} and
5495 @code{\]}. Some ligature styles (such as Editio Vaticana) may need
5496 additional input syntax specific for this particular type of ligature.
5497 By default, the @internalsref{LigatureBracket} engraver just puts a
5498 square bracket above the ligature:
5500 @lilypond[raggedright,verbatim]
5502 \notes \transpose c c' {
5510 To select a specific style of ligatures, a proper ligature engraver
5511 has to be added to the @internalsref{Voice} context, as explained in
5512 the following subsections. Only white mensural ligatures
5513 are supported with certain limitations. Support for Editio Vaticana
5514 will be added in the future.
5517 * White mensural ligatures::
5518 * Gregorian square neumes ligatures::
5521 @node White mensural ligatures
5522 @subsubsection White mensural ligatures
5524 @cindex Mensural ligatures
5525 @cindex White mensural ligatures
5527 There is limited support for white mensural ligatures. The
5528 implementation is still experimental; it may output strange
5529 warnings or even crash in some cases or produce weird results on more
5534 To engrave white mensural ligatures, in the paper block the
5535 @internalsref{Mensural_ligature_engraver} has to be put into the
5536 @internalsref{Voice} context, and remove the
5537 @internalsref{Ligature_bracket_engraver}:
5543 \remove Ligature_bracket_engraver
5544 \consists Mensural_ligature_engraver
5549 There is no additional input language to describe the shape of a
5550 white mensural ligature. The shape is rather determined solely from
5551 the pitch and duration of the enclosed notes. While this approach may
5552 take a new user a while to get accustomed, it has the great advantage
5553 that the full musical information of the ligature is known internally.
5554 This is not only required for correct MIDI output, but also allows for
5555 automatic transcription of the ligatures.
5560 \set Score.timing = ##f
5561 \set Score.defaultBarType = "empty"
5562 \override NoteHead #'style = #'neo_mensural
5563 \override Staff.TimeSignature #'style = #'neo_mensural
5565 \[ g\longa c\breve a\breve f\breve d'\longa \]
5567 \[ e1 f1 a\breve g\longa \]
5569 @lilypond[raggedright]
5571 \notes \transpose c c' {
5572 \set Score.timing = ##f
5573 \set Score.defaultBarType = "empty"
5574 \override NoteHead #'style = #'neo_mensural
5575 \override Staff.TimeSignature #'style = #'neo_mensural
5577 \[ g\longa c\breve a\breve f\breve d'\longa \]
5579 \[ e1 f1 a\breve g\longa \]
5584 \remove Ligature_bracket_engraver
5585 \consists Mensural_ligature_engraver
5591 Without replacing @internalsref{Ligature_bracket_engraver} with
5592 @internalsref{Mensural_ligature_engraver}, the same music transcribes
5595 @lilypond[raggedright]
5597 \notes \transpose c c' {
5598 \set Score.timing = ##f
5599 \set Score.defaultBarType = "empty"
5600 \override NoteHead #'style = #'neo_mensural
5601 \override Staff.TimeSignature #'style = #'neo_mensural
5603 \[ g\longa c\breve a\breve f\breve d'\longa \]
5605 \[ e1 f1 a\breve g\longa \]
5611 @node Gregorian square neumes ligatures
5612 @subsubsection Gregorian square neumes ligatures
5614 @cindex Square neumes ligatures
5615 @cindex Gregorian square neumes ligatures
5617 Gregorian square neumes notation (following the style of the Editio
5618 Vaticana) is under heavy development, but not yet really usable for
5619 production purposes. Core ligatures can already be typeset, but
5620 essential issues for serious typesetting are still under development,
5621 such as (among others) horizontal alignment of multiple ligatures,
5622 lyrics alignment and proper accidentals handling. Still, this section
5623 gives a sneak preview of what Gregorian chant may look like once it
5626 The following table contains the extended neumes table of the 2nd
5627 volume of the Antiphonale Romanum (@emph{Liber Hymnarius}), published
5628 1983 by the monks of Solesmes.
5630 @multitable @columnfractions .4 .2 .2 .2
5633 @b{Neuma aut@*Neumarum Elementa} @tab
5634 @b{Figurae@*Rectae} @tab
5635 @b{Figurae@*Liquescentes Auctae} @tab
5636 @b{Figurae@*Liquescentes Deminutae}
5638 @c TODO: \paper block is identical in all of the below examples.
5639 @c Therefore, it should somehow be included rather than duplicated all
5642 @c why not make identifiers in ly/engraver-init.ly? --hwn
5644 @c Because it's just used to typeset plain notes without
5645 @c a staff for demonstration purposes rather than something
5646 @c special of Gregorian chant notation. --jr
5651 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.5\cm]
5652 \include "gregorian-init.ly"
5654 \notes \transpose c c' {
5657 \noBreak s^\markup {"a"} \noBreak
5659 % Punctum Inclinatum
5661 \noBreak s^\markup {"b"}
5667 \remove "Bar_number_engraver"
5671 \remove "Clef_engraver"
5672 \remove "Key_engraver"
5673 \override StaffSymbol #'transparent = ##t
5674 \remove "Time_signature_engraver"
5675 \remove "Bar_engraver"
5676 minimumVerticalExtent = ##f
5680 \remove Ligature_bracket_engraver
5681 \consists Vaticana_ligature_engraver
5682 \override NoteHead #'style = #'vaticana_punctum
5683 \override Stem #'transparent = ##t
5689 @lilypond[noindent,staffsize=26,nofragment,linewidth=2.5\cm]
5690 \include "gregorian-init.ly"
5692 \notes \transpose c c' {
5693 % Punctum Auctum Ascendens
5694 \[ \auctum \ascendens b \]
5695 \noBreak s^\markup {"c"} \noBreak
5697 % Punctum Auctum Descendens
5698 \[ \auctum \descendens b \]
5699 \noBreak s^\markup {"d"} \noBreak
5701 % Punctum Inclinatum Auctum
5702 \[ \inclinatum \auctum b \]
5703 \noBreak s^\markup {"e"}
5709 \remove "Bar_number_engraver"
5713 \remove "Clef_engraver"
5714 \remove "Key_engraver"
5715 \override StaffSymbol #'transparent = ##t
5716 \remove "Time_signature_engraver"
5717 \remove "Bar_engraver"
5718 minimumVerticalExtent = ##f
5722 \remove Ligature_bracket_engraver
5723 \consists Vaticana_ligature_engraver
5724 \override NoteHead #'style = #'vaticana_punctum
5725 \override Stem #'transparent = ##t
5731 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5732 \include "gregorian-init.ly"
5734 \notes \transpose c c' {
5735 % Punctum Inclinatum Parvum
5736 \[ \inclinatum \deminutum b \]
5737 \noBreak s^\markup {"f"}
5743 \remove "Bar_number_engraver"
5747 \remove "Clef_engraver"
5748 \remove "Key_engraver"
5749 \override StaffSymbol #'transparent = ##t
5750 \remove "Time_signature_engraver"
5751 \remove "Bar_engraver"
5752 minimumVerticalExtent = ##f
5756 \remove Ligature_bracket_engraver
5757 \consists Vaticana_ligature_engraver
5758 \override NoteHead #'style = #'vaticana_punctum
5759 \override Stem #'transparent = ##t
5768 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5769 \include "gregorian-init.ly"
5771 \notes \transpose c c' {
5774 \noBreak s^\markup {"g"}
5780 \remove "Bar_number_engraver"
5784 \remove "Clef_engraver"
5785 \remove "Key_engraver"
5786 \override StaffSymbol #'transparent = ##t
5787 \remove "Time_signature_engraver"
5788 \remove "Bar_engraver"
5789 minimumVerticalExtent = ##f
5793 \remove Ligature_bracket_engraver
5794 \consists Vaticana_ligature_engraver
5795 \override NoteHead #'style = #'vaticana_punctum
5796 \override Stem #'transparent = ##t
5805 @code{3. Apostropha vel Stropha}
5807 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5808 \include "gregorian-init.ly"
5810 \notes \transpose c c' {
5813 \noBreak s^\markup {"h"}
5819 \remove "Bar_number_engraver"
5823 \remove "Clef_engraver"
5824 \remove "Key_engraver"
5825 \override StaffSymbol #'transparent = ##t
5826 \remove "Time_signature_engraver"
5827 \remove "Bar_engraver"
5828 minimumVerticalExtent = ##f
5832 \remove Ligature_bracket_engraver
5833 \consists Vaticana_ligature_engraver
5834 \override NoteHead #'style = #'vaticana_punctum
5835 \override Stem #'transparent = ##t
5841 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5842 \include "gregorian-init.ly"
5844 \notes \transpose c c' {
5846 \[ \stropha \auctum b \]
5847 \noBreak s^\markup {"i"}
5853 \remove "Bar_number_engraver"
5857 \remove "Clef_engraver"
5858 \remove "Key_engraver"
5859 \override StaffSymbol #'transparent = ##t
5860 \remove "Time_signature_engraver"
5861 \remove "Bar_engraver"
5862 minimumVerticalExtent = ##f
5866 \remove Ligature_bracket_engraver
5867 \consists Vaticana_ligature_engraver
5868 \override NoteHead #'style = #'vaticana_punctum
5869 \override Stem #'transparent = ##t
5879 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5880 \include "gregorian-init.ly"
5882 \notes \transpose c c' {
5885 \noBreak s^\markup {"j"}
5891 \remove "Bar_number_engraver"
5895 \remove "Clef_engraver"
5896 \remove "Key_engraver"
5897 \override StaffSymbol #'transparent = ##t
5898 \remove "Time_signature_engraver"
5899 \remove "Bar_engraver"
5900 minimumVerticalExtent = ##f
5904 \remove Ligature_bracket_engraver
5905 \consists Vaticana_ligature_engraver
5906 \override NoteHead #'style = #'vaticana_punctum
5907 \override Stem #'transparent = ##t
5916 @code{5. Clivis vel Flexa}
5918 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5919 \include "gregorian-init.ly"
5921 \notes \transpose c c' {
5930 \remove "Bar_number_engraver"
5934 \remove "Clef_engraver"
5935 \remove "Key_engraver"
5936 \override StaffSymbol #'transparent = ##t
5937 \remove "Time_signature_engraver"
5938 \remove "Bar_engraver"
5939 minimumVerticalExtent = ##f
5943 \remove Ligature_bracket_engraver
5944 \consists Vaticana_ligature_engraver
5945 \override NoteHead #'style = #'vaticana_punctum
5946 \override Stem #'transparent = ##t
5952 @lilypond[noindent,staffsize=26,nofragment,linewidth=2.0\cm]
5953 \include "gregorian-init.ly"
5955 \notes \transpose c c' {
5956 % Clivis Aucta Descendens
5957 \[ b \flexa \auctum \descendens g \]
5958 \noBreak s^\markup {"l"} \noBreak
5960 % Clivis Aucta Ascendens
5961 \[ b \flexa \auctum \ascendens g \]
5962 \noBreak s^\markup {"m"}
5968 \remove "Bar_number_engraver"
5972 \remove "Clef_engraver"
5973 \remove "Key_engraver"
5974 \override StaffSymbol #'transparent = ##t
5975 \remove "Time_signature_engraver"
5976 \remove "Bar_engraver"
5977 minimumVerticalExtent = ##f
5981 \remove Ligature_bracket_engraver
5982 \consists Vaticana_ligature_engraver
5983 \override NoteHead #'style = #'vaticana_punctum
5984 \override Stem #'transparent = ##t
5990 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
5991 \include "gregorian-init.ly"
5993 \notes \transpose c c' {
5995 \[ b \flexa \deminutum g \]
6002 \remove "Bar_number_engraver"
6006 \remove "Clef_engraver"
6007 \remove "Key_engraver"
6008 \override StaffSymbol #'transparent = ##t
6009 \remove "Time_signature_engraver"
6010 \remove "Bar_engraver"
6011 minimumVerticalExtent = ##f
6015 \remove Ligature_bracket_engraver
6016 \consists Vaticana_ligature_engraver
6017 \override NoteHead #'style = #'vaticana_punctum
6018 \override Stem #'transparent = ##t
6025 @code{6. Podatus vel Pes}
6027 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6028 \include "gregorian-init.ly"
6030 \notes \transpose c c' {
6039 \remove "Bar_number_engraver"
6043 \remove "Clef_engraver"
6044 \remove "Key_engraver"
6045 \override StaffSymbol #'transparent = ##t
6046 \remove "Time_signature_engraver"
6047 \remove "Bar_engraver"
6048 minimumVerticalExtent = ##f
6052 \remove Ligature_bracket_engraver
6053 \consists Vaticana_ligature_engraver
6054 \override NoteHead #'style = #'vaticana_punctum
6055 \override Stem #'transparent = ##t
6061 @lilypond[noindent,staffsize=26,nofragment,linewidth=2.0\cm]
6062 \include "gregorian-init.ly"
6064 \notes \transpose c c' {
6065 % Pes Auctus Descendens
6066 \[ g \pes \auctum \descendens b \]
6067 \noBreak s^\markup {"p"} \noBreak
6069 % Pes Auctus Ascendens
6070 \[ g \pes \auctum \ascendens b \]
6071 \noBreak s^\markup {"q"}
6077 \remove "Bar_number_engraver"
6081 \remove "Clef_engraver"
6082 \remove "Key_engraver"
6083 \override StaffSymbol #'transparent = ##t
6084 \remove "Time_signature_engraver"
6085 \remove "Bar_engraver"
6086 minimumVerticalExtent = ##f
6090 \remove Ligature_bracket_engraver
6091 \consists Vaticana_ligature_engraver
6092 \override NoteHead #'style = #'vaticana_punctum
6093 \override Stem #'transparent = ##t
6099 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6100 \include "gregorian-init.ly"
6102 \notes \transpose c c' {
6104 \[ g \pes \deminutum b \]
6111 \remove "Bar_number_engraver"
6115 \remove "Clef_engraver"
6116 \remove "Key_engraver"
6117 \override StaffSymbol #'transparent = ##t
6118 \remove "Time_signature_engraver"
6119 \remove "Bar_engraver"
6120 minimumVerticalExtent = ##f
6124 \remove Ligature_bracket_engraver
6125 \consists Vaticana_ligature_engraver
6126 \override NoteHead #'style = #'vaticana_punctum
6127 \override Stem #'transparent = ##t
6134 @code{7. Pes Quassus}
6136 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6137 \include "gregorian-init.ly"
6139 \notes \transpose c c' {
6141 \[ \oriscus g \pes \virga b \]
6148 \remove "Bar_number_engraver"
6152 \remove "Clef_engraver"
6153 \remove "Key_engraver"
6154 \override StaffSymbol #'transparent = ##t
6155 \remove "Time_signature_engraver"
6156 \remove "Bar_engraver"
6157 minimumVerticalExtent = ##f
6161 \remove Ligature_bracket_engraver
6162 \consists Vaticana_ligature_engraver
6163 \override NoteHead #'style = #'vaticana_punctum
6164 \override Stem #'transparent = ##t
6170 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6171 \include "gregorian-init.ly"
6173 \notes \transpose c c' {
6174 % Pes Quassus Auctus Descendens
6175 \[ \oriscus g \pes \auctum \descendens b \]
6182 \remove "Bar_number_engraver"
6186 \remove "Clef_engraver"
6187 \remove "Key_engraver"
6188 \override StaffSymbol #'transparent = ##t
6189 \remove "Time_signature_engraver"
6190 \remove "Bar_engraver"
6191 minimumVerticalExtent = ##f
6195 \remove Ligature_bracket_engraver
6196 \consists Vaticana_ligature_engraver
6197 \override NoteHead #'style = #'vaticana_punctum
6198 \override Stem #'transparent = ##t
6206 @code{8. Quilisma Pes}
6208 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6209 \include "gregorian-init.ly"
6211 \notes \transpose c c' {
6213 \[ \quilisma g \pes b \]
6220 \remove "Bar_number_engraver"
6224 \remove "Clef_engraver"
6225 \remove "Key_engraver"
6226 \override StaffSymbol #'transparent = ##t
6227 \remove "Time_signature_engraver"
6228 \remove "Bar_engraver"
6229 minimumVerticalExtent = ##f
6233 \remove Ligature_bracket_engraver
6234 \consists Vaticana_ligature_engraver
6235 \override NoteHead #'style = #'vaticana_punctum
6236 \override Stem #'transparent = ##t
6242 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6243 \include "gregorian-init.ly"
6245 \notes \transpose c c' {
6246 % Quilisma Pes Auctus Descendens
6247 \[ \quilisma g \pes \auctum \descendens b \]
6254 \remove "Bar_number_engraver"
6258 \remove "Clef_engraver"
6259 \remove "Key_engraver"
6260 \override StaffSymbol #'transparent = ##t
6261 \remove "Time_signature_engraver"
6262 \remove "Bar_engraver"
6263 minimumVerticalExtent = ##f
6267 \remove Ligature_bracket_engraver
6268 \consists Vaticana_ligature_engraver
6269 \override NoteHead #'style = #'vaticana_punctum
6270 \override Stem #'transparent = ##t
6278 @code{9. Podatus Initio Debilis}
6280 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6281 \include "gregorian-init.ly"
6283 \notes \transpose c c' {
6284 % Pes Initio Debilis
6285 \[ \deminutum g \pes b \]
6292 \remove "Bar_number_engraver"
6296 \remove "Clef_engraver"
6297 \remove "Key_engraver"
6298 \override StaffSymbol #'transparent = ##t
6299 \remove "Time_signature_engraver"
6300 \remove "Bar_engraver"
6301 minimumVerticalExtent = ##f
6305 \remove Ligature_bracket_engraver
6306 \consists Vaticana_ligature_engraver
6307 \override NoteHead #'style = #'vaticana_punctum
6308 \override Stem #'transparent = ##t
6314 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6315 \include "gregorian-init.ly"
6317 \notes \transpose c c' {
6318 % Pes Auctus Descendens Initio Debilis
6319 \[ \deminutum g \pes \auctum \descendens b \]
6326 \remove "Bar_number_engraver"
6330 \remove "Clef_engraver"
6331 \remove "Key_engraver"
6332 \override StaffSymbol #'transparent = ##t
6333 \remove "Time_signature_engraver"
6334 \remove "Bar_engraver"
6335 minimumVerticalExtent = ##f
6339 \remove Ligature_bracket_engraver
6340 \consists Vaticana_ligature_engraver
6341 \override NoteHead #'style = #'vaticana_punctum
6342 \override Stem #'transparent = ##t
6352 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6353 \include "gregorian-init.ly"
6355 \notes \transpose c c' {
6357 \[ a \pes b \flexa g \]
6364 \remove "Bar_number_engraver"
6368 \remove "Clef_engraver"
6369 \remove "Key_engraver"
6370 \override StaffSymbol #'transparent = ##t
6371 \remove "Time_signature_engraver"
6372 \remove "Bar_engraver"
6373 minimumVerticalExtent = ##f
6377 \remove Ligature_bracket_engraver
6378 \consists Vaticana_ligature_engraver
6379 \override NoteHead #'style = #'vaticana_punctum
6380 \override Stem #'transparent = ##t
6386 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6387 \include "gregorian-init.ly"
6389 \notes \transpose c c' {
6390 % Torculus Auctus Descendens
6391 \[ a \pes b \flexa \auctum \descendens g \]
6398 \remove "Bar_number_engraver"
6402 \remove "Clef_engraver"
6403 \remove "Key_engraver"
6404 \override StaffSymbol #'transparent = ##t
6405 \remove "Time_signature_engraver"
6406 \remove "Bar_engraver"
6407 minimumVerticalExtent = ##f
6411 \remove Ligature_bracket_engraver
6412 \consists Vaticana_ligature_engraver
6413 \override NoteHead #'style = #'vaticana_punctum
6414 \override Stem #'transparent = ##t
6420 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6421 \include "gregorian-init.ly"
6423 \notes \transpose c c' {
6424 % Torculus Deminutus
6425 \[ a \pes b \flexa \deminutum g \]
6432 \remove "Bar_number_engraver"
6436 \remove "Clef_engraver"
6437 \remove "Key_engraver"
6438 \override StaffSymbol #'transparent = ##t
6439 \remove "Time_signature_engraver"
6440 \remove "Bar_engraver"
6441 minimumVerticalExtent = ##f
6445 \remove Ligature_bracket_engraver
6446 \consists Vaticana_ligature_engraver
6447 \override NoteHead #'style = #'vaticana_punctum
6448 \override Stem #'transparent = ##t
6455 @code{11. Torculus Initio Debilis}
6457 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6458 \include "gregorian-init.ly"
6460 \notes \transpose c c' {
6461 % Torculus Initio Debilis
6462 \[ \deminutum a \pes b \flexa g \]
6469 \remove "Bar_number_engraver"
6473 \remove "Clef_engraver"
6474 \remove "Key_engraver"
6475 \override StaffSymbol #'transparent = ##t
6476 \remove "Time_signature_engraver"
6477 \remove "Bar_engraver"
6478 minimumVerticalExtent = ##f
6482 \remove Ligature_bracket_engraver
6483 \consists Vaticana_ligature_engraver
6484 \override NoteHead #'style = #'vaticana_punctum
6485 \override Stem #'transparent = ##t
6491 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6492 \include "gregorian-init.ly"
6494 \notes \transpose c c' {
6495 % Torculus Auctus Descendens Initio Debilis
6496 \[ \deminutum a \pes b \flexa \auctum \descendens g \]
6503 \remove "Bar_number_engraver"
6507 \remove "Clef_engraver"
6508 \remove "Key_engraver"
6509 \override StaffSymbol #'transparent = ##t
6510 \remove "Time_signature_engraver"
6511 \remove "Bar_engraver"
6512 minimumVerticalExtent = ##f
6516 \remove Ligature_bracket_engraver
6517 \consists Vaticana_ligature_engraver
6518 \override NoteHead #'style = #'vaticana_punctum
6519 \override Stem #'transparent = ##t
6525 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6526 \include "gregorian-init.ly"
6528 \notes \transpose c c' {
6529 % Torculus Deminutus Initio Debilis
6530 \[ \deminutum a \pes b \flexa \deminutum g \]
6537 \remove "Bar_number_engraver"
6541 \remove "Clef_engraver"
6542 \remove "Key_engraver"
6543 \override StaffSymbol #'transparent = ##t
6544 \remove "Time_signature_engraver"
6545 \remove "Bar_engraver"
6546 minimumVerticalExtent = ##f
6550 \remove Ligature_bracket_engraver
6551 \consists Vaticana_ligature_engraver
6552 \override NoteHead #'style = #'vaticana_punctum
6553 \override Stem #'transparent = ##t
6560 @code{12. Porrectus}
6562 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6563 \include "gregorian-init.ly"
6565 \notes \transpose c c' {
6567 \[ a \flexa g \pes b \]
6574 \remove "Bar_number_engraver"
6578 \remove "Clef_engraver"
6579 \remove "Key_engraver"
6580 \override StaffSymbol #'transparent = ##t
6581 \remove "Time_signature_engraver"
6582 \remove "Bar_engraver"
6583 minimumVerticalExtent = ##f
6587 \remove Ligature_bracket_engraver
6588 \consists Vaticana_ligature_engraver
6589 \override NoteHead #'style = #'vaticana_punctum
6590 \override Stem #'transparent = ##t
6596 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6597 \include "gregorian-init.ly"
6599 \notes \transpose c c' {
6600 % Porrectus Auctus Descendens
6601 \[ a \flexa g \pes \auctum \descendens b \]
6608 \remove "Bar_number_engraver"
6612 \remove "Clef_engraver"
6613 \remove "Key_engraver"
6614 \override StaffSymbol #'transparent = ##t
6615 \remove "Time_signature_engraver"
6616 \remove "Bar_engraver"
6617 minimumVerticalExtent = ##f
6621 \remove Ligature_bracket_engraver
6622 \consists Vaticana_ligature_engraver
6623 \override NoteHead #'style = #'vaticana_punctum
6624 \override Stem #'transparent = ##t
6630 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6631 \include "gregorian-init.ly"
6633 \notes \transpose c c' {
6634 % Porrectus Deminutus
6635 \[ a \flexa g \pes \deminutum b \]
6642 \remove "Bar_number_engraver"
6646 \remove "Clef_engraver"
6647 \remove "Key_engraver"
6648 \override StaffSymbol #'transparent = ##t
6649 \remove "Time_signature_engraver"
6650 \remove "Bar_engraver"
6651 minimumVerticalExtent = ##f
6655 \remove Ligature_bracket_engraver
6656 \consists Vaticana_ligature_engraver
6657 \override NoteHead #'style = #'vaticana_punctum
6658 \override Stem #'transparent = ##t
6667 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6668 \include "gregorian-init.ly"
6670 \notes \transpose c c' {
6672 \[ \virga b \inclinatum a \inclinatum g \]
6679 \remove "Bar_number_engraver"
6683 \remove "Clef_engraver"
6684 \remove "Key_engraver"
6685 \override StaffSymbol #'transparent = ##t
6686 \remove "Time_signature_engraver"
6687 \remove "Bar_engraver"
6688 minimumVerticalExtent = ##f
6692 \remove Ligature_bracket_engraver
6693 \consists Vaticana_ligature_engraver
6694 \override NoteHead #'style = #'vaticana_punctum
6695 \override Stem #'transparent = ##t
6701 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6702 \include "gregorian-init.ly"
6704 \notes \transpose c c' {
6706 \[ \virga b \inclinatum a \inclinatum \auctum g \]
6713 \remove "Bar_number_engraver"
6717 \remove "Clef_engraver"
6718 \remove "Key_engraver"
6719 \override StaffSymbol #'transparent = ##t
6720 \remove "Time_signature_engraver"
6721 \remove "Bar_engraver"
6722 minimumVerticalExtent = ##f
6726 \remove Ligature_bracket_engraver
6727 \consists Vaticana_ligature_engraver
6728 \override NoteHead #'style = #'vaticana_punctum
6729 \override Stem #'transparent = ##t
6735 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6736 \include "gregorian-init.ly"
6738 \notes \transpose c c' {
6739 % Climacus Deminutus
6740 \[ \virga b \inclinatum a \inclinatum \deminutum g \]
6747 \remove "Bar_number_engraver"
6751 \remove "Clef_engraver"
6752 \remove "Key_engraver"
6753 \override StaffSymbol #'transparent = ##t
6754 \remove "Time_signature_engraver"
6755 \remove "Bar_engraver"
6756 minimumVerticalExtent = ##f
6760 \remove Ligature_bracket_engraver
6761 \consists Vaticana_ligature_engraver
6762 \override NoteHead #'style = #'vaticana_punctum
6763 \override Stem #'transparent = ##t
6770 @code{14. Scandicus}
6772 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6773 \include "gregorian-init.ly"
6775 \notes \transpose c c' {
6777 \[ g \pes a \virga b \]
6784 \remove "Bar_number_engraver"
6788 \remove "Clef_engraver"
6789 \remove "Key_engraver"
6790 \override StaffSymbol #'transparent = ##t
6791 \remove "Time_signature_engraver"
6792 \remove "Bar_engraver"
6793 minimumVerticalExtent = ##f
6797 \remove Ligature_bracket_engraver
6798 \consists Vaticana_ligature_engraver
6799 \override NoteHead #'style = #'vaticana_punctum
6800 \override Stem #'transparent = ##t
6806 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6807 \include "gregorian-init.ly"
6809 \notes \transpose c c' {
6810 % Scandicus Auctus Descendens
6811 \[ g \pes a \pes \auctum \descendens b \]
6818 \remove "Bar_number_engraver"
6822 \remove "Clef_engraver"
6823 \remove "Key_engraver"
6824 \override StaffSymbol #'transparent = ##t
6825 \remove "Time_signature_engraver"
6826 \remove "Bar_engraver"
6827 minimumVerticalExtent = ##f
6831 \remove Ligature_bracket_engraver
6832 \consists Vaticana_ligature_engraver
6833 \override NoteHead #'style = #'vaticana_punctum
6834 \override Stem #'transparent = ##t
6840 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6841 \include "gregorian-init.ly"
6843 \notes \transpose c c' {
6844 % Scandicus Deminutus
6845 \[ g \pes a \pes \deminutum b \]
6852 \remove "Bar_number_engraver"
6856 \remove "Clef_engraver"
6857 \remove "Key_engraver"
6858 \override StaffSymbol #'transparent = ##t
6859 \remove "Time_signature_engraver"
6860 \remove "Bar_engraver"
6861 minimumVerticalExtent = ##f
6865 \remove Ligature_bracket_engraver
6866 \consists Vaticana_ligature_engraver
6867 \override NoteHead #'style = #'vaticana_punctum
6868 \override Stem #'transparent = ##t
6877 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6878 \include "gregorian-init.ly"
6880 \notes \transpose c c' {
6882 \[ g \oriscus a \pes \virga b \]
6889 \remove "Bar_number_engraver"
6893 \remove "Clef_engraver"
6894 \remove "Key_engraver"
6895 \override StaffSymbol #'transparent = ##t
6896 \remove "Time_signature_engraver"
6897 \remove "Bar_engraver"
6898 minimumVerticalExtent = ##f
6902 \remove Ligature_bracket_engraver
6903 \consists Vaticana_ligature_engraver
6904 \override NoteHead #'style = #'vaticana_punctum
6905 \override Stem #'transparent = ##t
6911 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6912 \include "gregorian-init.ly"
6914 \notes \transpose c c' {
6915 % Salicus Auctus Descendens
6916 \[ g \oriscus a \pes \auctum \descendens b \]
6923 \remove "Bar_number_engraver"
6927 \remove "Clef_engraver"
6928 \remove "Key_engraver"
6929 \override StaffSymbol #'transparent = ##t
6930 \remove "Time_signature_engraver"
6931 \remove "Bar_engraver"
6932 minimumVerticalExtent = ##f
6936 \remove Ligature_bracket_engraver
6937 \consists Vaticana_ligature_engraver
6938 \override NoteHead #'style = #'vaticana_punctum
6939 \override Stem #'transparent = ##t
6949 @lilypond[noindent,staffsize=26,nofragment,linewidth=1.0\cm]
6950 \include "gregorian-init.ly"
6952 \notes \transpose c c' {
6954 \[ \stropha b \stropha b \stropha a \]
6961 \remove "Bar_number_engraver"
6965 \remove "Clef_engraver"
6966 \remove "Key_engraver"
6967 \override StaffSymbol #'transparent = ##t
6968 \remove "Time_signature_engraver"
6969 \remove "Bar_engraver"
6970 minimumVerticalExtent = ##f
6974 \remove Ligature_bracket_engraver
6975 \consists Vaticana_ligature_engraver
6976 \override NoteHead #'style = #'vaticana_punctum
6977 \override Stem #'transparent = ##t
6989 Unlike most other neumes notation systems, the input language for
6990 neumes does not necessarily reflect directly the typographical
6991 appearance, but is designed to solely focuse on musical meaning. For
6992 example, @code{\[ a \pes b \flexa g \]} produces a Torculus consisting
6993 of three Punctum heads, while @code{\[ a \flexa g \pes b \]} produces
6994 a Porrectus with a curved flexa shape and only a single Punctum head.
6995 There is no command to explicitly typeset the curved flexa shape; the
6996 decision of when to typeset a curved flexa shape is purely taken from
6997 the musical input. The idea of this approach is to separate the
6998 musical aspects of the input from the notation style of the output.
6999 This way, the same input can be reused to typeset the same music in a
7000 different style of Gregorian chant notation such as Hufnagel (also
7001 known as German gothic neumes) or Medicaea (kind of a very simple
7002 forerunner of the Editio Vaticana). As soon as Hufnagel ligature
7003 engraver and Medicaea ligature engraver will have been implemented, it
7004 will be as simple as replacing the ligature engraver in the
7005 @internalsref{Voice} context to get the desired notation style from
7008 The following table shows the code fragments that produce the
7009 ligatures in the above neumes table. The letter in the first column
7010 in each line of the below table indicates to which ligature in the
7011 above table it refers. The second column gives the name of the
7012 ligature. The third column shows the code fragment that produces this
7013 ligature, using @code{g}, @code{a} and @code{b} as example pitches.
7015 @multitable @columnfractions .1 .4 .5
7029 Punctum Inclinatum @tab
7030 @code{\[ \inclinatum b \]}
7034 Punctum Auctum Ascendens @tab
7035 @code{\[ \auctum \ascendens b \]}
7039 Punctum Auctum Descendens @tab
7040 @code{\[ \auctum \descendens b \]}
7044 Punctum Inclinatum Auctum @tab
7045 @code{\[ \inclinatum \auctum b \]}
7049 Punctum Inclinatum Parvum @tab
7050 @code{\[ \inclinatum \deminutum b \]}
7055 @code{\[ \virga b \]}
7060 @code{\[ \stropha b \]}
7065 @code{\[ \stropha \auctum b \]}
7070 @code{\[ \oriscus b \]}
7074 Clivis vel Flexa @tab
7075 @code{\[ b \flexa g \]}
7079 Clivis Aucta Descendens @tab
7080 @code{\[ b \flexa \auctum \descendens g \]}
7084 Clivis Aucta Ascendens @tab
7085 @code{\[ b \flexa \auctum \ascendens g \]}
7090 @code{\[ b \flexa \deminutum g \]}
7094 Podatus vel Pes @tab
7095 @code{\[ g \pes b \]}
7099 Pes Auctus Descendens @tab
7100 @code{\[ g \pes \auctum \descendens b \]}
7104 Pes Auctus Ascendens @tab
7105 @code{\[ g \pes \auctum \ascendens b \]}
7110 @code{\[ g \pes \deminutum b \]}
7115 @code{\[ \oriscus g \pes \virga b \]}
7119 Pes Quassus Auctus Descendens @tab
7120 @code{\[ \oriscus g \pes \auctum \descendens b \]}
7125 @code{\[ \quilisma g \pes b \]}
7129 Quilisma Pes Auctus Descendens @tab
7130 @code{\[ \quilisma g \pes \auctum \descendens b \]}
7134 Pes Initio Debilis @tab
7135 @code{\[ \deminutum g \pes b \]}
7139 Pes Auctus Descendens Initio Debilis @tab
7140 @code{\[ \deminutum g \pes \auctum \descendens b \]}
7145 @code{\[ a \pes b \flexa g \]}
7149 Torculus Auctus Descendens @tab
7150 @code{\[ a \pes b \flexa \auctum \descendens g \]}
7154 Torculus Deminutus @tab
7155 @code{\[ a \pes b \flexa \deminutum g \]}
7159 Torculus Initio Debilis @tab
7160 @code{\[ \deminutum a \pes b \flexa g \]}
7164 Torculus Auctus Descendens Initio Debilis @tab
7165 @code{\[ \deminutum a \pes b \flexa \auctum \descendens g \]}
7169 Torculus Deminutus Initio Debilis @tab
7170 @code{\[ \deminutum a \pes b \flexa \deminutum g \]}
7175 @code{\[ a \flexa g \pes b \]}
7179 Porrectus Auctus Descendens @tab
7180 @code{\[ a \flexa g \pes \auctum \descendens b \]}
7184 Porrectus Deminutus @tab
7185 @code{\[ a \flexa g \pes \deminutum b \]}
7190 @code{\[ \virga b \inclinatum a \inclinatum g \]}
7194 Climacus Auctus @tab
7195 @code{\[ \virga b \inclinatum a \inclinatum \auctum g \]}
7199 Climacus Deminutus @tab
7200 @code{\[ \virga b \inclinatum a \inclinatum \deminutum g \]}
7205 @code{\[ g \pes a \virga b \]}
7209 Scandicus Auctus Descendens @tab
7210 @code{\[ g \pes a \pes \auctum \descendens b \]}
7214 Scandicus Deminutus @tab
7215 @code{\[ g \pes a \pes \deminutum b \]}
7220 @code{\[ g \oriscus a \pes \virga b \]}
7224 Salicus Auctus Descendens @tab
7225 @code{\[ g \oriscus a \pes \auctum \descendens b \]}
7230 @code{\[ \stropha b \stropha b \stropha a \]}
7236 The following head prefixes are supported:
7238 @cindex @code{\virga}
7240 @cindex @code{\stropha}
7242 @cindex @code{\inclinatum}
7244 @cindex @code{\auctum}
7246 @cindex @code{\descendens}
7248 @cindex @code{\ascendens}
7250 @cindex @code{\oriscus}
7252 @cindex @code{\quilisma}
7254 @cindex @code{\deminutum}
7257 Head prefixes can be accumulated, though restrictions apply. For
7258 example, either @code{\descendens} or @code{\ascendens} can be applied
7259 to a head, but not both to the same head.
7262 @cindex @code{\flexa}
7263 Two adjacent heads can be tied together with the @code{\pes} and
7264 @code{\flexa} infix commands for a rising and falling line of melody,
7269 Trigonus: apply equal spacing, regardless of pitch.
7272 @subsection Figured bass
7274 @cindex Basso continuo
7276 @c TODO: musicological blurb about FB
7280 LilyPond has limited support for figured bass:
7282 @lilypond[verbatim,fragment]
7284 \context Voice \notes { \clef bass dis4 c d ais}
7285 \context FiguredBass
7287 < 6 >4 < 7 >8 < 6+ [_!] >
7293 The support for figured bass consists of two parts: there is an input
7294 mode, introduced by @code{\figures}, where you can enter bass figures
7295 as numbers, and there is a context called @internalsref{FiguredBass} that
7296 takes care of making @internalsref{BassFigure} objects.
7298 In figures input mode, a group of bass figures is delimited by
7299 @code{<} and @code{>}. The duration is entered after the @code{>>}:
7304 \context FiguredBass
7308 Accidentals are added when you append @code{-}, @code{!} and @code{+}
7315 \context FiguredBass
7316 \figures { <4- 6+ 7!> }
7319 Spaces or dashes may be inserted by using @code{_}. Brackets are
7320 introduced with @code{[} and @code{]}:
7326 \context FiguredBass
7327 \figures { < [4 6] 8 [_! 12]> }
7330 Although the support for figured bass may superficially resemble chord
7331 support, it works much simpler. The @code{\figures} mode simply
7332 stores the numbers , and @internalsref{FiguredBass} context prints
7333 them as entered. There is no conversion to pitches, and no
7334 realizations of the bass are played in the MIDI file.
7336 Internally, the code produces markup texts. You can use any of the
7337 markup text properties to override formatting. For example, the
7338 vertical spacing of the figures may be set with @code{baseline-skip}.
7342 Internals: @internalsref{BassFigureEvent} music, @internalsref{BassFigure} object,
7343 and @internalsref{FiguredBass} context.
7347 Slash notation for alterations is not supported.
7350 @node Vaticana style contexts
7351 @subsection Vaticana style contexts
7353 @cindex VaticanaVoiceContext
7354 @cindex VaticanaStaffContext
7356 The predefined @code{VaticanaVoiceContext} and
7357 @code{VaticanaStaffContext} can be used to easily engrave a piece of
7358 Gregorian Chant in the style of the Editio Vaticana. These contexts
7359 initialize all relevant context properties and grob properties to
7360 proper values. With these contexts, you can immediately go ahead
7361 entering the chant, as the following short excerpt demonstrates:
7363 @lilypond[raggedright,verbatim,noindent]
7364 \include "gregorian-init.ly"
7367 \context VaticanaVoice = "cantus" {
7368 \override Score.BarNumber #'transparent = ##t
7370 \[ c'\melisma c' \flexa a \] \[ a \flexa \deminutum g\melismaEnd \] f \divisioMinima
7371 \[ f\melisma \pes a c' c' \pes d'\melismaEnd \] c' \divisioMinima \break
7372 \[ c'\melisma c' \flexa a \] \[ a \flexa \deminutum g\melismaEnd \] f \divisioMinima
7375 \lyricsto "cantus" \new Lyrics \lyrics {
7376 San- ctus, San- ctus, San- ctus
7382 @node Contemporary notation
7383 @section Contemporary notation
7385 In the 20th century, composers have greatly expanded the musical
7386 vocabulary. With this expansion, many innovations in musical notation
7387 have been tried. The book by Stone (1980) gives a comprehensive
7388 overview (see @ref{Literature list}). In general, the use of new,
7389 innovative notation makes a piece harder to understand and perform and
7390 its use should therefore be avoided if possible. For this reason,
7391 support for contemporary notation in LilyPond is limited.
7400 @subsection Clusters
7404 In musical terminology, a @emph{cluster} denotes a range of
7405 simultaneously sounding pitches that may change over time. The set of
7406 available pitches to apply usually depends on the acoustic source.
7407 Thus, in piano music, a cluster typically consists of a continuous range
7408 of the semitones as provided by the piano's fixed set of a chromatic
7409 scale. In choral music, each singer of the choir typically may sing an
7410 arbitrary pitch within the cluster's range that is not bound to any
7411 diatonic, chromatic or other scale. In electronic music, a cluster
7412 (theoretically) may even cover a continuous range of pitches, thus
7413 resulting in colored noise, such as pink noise.
7415 Clusters can be denoted in the context of ordinary staff notation by
7416 engraving simple geometrical shapes that replace ordinary notation of
7417 notes. Ordinary notes as musical events specify starting time and
7418 duration of pitches; however, the duration of a note is expressed by the
7419 shape of the note head rather than by the horizontal graphical extent of
7420 the note symbol. In contrast, the shape of a cluster geometrically
7421 describes the development of a range of pitches (vertical extent) over
7422 time (horizontal extent). Still, the geometrical shape of a cluster
7423 covers the area in which any single pitch contained in the cluster would
7424 be notated as an ordinary note. From this point of view, it is
7425 reasonable to specify a cluster as the envelope of a set of notes.
7429 A cluster is engraved as the envelope of a set of
7430 cluster-notes. Cluster notes are created by applying the function
7431 @code{notes-to-clusters} to a sequence of chords, e.g.
7433 @lilypond[relative=1,verbatim]
7434 \apply #notes-to-clusters { <c e > <b f'> }
7437 The following example (from
7438 @inputfileref{input/regression,cluster.ly}) shows what the result
7441 @lilypondfile[]{cluster.ly}
7443 By default, @internalsref{Cluster_spanner_engraver} is in the
7444 @internalsref{Voice} context. This allows putting ordinary notes and
7445 clusters together in the same staff, even simultaneously. In such a
7446 case no attempt is made to automatically avoid collisions between
7447 ordinary notes and clusters.
7451 Internals: @internalsref{ClusterSpanner},
7452 @internalsref{ClusterSpannerBeacon},
7453 @internalsref{Cluster_spanner_engraver}, and
7454 @internalsref{ClusterNoteEvent}.
7456 Examples: @inputfileref{input/regression,cluster.ly}.
7460 Music expressions like @code{<< @{ g8 e8 @} a4 >>} are not printed
7461 accurately. Use @code{<g a>8 <e a>8} instead.
7466 @subsection Fermatas
7472 Contemporary music notation frequently uses special fermata symbols to
7473 indicate fermatas of differing lengths.
7477 The following are supported
7479 @lilypond[raggedright]
7481 << \addlyrics \notes {
7501 \context Lyrics \lyrics {
7502 "shortfermata" "fermata" "longfermata" "verylongfermata"
7507 See @ref{Articulations} for general instructions how to apply scripts
7508 such as fermatas to a @code{\notes@{@}} block.
7511 @node Special notation
7512 @section Special notation
7516 * Easy Notation note heads::
7520 @subsection Balloon help
7522 Elements of notation can be marked and named with the help of a square
7523 balloon. The primary purpose of this feature is to explain notation.
7525 The following example demonstrates its use.
7527 @lilypond[verbatim,fragment,raggedright,relative=1]
7530 #(add-balloon-text 'NoteHead "heads, or tails?"
7536 The function @code{add-balloon-text} takes the name of a grob, the
7537 label to print and where to put the label relative to the object. In
7538 the above example, the text ``heads or tails?'' ends 3 spaces below
7542 @cindex notation, explaining
7546 Internals: @internalsref{text-balloon-interface}.
7548 Examples: @inputfileref{input/regression,balloon.ly}.
7550 @node Easy Notation note heads
7551 @subsection Easy Notation note heads
7553 @cindex easy notation
7556 The `easy play' note head includes a note name inside the head. It is
7557 used in music aimed at beginners:
7559 @lilypond[raggedright,verbatim,staffsize=26]
7561 \notes { c'2 e'4 f' | g'1 }
7562 \paper { \translator { \EasyNotation } }
7566 The @code{EasyNotation} variable overrides a @internalsref{Score} @c
7567 context. To make the letters readable, it has to be printed in a
7568 large font size. To print with a larger font, see @ref{Font Size}.
7573 If you view the result with Xdvi, then staff lines may show through
7574 the letters. Printing the PostScript file obtained does produce the
7580 @section Tuning output
7582 There are situations where default layout decisions are not
7583 sufficient. In this section we discuss ways to override these
7586 Formatting is internally done by manipulating so called objects
7587 (graphic objects). Each object carries with it a set of properties
7588 (object or layout properties) specific to that object. For example, a
7589 stem object has properties that specify its direction, length and
7592 The most direct way of tuning the output is by altering the values of
7593 these properties. There are two ways of doing that: first, you can
7594 temporarily change the definition of one type of object, thus
7595 affecting a whole set of objects. Second, you can select one specific
7596 object, and set a layout property in that object.
7598 Do not confuse layout properties with translation
7599 properties. Translation properties always use a mixed caps style
7600 naming, and are manipulated using @code{\set} and @code{\unset}:
7602 \set Context.propertyName = @var{value}
7605 Layout properties are use Scheme style variable naming, i.e. lower
7606 case words separated with dashes. They are symbols, and should always
7607 be quoted using @code{#'}. For example, this could be an imaginary
7608 layout property name:
7610 #'layout-property-name
7615 The introduction of the @ref{Technical manual} gives a more in-depth
7616 treatment of the difference between translation and layout.
7620 * Constructing a tweak::
7627 @node Tuning objects
7628 @subsection Tuning objects
7630 @cindex object description
7632 The definition of an object is a list of default object
7633 properties. For example, the definition of the Stem object (available
7634 in @file{scm/define-grobs.scm}), includes the following definitions
7635 for @internalsref{Stem}:
7639 (beamed-lengths . (3.5 3.5 3.5 4.5 5.0))
7640 (Y-extent-callback . ,Stem::height)
7645 Adding variables on top of this existing definition overrides the
7646 system default, and alters the resulting appearance of the layout
7652 Changing a variable for only one object is commonly achieved with
7656 \once \override @var{context}.@var{objectname}
7657 @var{symbol} = @var{value}
7659 Here @var{symbol} is a Scheme expression of symbol type, @var{context}
7660 and @var{objectname} is a string and @var{value} is a Scheme expression.
7661 This command applies a setting only during one moment in the score.
7663 In the following example, only one @internalsref{Stem} object is
7664 changed from its original setting:
7666 @lilypond[verbatim,fragment,relative=1]
7668 \once \override Voice.Stem #'thickness = #4
7672 @cindex @code{\once}
7674 For changing more objects, the same command, without @code{\once} can
7677 \override @var{context}.@var{objectname} @var{symbol} = @var{value}
7679 This command adds @code{@var{symbol} = @var{value}} to the definition
7680 of @var{objectname} in the context @var{context}, and this definition
7681 stays in place until it is removed.
7683 An existing definition may be removed by the following command:
7686 \property @var{context}.@var{objectname} \revert @var{symbol}
7691 @lilypond[verbatim,quote]
7692 c'4 \override Stem #'thickness = #4.0
7694 c'4 \revert Stem #'thickness
7698 The following example gives exactly the same result as the previous
7699 one (assuming the system default for stem thickness is 1.3):
7701 @lilypond[verbatim,quote]
7702 c'4 \override Stem #'thickness = #4.0
7704 c'4 \override Stem #'thickness = #1.3
7708 Reverting a setting which was not set in the first place has no
7714 Internals: @internalsref{OverrideProperty}, @internalsref{RevertProperty},
7715 @internalsref{PropertySet}, @internalsref{All-backend-properties}, and
7716 @internalsref{All-layout-objects}.
7721 The back-end is not very strict in type-checking object properties.
7722 Cyclic references in Scheme values for properties can cause hangs
7726 * Constructing a tweak::
7732 @node Constructing a tweak
7733 @subsection Constructing a tweak
7736 @cindex internal documentation
7737 @cindex finding graphical objects
7738 @cindex graphical object descriptions
7740 @cindex @code{\override}
7742 @cindex internal documentation
7746 Three pieces of information are required to use @code{\override} and
7747 @code{\set}: the name of the layout object, the context and the name
7748 of the property. We demonstrate how to glean this information from
7749 the notation manual and the generated documentation.
7751 The generated documentation is a set of HTML pages which should be
7752 included if you installed a binary distribution, typically in
7753 @file{/usr/share/doc/lilypond}. They are also available on the web:
7754 go to the @uref{http://lilypond.org,LilyPond website}, click
7755 ``Documentation'', select the correct version, and click then
7756 ``Program reference.'' It is advisable to bookmark the local HTML
7757 files. They will load faster than the ones on the web. If you use the
7758 version from the web, you must check whether the documentation matches
7759 the program version: it is generated from the definitions that the
7760 program uses, and therefore it is strongly tied to the LilyPond
7764 @c [TODO: revise for new site.]
7766 Suppose we want to move the fingering indication in the fragment below:
7768 @lilypond[relative=2,verbatim]
7774 If you visit the documentation of @code{Fingering} (in @ref{Fingering
7775 instructions}), you will notice that there is written:
7780 Internals: @internalsref{FingerEvent} and @internalsref{Fingering}.
7787 In other words, the fingerings once entered, are internally stored as
7788 @code{FingerEvent} music objects. When printed, a @code{Fingering}
7789 layout object is created for every @code{FingerEvent}.
7791 The Fingering object has a number of different functions, and each of
7792 those is captured in an interface. The interfaces are listed under
7793 @internalsref{Fingering} in the program reference.
7797 The @code{Fingering} object has a fixed size
7798 (@internalsref{item-interface}), the symbol is a piece of text
7799 (@internalsref{text-interface}), whose font can be set
7800 (@internalsref{font-interface}). It is centered horizontally
7801 (@internalsref{self-alignment-interface}), it is placed next to other
7802 objects (@internalsref{side-position-interface}) vertically, and its
7803 placement is coordinated with other scripts
7804 (@internalsref{text-script-interface}). It also has the standard
7805 @internalsref{grob-interface} (grob stands for Graphical object)
7807 @cindex graphical object
7808 @cindex layout object
7809 @cindex object, layout
7810 with all the variables that come with
7811 it. Finally, it denotes a fingering instruction, so it has
7812 @internalsref{finger-interface}.
7814 For the vertical placement, we have to look under
7815 @code{side-position-interface}:
7817 @code{side-position-interface}
7819 Position a victim object (this one) next to other objects (the
7820 support). In this case, the property @code{direction} signifies where to put the
7821 victim object relative to the support (left or right, up or down?)
7826 below this description, the variable @code{padding} is described as
7830 (dimension, in staff space)
7832 add this much extra space between objects that are next to each
7833 other. Default value: @code{0.6}
7837 By increasing the value of @code{padding}, we can move away the
7838 fingering. The following command inserts 3 staff spaces of white
7839 between the note and the fingering:
7841 \once \override Fingering #'padding = #3
7844 Inserting this command before the Fingering object is created,
7845 i.e. before @code{c2}, yields the following result:
7847 @lilypond[relative=2,fragment,verbatim]
7848 \once \override Fingering
7855 The context name @code{Voice} in the example above can be determined
7856 as follows. In the documentation for @internalsref{Fingering}, it says
7858 Fingering grobs are created by: @internalsref{Fingering_engraver} @c
7861 Clicking @code{Fingering_engraver} shows the documentation of
7862 the module responsible for interpreting the fingering instructions and
7863 translating them to a @code{Fingering} object. Such a module is called
7864 an @emph{engraver}. The documentation of the @code{Fingering_engraver}
7867 Fingering_engraver is part of contexts: Voice
7869 so tuning the settings for Fingering should be done with
7871 \override Fingering @dots{}
7874 Of course, the tweak may also done in a larger context than
7875 @code{Voice}, for example, @internalsref{Staff} or
7876 @internalsref{Score}.
7880 Internals: the program reference also contains alphabetical lists of
7881 @internalsref{Contexts}, @internalsref{All-layout-objects} and
7882 @internalsref{Music-expressions}, so you can also find which objects
7883 to tweak by browsing the internals document.
7887 @subsection Applyoutput
7889 The most versatile way of tuning an object is @code{\applyoutput}. Its
7892 \applyoutput @var{proc}
7896 where @var{proc} is a Scheme function, taking three arguments.
7898 When interpreted, the function @var{proc} is called for every layout
7899 object found in the context, with the following arguments:
7901 @item the layout object itself,
7902 @item the context where the layout object was created, and
7903 @item the context where @code{\applyoutput} is processed.
7907 In addition, the cause of the layout object, i.e. the music
7908 expression or object that was responsible for creating it, is in the
7909 object property @code{cause}. For example, for a note head, this is a
7910 @internalsref{NoteHead} event, and for a @internalsref{Stem} object,
7911 this is a @internalsref{NoteHead} object.
7913 Here is a simple example of @code{\applyoutput}; it blanks note-heads on the
7916 (define (blanker grob grob-origin context)
7917 (if (and (memq (ly:grob-property grob 'interfaces)
7918 note-head-interface)
7919 (eq? (ly:grob-property grob 'staff-position) 0))
7921 (ly:grob-set-property! grob 'transparent #t)))
7926 @node Font selection
7927 @subsection Font selection
7929 The most common thing to change about the appearance of fonts is their
7930 size. The font size of any context can be easily changed by setting
7931 the @code{fontSize} property for that context. Its value is a number:
7932 negative numbers make the font smaller, positive numbers larger. An
7933 example is given below:
7935 @lilypond[fragment,relative=1,verbatim,quote]
7936 c4 c4 \set fontSize = #-1
7939 This command will set @code{font-size} (see below), and does
7940 not change the size of variable symbols, such as beams or slurs.
7942 One of the uses of @code{fontSize} is to get smaller symbols for cue
7943 notes. An elaborate example of those is in
7944 @inputfileref{input/test,cue-notes.ly}.
7946 @cindex magnification
7949 The font used for printing a object can be selected by setting
7950 @code{font-name}, e.g.
7952 \override Staff.TimeSignature
7953 #'font-name = #"cmr17"
7957 Any font can be used, as long as it is available to @TeX{}. Possible
7958 fonts include foreign fonts or fonts that do not belong to the
7959 Computer Modern font family. The size of fonts selected in this way
7960 can be changed with the @code{font-magnification} property. For
7961 example, @code{2.0} blows up all letters by a factor 2 in both
7965 @cindex font magnification
7967 Font selection for the standard fonts, @TeX{}'s Computer Modern fonts,
7968 can also be adjusted with a more fine-grained mechanism. By setting
7969 the object properties described below, you can select a different font;
7970 all three mechanisms work for every object that supports
7971 @code{font-interface}:
7976 is a symbol indicating the general class of the typeface. Supported are
7977 @code{roman} (Computer Modern), @code{braces} (for piano staff
7978 braces), @code{music} (the standard music font, including ancient
7979 glyphs), @code{dynamic} (for dynamic signs) and @code{typewriter}.
7982 is a symbol indicating the shape of the font, there are typically several
7983 font shapes available for each font family. Choices are @code{italic},
7984 @code{caps} and @code{upright}.
7987 is a symbol indicating the series of the font. There are typically several
7988 font series for each font family and shape. Choices are @code{medium}
7993 For any of these properties, the value @code{*} (i.e. the symbol
7994 @code{*}, entered as @code{#'*}), acts as a wildcard. This can be used
7995 to override default setting, which are always present. For example:
7997 \override Lyrics .LyricText #'font-series = #'bold
7998 \override Lyrics .LyricText #'font-family = #'typewriter
7999 \override Lyrics .LyricText #'font-shape = #'*
8002 @cindex @code{font-style}
8004 The font size is set by modifying the @code{font-size} property. Its
8005 value is a number indicating the size relative to the standard size.
8006 Each step up is an increase of approximately 12% of the font size. Six
8007 steps is exactly a factor two. The Scheme function @code{magstep}
8008 converts a @code{font-size} number to a scaling factor.
8010 LilyPond has fonts in different design sizes: the music fonts for
8011 smaller sizes are chubbier, while the text fonts are relatively wider.
8012 Font size changes are achieved by scaling the design size that is
8013 closest to the desired size.
8015 The @code{font-size} mechanism does not work for fonts selected
8016 through @code{font-name}. These may be scaled with
8017 @code{font-magnification}.
8021 The following commands set @code{fontSize} for the current voice.
8023 @cindex @code{\tiny}
8025 @cindex @code{\small}
8027 @cindex @code{\normalsize}
8032 Init files: @file{ly/declarations-init.ly} contains hints how new
8033 fonts may be added to LilyPond.
8037 There is no style sheet provided for other fonts besides the @TeX{}
8038 Computer Modern family.
8040 @cindex font selection
8041 @cindex font magnification
8042 @cindex @code{font-interface}
8046 @section Text markup
8051 @cindex typeset text
8053 LilyPond has an internal mechanism to typeset texts. You can access it
8054 with the keyword @code{\markup}. Within markup mode, you can enter texts
8055 similar to lyrics: simply enter them, surrounded by spaces:
8058 @lilypond[verbatim,fragment,relative=1]
8059 c1^\markup { hello }
8060 c1_\markup { hi there }
8061 c1^\markup { hi \bold there, is \italic anyone home? }
8064 @cindex font switching
8066 The markup in the example demonstrates font switching commands. The
8067 command @code{\bold} and @code{\italic} only apply to the first
8068 following word; enclose a set of texts with braces to apply a command
8071 \markup @{ \bold @{ hi there @} @}
8075 For clarity, you can also do this for single arguments, e.g.
8078 \markup { is \italic { anyone } home }
8081 @cindex font size, texts
8084 In markup mode you can compose expressions, similar to mathematical
8085 expressions, XML documents and music expressions. The braces group
8086 notes into horizontal lines. Other types of lists also exist: you can
8087 stack expressions grouped with @code{<}, and @code{>} vertically with
8088 the command @code{\column}. Similarly, @code{\center-align} aligns
8089 texts by their center lines:
8091 @lilypond[verbatim,fragment,relative=1]
8092 c1^\markup { \column < a bbbb c > }
8093 c1^\markup { \center-align < a bbbb c > }
8094 c1^\markup { \line < a b c > }
8098 Markups can be stored in variables, and these variables
8099 may be attached to notes, like
8101 allegro = \markup { \bold \large { Allegro } }
8102 \notes { a^\allegro b c d }
8106 Some objects have alignment procedures of their own, which cancel out
8107 any effects of alignments applied to their markup arguments as a
8108 whole. For example, the @internalsref{RehearsalMark} is horizontally
8109 centered, so using @code{\mark \markup @{ \left-align .. @}} has no
8110 effect. Similarly, whole texts over notes cannot be moved vertically
8111 with @code{\raise}. For moving and aligning complete objects, grob
8112 properties should be used.
8118 Init files: @file{scm/new-markup.scm}.
8123 Text layout is ultimately done by @TeX{}, which does kerning of
8124 letters. LilyPond does not account for kerning, so texts will be
8125 spaced slightly too wide.
8127 Syntax errors for markup mode are confusing.
8129 Markup texts cannot be used in the titling of the @code{\header}
8130 field. Titles are made by La@TeX{}, so La@TeX{} commands should be used
8136 * Overview of text markup commands::
8137 * Markup construction in scheme::
8138 * Markup command definition::
8141 @node Overview of text markup commands
8142 @subsection Overview of text markup commands
8144 @include markup-commands.tely
8146 @node Markup construction in scheme
8147 @subsection Markup construction in scheme
8149 @cindex defining markup commands
8151 The @code{markup} macro builds markup expressions in Scheme while
8152 providing a LilyPond-like syntax. For example,
8154 (markup #:column (#:line (#:bold #:italic "hello" #:raise 0.4 "world")
8155 #:bigger #:line ("foo" "bar" "baz")))
8161 \markup \column < @{ \bold \italic "hello" \raise #0.4 "world" @}
8162 \bigger @{ foo bar baz @} >
8166 This example exposes the main translation rules between regular
8167 LilyPond markup syntax and scheme markup syntax, which are summed up
8169 @multitable @columnfractions .5 .5
8170 @item @b{LilyPond} @tab @b{Scheme}
8171 @item @code{\command} @tab @code{#:command}
8172 @item @code{\variable} @tab @code{variable}
8173 @item @code{@{ ... @}} @tab @code{#:line ( ... )}
8174 @item @code{\center-align < ... >} @tab @code{#:center ( ... )}
8175 @item @code{string} @tab @code{"string"}
8176 @item @code{#scheme-arg} @tab @code{scheme-arg}
8179 Besides, the whole scheme language is accessible inside the
8180 @code{markup} macro: thus, one may use function calls inside
8181 @code{markup} in order to manipulate character strings for
8182 instance. This proves useful when defining new markup commands (see
8183 @ref{Markup command definition}).
8187 One can not feed the @code{#:line} (resp @code{#:center},
8188 @code{#:column}) command with a variable or the result of a function
8191 (markup #:line (fun-that-returns-markups))
8193 is illegal. One should use the @code{make-line-markup} (resp
8194 @code{make-center-markup}, @code{make-column-markup}) function
8197 (markup (make-line-markup (fun-that-returns-markups)))
8200 @node Markup command definition
8201 @subsection Markup command definition
8203 New markup commands can be defined thanks to the @code{def-markup-command} scheme macro.
8205 (def-markup-command (@var{command-name} @var{paper} @var{props} @var{arg1} @var{arg2} ...)
8206 (@var{arg1-type?} @var{arg2-type?} ...)
8209 @var{argi}: i@var{th} command argument
8210 @var{argi-type?}: a type predicate for the i@var{th} argument
8211 @var{paper}: the `paper' definition
8212 @var{props}: a list of alists, containing all active properties.
8215 As a simple example, we show how to add a @code{\smallcaps} command,
8216 which selects @TeX{}'s small caps font. Normally, we could select the
8217 small caps font as follows:
8220 \markup { \override #'(font-shape . caps) Text-in-caps }
8223 This selects the caps font by setting the @code{font-shape} property to
8224 @code{#'caps} for interpreting @code{Text-in-caps}.
8226 To make the above available as @code{\smallcaps} command, we have to
8227 define a function using @code{def-markup-command}. The command should
8228 take a single argument, of markup type. Therefore, the start of the
8229 definition should read
8231 (def-markup-command (smallcaps paper props argument) (markup?)
8236 What follows is the content of the command: we should interpret
8237 the @code{argument} as a markup, i.e.
8240 (interpret-markup paper @dots{} argument)
8244 This interpretation should add @code{'(font-shape . caps)} to the active
8245 properties, so we substitute the the following for the @dots{} in the
8249 (cons (list '(font-shape . caps) ) props)
8253 The variable @code{props} is a list of alists, and we prepend to it by
8254 consing a list with the extra setting.
8256 However, suppose that we are using a font that does not have a
8257 small-caps variant. In that case, we have to fake the small caps font,
8258 by setting a string in upcase, with the first letter a little larger:
8261 #(def-markup-command (smallcaps paper props str) (string?)
8262 "Print the string argument in small caps. Syntax: \\smallcaps #\"string\""
8263 (interpret-markup paper props
8266 (if (= (string-length s) 0)
8268 (markup #:large (string-upcase (substring s 0 1))
8269 #:translate (cons -0.6 0)
8270 #:tiny (string-upcase (substring s 1)))))
8271 (string-split str #\Space)))))
8274 The @code{smallcaps} command first splits its string argument into
8275 tokens separated by spaces (@code{(string-split str #\Space)}); for
8276 each token, a markup is built with the first letter made large and
8277 upcased (@code{#:large (string-upcase (substring s 0 1))}), and a
8278 second markup built with the following letters made tiny and upcased
8279 (@code{#:tiny (string-upcase (substring s 1))}). As LilyPond
8280 introduces a space between markups on a line, the second markup is
8281 translated to the left (@code{#:translate (cons -0.6 0) ...}). Then,
8282 the markups built for each token are put in a line
8283 (@code{(make-line-markup ...)}). Finally, the resulting markup is
8284 passed to the @code{interpret-markup} function, with the @code{paper}
8285 and @code{props} arguments.
8287 Finally, suppose that we are typesetting a recitative in an opera, and
8288 we would like to define a command that will show character names in a
8289 custom manner. Names should be printed with small caps and translated a
8290 bit to the left and top. We will define a @code{\character} command
8291 that takes into account the needed translation, and uses the newly
8292 defined @code{\smallcaps} command:
8295 #(def-markup-command (character paper props name) (string?)
8296 "Print the character name in small caps, translated to the left and
8297 top. Syntax: \\character #\"name\""
8298 (interpret-markup paper props
8299 (markup "" #:translate (cons -4 2) #:smallcaps name)))
8302 There is one complication that needs explanation: texts above and below
8303 the staff are moved vertically to be at a certain distance (the
8304 @code{padding} property) from the staff and the notes. To make sure
8305 that this mechanism does not annihilate the vertical effect of our
8306 @code{#:translate}, we add an empty string (@code{""}) before the
8307 translated text. Now the @code{""} will be put above the notes, and the
8308 @code{name} is moved in relation to that empty string. The net effect is
8309 that the text is moved to the upper left.
8311 The final result is as follows:
8315 c''^\markup \character #"Cleopatra"
8316 e'^\markup \character #"Giulio Cesare"
8321 @lilypond[raggedright]
8322 #(def-markup-command (smallcaps paper props str) (string?)
8323 "Print the string argument in small caps. Syntax: \\smallcaps #\"string\""
8324 (interpret-markup paper props
8327 (if (= (string-length s) 0)
8329 (markup #:large (string-upcase (substring s 0 1))
8330 #:translate (cons -0.6 0)
8331 #:tiny (string-upcase (substring s 1)))))
8332 (string-split str #\Space)))))
8334 #(def-markup-command (character paper props name) (string?)
8335 "Print the character name in small caps, translated to the left and
8336 top. Syntax: \\character #\"name\""
8337 (interpret-markup paper props
8338 (markup "" #:translate (cons -4 0) #:smallcaps name)))
8342 c''^\markup \character #"Cleopatra"
8343 e'^\markup \character #"Giulio Cesare"
8351 @section Global layout
8353 The global layout determined by three factors: the page layout, the
8354 line breaks and the spacing. These all influence each other. The
8355 choice of spacing determines how densely each system of music is set,
8356 which influences where line breaks breaks are chosen, and thus
8357 ultimately how many pages a piece of music takes. This section
8358 explains how to tune the algorithm for spacing.
8360 Globally spoken, this procedure happens in three steps: first,
8361 flexible distances (``springs'') are chosen, based on durations. All
8362 possible line breaking combination are tried, and the one with the
8363 best results---a layout that has uniform density and requires as
8364 little stretching or cramping as possible---is chosen. When the score
8365 is processed by @TeX{}, each page is filled with systems, and page breaks
8366 are chosen whenever the page gets full.
8371 * Vertical spacing::
8372 * Horizontal spacing::
8379 @node Vertical spacing
8380 @subsection Vertical spacing
8382 @cindex vertical spacing
8383 @cindex distance between staves
8384 @cindex staff distance
8385 @cindex between staves, distance
8386 @cindex staffs per page
8387 @cindex space between staves
8389 The height of each system is determined automatically by LilyPond, to
8390 keep systems from bumping into each other, some minimum distances are
8391 set. By changing these, you can put staves closer together, and thus
8392 put more systems onto one page.
8394 Normally staves are stacked vertically. To make
8395 staves maintain a distance, their vertical size is padded. This is
8396 done with the property @code{minimumVerticalExtent}. It takes a pair
8397 of numbers, so if you want to make it smaller from its, then you could
8400 \set Staff.minimumVerticalExtent = #'(-4 . 4)
8402 This sets the vertical size of the current staff to 4 staff spaces on
8403 either side of the center staff line. The argument of
8404 @code{minimumVerticalExtent} is interpreted as an interval, where the
8405 center line is the 0, so the first number is generally negative. The
8406 staff can be made larger at the bottom by setting it to @code{(-6
8409 The piano staves are handled a little differently: to make cross-staff
8410 beaming work correctly, it is necessary that the distance between staves
8411 is fixed beforehand. This is also done with a
8412 @internalsref{VerticalAlignment} object, created in
8413 @internalsref{PianoStaff}. In this object the distance between the
8414 staves is fixed by setting @code{forced-distance}. If you want to
8415 override this, use a @code{\translator} block as follows:
8420 \override VerticalAlignment #'forced-distance = #9
8425 This would bring the staves together at a distance of 9 staff spaces,
8426 measured from the center line of each staff.
8430 Internals: Vertical alignment of staves is handled by the
8431 @internalsref{VerticalAlignment} object.
8436 @node Horizontal spacing
8437 @subsection Horizontal Spacing
8439 The spacing engine translates differences in durations into
8440 stretchable distances (``springs'') of differing lengths. Longer
8441 durations get more space, shorter durations get less. The shortest
8442 durations get a fixed amount of space (which is controlled by
8443 @code{shortest-duration-space} in the @internalsref{SpacingSpanner} object).
8444 The longer the duration, the more space it gets: doubling a
8445 duration adds a fixed amount (this amount is controlled by
8446 @code{spacing-increment}) of space to the note.
8448 For example, the following piece contains lots of half, quarter and
8449 8th notes, the eighth note is followed by 1 note head width (NHW).
8450 The quarter note is followed by 2 NHW, the half by 3 NHW, etc.
8451 @lilypond[fragment,verbatim,relative=1] c2 c4. c8 c4. c8 c4. c8 c8
8455 Normally, @code{shortest-duration-space} is set to 1.2, which is the
8456 width of a note head, and @code{shortest-duration-space} is set to
8457 2.0, meaning that the shortest note gets 2 NHW (i.e. 2 times
8458 @code{shortest-duration-space}) of space. For normal notes, this space
8459 is always counted from the left edge of the symbol, so the shortest
8460 notes are generally followed by one NHW of space.
8462 If one would follow the above procedure exactly, then adding a single
8463 32th note to a score that uses 8th and 16th notes, would widen up the
8464 entire score a lot. The shortest note is no longer a 16th, but a 32nd,
8465 thus adding 1 NHW to every note. To prevent this, the
8466 shortest duration for spacing is not the shortest note in the score,
8467 but the most commonly found shortest note. Notes that are even
8468 shorter this are followed by a space that is proportional to their
8469 duration relative to the common shortest note. So if we were to add
8470 only a few 16th notes to the example above, they would be followed by
8473 @lilypond[fragment,verbatim,relative=2]
8474 c2 c4. c8 c4. c16[ c] c4. c8 c8 c8 c4 c4 c4
8477 The most common shortest duration is determined as follows: in every
8478 measure, the shortest duration is determined. The most common short
8479 duration, is taken as the basis for the spacing, with the stipulation
8480 that this shortest duration should always be equal to or shorter than
8481 1/8th note. The shortest duration is printed when you run lilypond
8482 with @code{--verbose}. These durations may also be customized. If you
8483 set the @code{common-shortest-duration} in
8484 @internalsref{SpacingSpanner}, then this sets the base duration for
8485 spacing. The maximum duration for this base (normally 1/8th), is set
8486 through @code{base-shortest-duration}.
8488 @cindex @code{common-shortest-duration}
8489 @cindex @code{base-shortest-duration}
8490 @cindex @code{stem-spacing-correction}
8491 @cindex @code{spacing}
8493 In the introduction it was explained that stem directions influence
8494 spacing. This is controlled with @code{stem-spacing-correction}
8495 property in @internalsref{NoteSpacing}, which are generated for every
8496 @internalsref{Voice} context. The @code{StaffSpacing} object
8497 (generated at @internalsref{Staff} context) contains the same property
8498 for controlling the stem/bar line spacing. The following example
8499 shows these corrections, once with default settings, and once with
8500 exaggerated corrections:
8506 \override Staff.NoteSpacing #'stem-spacing-correction
8508 \override Staff.StaffSpacing #'stem-spacing-correction
8513 \paper { raggedright = ##t } }
8516 @cindex SpacingSpanner, overriding properties
8518 Properties of the @internalsref{SpacingSpanner} must be overridden
8519 from the @code{\paper} block, since the @internalsref{SpacingSpanner} is
8520 created before any property commands are interpreted.
8522 \paper @{ \translator @{
8524 SpacingSpanner \override #'spacing-increment = #3.0
8531 Internals: @internalsref{SpacingSpanner}, @internalsref{NoteSpacing},
8532 @internalsref{StaffSpacing}, @internalsref{SeparationItem}, and
8533 @internalsref{SeparatingGroupSpanner}.
8537 Spacing is determined on a score wide basis. If you have a score that
8538 changes its character (measured in durations) halfway during the
8539 score, the part containing the longer durations will be spaced too
8542 There is no convenient mechanism to manually override spacing.
8547 @subsection Font size
8548 @cindex font size, setting
8549 @cindex staff size, setting
8550 @cindex @code{paper} file
8552 The Feta font provides musical symbols at eight seven different
8553 sizes. Each font is tuned for a different staff size: at smaller sizes
8554 the font gets heavier, to match the relatively heavier staff lines.
8555 The recommended font sizes are listed in the following table:
8557 @multitable @columnfractions .25 .25 .25 .25
8560 @tab @b{staff height (pt)}
8561 @tab @b{staff height (mm)}
8603 @c modern rental material ?
8607 These fonts are available in any sizes. The context property
8608 @code{fontSize} and the layout property @code{staff-space} (in
8609 @internalsref{StaffSymbol}) can be used to tune size for individual
8610 staffs. The size of individual staffs are relative to the global size,
8611 which can be set in the following manner:
8614 #(set-global-staff-size 14)
8617 This sets the global default size to 14pt staff height, and scales all
8623 @subsection Line breaking
8626 @cindex breaking lines
8628 Line breaks are normally computed automatically. They are chosen such
8629 that lines look neither cramped nor loose, and that consecutive lines
8630 have similar density.
8632 Occasionally you might want to override the automatic breaks; you can
8633 do this by specifying @code{\break}. This will force a line break at
8634 this point. Line breaks can only occur at places where there are bar
8635 lines. If you want to have a line break where there is no bar line,
8636 you can force an invisible bar line by entering @code{\bar
8637 ""}. Similarly, @code{\noBreak} forbids a line break at a
8641 @cindex regular line breaks
8642 @cindex four bar music.
8644 For line breaks at regular intervals use @code{\break} separated by
8645 skips and repeated with @code{\repeat}:
8647 << \repeat unfold 7 @{
8648 s1 \noBreak s1 \noBreak
8649 s1 \noBreak s1 \break @}
8650 @emph{the real music}
8655 This makes the following 28 measures (assuming 4/4 time) be broken every
8656 4 measures, and only there.
8660 @code{\break}, @code{\noBreak}
8661 @cindex @code{\break}
8662 @cindex @code{\noBreak}
8666 Internals: @internalsref{BreakEvent}.
8670 @subsection Page layout
8673 @cindex breaking pages
8675 @cindex @code{indent}
8676 @cindex @code{linewidth}
8678 The most basic settings influencing the spacing are @code{indent} and
8679 @code{linewidth}. They are set in the @code{\paper} block. They
8680 control the indentation of the first line of music, and the lengths of
8683 If @code{raggedright} is set to true in the @code{\paper}
8684 block, then the lines are justified at their natural length. This
8685 useful for short fragments, and for checking how tight the natural
8689 @cindex vertical spacing
8691 The page layout process happens outside the LilyPond formatting
8692 engine: variables controlling page layout are passed to the output,
8693 and are further interpreted by @code{lilypond} wrapper program. It
8694 responds to the following variables in the @code{\paper} block. The
8695 variable @code{textheight} sets the total height of the music on each
8696 page. The spacing between systems is controlled with
8697 @code{interscoreline}, its default is 16pt. The distance between the
8698 score lines will stretch in order to fill the full page
8699 @code{interscorelinefill} is set to a positive number. In that case
8700 @code{interscoreline} specifies the minimum spacing.
8702 @cindex @code{textheight}
8703 @cindex @code{interscoreline}
8704 @cindex @code{interscorelinefill}
8706 If the variable @code{lastpagefill} is defined,
8707 @c fixme: this should only be done if lastpagefill= #t
8708 systems are evenly distributed vertically on the last page. This
8709 might produce ugly results in case there are not enough systems on the
8710 last page. The @command{lilypond-book} command ignores
8711 @code{lastpagefill}. See @ref{lilypond-book manual} for more
8714 @cindex @code{lastpagefill}
8716 Page breaks are normally computed by @TeX{}, so they are not under
8717 direct control of LilyPond. However, you can insert a commands into
8718 the @file{.tex} output to instruct @TeX{} where to break pages. This
8719 is done by setting the @code{between-systems-strings} on the
8720 @internalsref{NonMusicalPaperColumn} where the system is broken.
8721 An example is shown in @inputfileref{input/regression,between-systems.ly}.
8722 The predefined command @code{\newpage} also does this.
8726 @cindex @code{papersize}
8728 To change the paper size, use the following Scheme code:
8731 #(set-paper-size "a4")
8738 @cindex @code{\newpage}
8744 In this manual: @ref{Invoking lilypond}.
8746 Examples: @inputfileref{input/regression,between-systems.ly}.
8748 Internals: @internalsref{NonMusicalPaperColumn}.
8752 LilyPond has no concept of page layout, which makes it difficult to
8753 reliably choose page breaks in longer pieces.
8762 Entered music can also be converted to MIDI output. The performance
8763 is good enough for proof-hearing the music for errors.
8765 Ties, dynamics and tempo changes are interpreted. Dynamic marks,
8766 crescendi and decrescendi translate into MIDI volume levels. Dynamic
8767 marks translate to a fixed fraction of the available MIDI volume
8768 range, crescendi and decrescendi make the volume vary linearly between
8769 their two extremities. The fractions can be adjusted by
8770 @code{dynamicAbsoluteVolumeFunction} in @internalsref{Voice} context.
8771 For each type of MIDI instrument, a volume range can be defined. This
8772 gives a basic equalizer control, which can enhance the quality of
8773 the MIDI output remarkably. The equalizer can be controlled by
8774 setting @code{instrumentEqualizer}.
8778 Many musically interesting effects, such as swing, articulation,
8779 slurring, etc., are not translated to MIDI.
8781 Since slurs are not interpreted, @code{\lyricsto} and
8782 @code{\addlyrics} sections will be interpreted wrongly.
8784 The MIDI output allocates a channel for each Staff, and one for global
8785 settings. Hence, the MIDI file should not have more than 15 staves
8786 (or 14 if you do not use drums).
8791 * MIDI instrument names::
8796 @subsection MIDI block
8800 The MIDI block is analogous to the paper block, but it is somewhat
8801 simpler. The @code{\midi} block can contain:
8805 @item a @code{\tempo} definition, and
8806 @item context definitions.
8809 Assignments in the @code{\midi} block are not allowed.
8811 A number followed by a period is interpreted as a real number, so
8812 for setting the tempo for dotted notes, an extra space should be
8813 inserted, for example:
8816 \midi @{ \tempo 4 . = 120 @}
8820 @cindex context definition
8822 Context definitions follow precisely the same syntax as within the
8823 \paper block. Translation modules for sound are called performers.
8824 The contexts for MIDI output are defined in @file{ly/performer-init.ly}.
8827 @node MIDI instrument names
8828 @subsection MIDI instrument names
8830 @cindex instrument names
8831 @cindex @code{Staff.midiInstrument}
8833 The MIDI instrument name is set by the @code{Staff.midiInstrument}
8834 property. The instrument name should be chosen from the list in
8835 @ref{MIDI instruments}.
8839 If the selected string does not exactly match, then the default is
8840 used, which is the Grand Piano.