3 @c A menu is needed before every deeper *section nesting of @node's; run
4 @c M-x texinfo-all-menus-update
5 @c to automagically fill in these menus before saving changes
7 @c FIXME: singular vs. plural: Beams/Beam
11 @chapter Notation manual
13 This chapter describes all the different types of notation supported
14 by LilyPond. It is intended as a reference for users that are already
15 somewhat familiar with using LilyPond.
19 * Easier music entry::
33 * Contemporary notation::
39 @c FIXME: Note entry vs Music entry at top level menu is confusing.
45 The basic elements of any piece of music are the notes. This section
46 is about basic notation elements notes, rests and related constructs,
47 such as stems, tuplets and ties.
52 * Chromatic alterations::
60 * Easy Notation note heads ::
68 A note is printed by specifying its pitch and then its duration:
69 @footnote{Notes constitute the most basic elements of LilyPond input,
70 but they do not form valid input on their own without a @code{\score}
71 block. However, for the sake of brevity and simplicity we will
72 generally omit @code{\score} blocks and @code{\paper} declarations in
75 @lilypond[fragment,verbatim]
84 @cindex Note specification
86 @cindex entering notes
88 The most common syntax for pitch entry is used in @code{\chords} and
89 @code{\notes} mode. In Note and Chord mode, pitches may be designated
90 by names. The notes are specified by the letters @code{a} through
91 @code{g}, while the octave is formed with notes ranging from @code{c}
92 to @code{b}. The pitch @code{c} is an octave below middle C and the
93 letters span the octave above that C:
95 @lilypond[fragment,verbatim]
97 a,4 b, c d e f g a b c' d' e' \clef treble f' g' a' b' c''
100 @cindex note names, Dutch
102 A sharp is formed by adding @code{-is} to the end of a pitch name and
103 a flat is formed by adding @code{-es}. Double sharps and double flats
104 are obtained by adding @code{-isis} or @code{-eses}. These
105 names are the Dutch note names. In Dutch, @code{aes} is contracted to
106 @code{as}, but both forms are accepted. Similarly, both
107 @code{es} and @code{ees} are accepted.
109 There are predefined sets of note names for various other languages.
110 To use them, include the language specific init file. For
111 example: @code{\include "english.ly"}. The available language files
112 and the note names they define are:
117 Note Names sharp flat
118 nederlands.ly c d e f g a bes b -is -es
119 english.ly c d e f g a bf b -s/-sharp -f/-flat
121 deutsch.ly c d e f g a b h -is -es
122 norsk.ly c d e f g a b h -iss/-is -ess/-es
123 svenska.ly c d e f g a b h -iss -ess
124 italiano.ly do re mi fa sol la sib si -d -b
125 catalan.ly do re mi fa sol la sib si -d/-s -b
126 espanol.ly do re mi fa sol la sib si -s -b
135 The optional octave specification takes the form of a series of
136 single quote (`@code{'}') characters or a series of comma
137 (`@code{,}') characters. Each @code{'} raises the pitch by one
138 octave; each @code{,} lowers the pitch by an octave:
140 @lilypond[fragment,verbatim,center]
141 c' c'' es' g' as' gisis' ais'
147 Notes can be hidden and unhidden with the following commands:
149 @cindex @code{\hideNotes}
151 @cindex @code{\unHideNotes}
161 @internalsref{NoteEvent}, and @internalsref{NoteHead}.
163 @node Chromatic alterations
164 @subsection Chromatic alterations
166 Normally accidentals are printed automatically, but you may also
167 print them manually. A reminder accidental
168 @cindex reminder accidental
170 can be forced by adding an exclamation mark @code{!}
171 after the pitch. A cautionary accidental
172 @cindex cautionary accidental
173 @cindex parenthesized accidental
174 (an accidental within parentheses) can be obtained by adding the
175 question mark `@code{?}' after the pitch:
177 @lilypond[fragment,verbatim]
178 cis' cis' cis'! cis'?
182 The automatic production of accidentals can be tuned in many
183 ways. For more information, refer to @ref{Accidentals}.
188 A chord is formed by a enclosing a set of pitches in @code{<} and
189 @code{>}. A chord may be followed by a duration, and a set of
190 articulations, just like simple notes.
200 Rests are entered like notes, with the note name @code{r}:
202 @lilypond[singleline,verbatim]
206 Whole bar rests, centered in middle of the bar,
207 must be done with multi measure rests. They are discussed in
208 @ref{Multi measure rests}.
211 A rest's vertical position may be explicitly specified by entering a
212 note with the @code{\rest} keyword appended. This makes manual
213 formatting in polyphonic music easier. Rest collision testing will
214 leave these rests alone:
216 @lilypond[singleline,verbatim]
222 @internalsref{RestEvent}, and @internalsref{Rest}.
229 @cindex Invisible rest
232 An invisible rest (also called a `skip') can be entered like a note
233 with note name `@code{s}' or with @code{\skip @var{duration}}:
235 @lilypond[singleline,verbatim]
239 The @code{s} syntax is only available in Note mode and Chord mode. In
240 other situations, you should use the @code{\skip} command:
242 @lilypond[singleline,verbatim]
245 { \time 4/8 \skip 2 \time 4/4 }
246 \notes\relative c'' { a2 a1 }
251 The skip command is merely an empty musical placeholder. It does not
252 produce any output, not even transparent output.
256 @internalsref{SkipEvent}.
261 @subsection Durations
267 In Note, Chord, and Lyrics mode, durations are designated by numbers
268 and dots: durations are entered as their reciprocal values. For example,
269 a quarter note is entered using a @code{4} (since it is a 1/4 note), while
270 a half note is entered using a @code{2} (since it is a 1/2 note). For notes
271 longer than a whole you must use variables:
273 @c FIXME: what is an identifier? I do not think it's been introduced yet.
274 @c and if it has, I obviously skipped that part. - Graham
278 c'1 c'2 c'4 c'8 c'16 c'32 c'64 c'64
280 r1 r2 r4 r8 r16 r32 r64 r64
285 \notes \relative c'' {
287 a1 a2 a4 a8 a16 a32 a64 a64
289 r1 r2 r4 r8 r16 r32 r64 r64
294 \remove "Clef_engraver"
295 \remove "Staff_symbol_engraver"
296 \remove "Time_signature_engraver"
297 \consists "Pitch_squash_engraver"
304 If the duration is omitted then it is set to the previously entered
305 duration. The default for the first note is a quarter note. The duration
306 can be followed by dots (`@code{.}') in order to obtain dotted note
310 @lilypond[fragment,verbatim,center]
311 a' b' c''8 b' a'4 a'4. b'4.. c'8.
316 You can alter the length of duration by a fraction @var{N/M}
317 appending `@code{*}@var{N/M}' (or `@code{*}@var{N}' if @var{M=1}). This
318 will not affect the appearance of the notes or rests produced.
319 In the following example, the first three notes take up exactly two
321 @lilypond[fragment,relative 2,verbatim]
323 a4*2/3 gis4*2/3 a4*2/3
330 Dots are normally moved up to avoid staff lines, except in polyphonic
331 situations. The following commands may be used to force a particular
334 @cindex @code{\dotsUp}
336 @cindex @code{\dotsDown}
338 @cindex @code{\dotsBoth}
343 @internalsref{Dots}, and @internalsref{DotColumn}.
347 In dense chords, dots can overlap.
352 Whenever a note is found, a @internalsref{Stem} object is created
353 automatically. For whole notes and rests, they are also created but
358 @cindex @code{\stemUp}
360 @cindex @code{\stemDown}
362 @cindex @code{\stemBoth}
373 A tie connects two adjacent note heads of the same pitch. The tie in
374 effect extends the length of a note. Ties should not be confused with
375 slurs, which indicate articulation, or phrasing slurs, which indicate
376 musical phrasing. A tie is entered using the tilde symbol `@code{~}':
378 @lilypond[fragment,verbatim,center]
379 e' ~ e' <c' e' g'> ~ <c' e' g'>
382 When a tie is applied to a chord, all note heads whose pitches match
383 are connected. When no note heads match, no ties will be created.
385 In its meaning a tie is just a way of extending a note duration, similar
386 to the augmentation dot; in the following example there are two ways of
387 notating exactly the same concept:
389 @lilypond[fragment, singleline,quote]
390 \time 3/4 c'2. c'2 ~ c'4
392 If you need to tie a lot of notes over bars, it may be easier to use automatic
393 note splitting (See @ref{Automatic note splitting}).
398 @cindex @code{\tieUp}
400 @cindex @code{\tieDown}
402 @cindex @code{\tieBoth}
404 @cindex @code{\tieDotted}
406 @cindex @code{\tieSolid}
411 @internalsref{TieEvent}, @internalsref{NewTieEvent},
412 @internalsref{Tie}, and @ref{Automatic note splitting}.
415 ties created for a chord, see @inputfileref{input/test,tie-sparse.ly}.
419 Tieing only a subset of the note heads of a pair of chords is not
420 supported in a simple way.
423 It can be achieved by moving the
424 tie-engraver into the @internalsref{Thread} context and turning on and
425 off ties per @internalsref{Thread}.
428 Switching staves when a tie is active will not produce a slanted tie.
430 Formatting of ties is a difficult subject. The results are often not
440 @cindex @code{\times}
442 Tuplets are made out of a music expression by multiplying all durations
445 @cindex @code{\times}
447 \times @var{fraction} @var{musicexpr}
451 The duration of @var{musicexpr} will be multiplied by the fraction.
452 The fraction's denominator will be printed over the notes, optionally
453 with a bracket. The most common tuplet is the triplet in which 3
454 notes have the length of 2, so the notes are 2/3 of their written
457 @lilypond[fragment,verbatim,center]
458 g'4 \times 2/3 {c'4 c' c'} d'4 d'4
461 The property @code{tupletSpannerDuration} specifies how long each
462 bracket should last. With this, you can make lots of tuplets while
463 typing @code{\times} only once, saving lots of typing. In the next
464 example, there are two triplets shown, while @code{\times} was only
467 @lilypond[fragment, relative, singleline, verbatim]
468 \property Voice.tupletSpannerDuration = #(ly:make-moment 1 4)
469 \times 2/3 { c'8 c c c c c }
472 The format of the number is determined by the property
473 @code{tupletNumberFormatFunction}. The default prints only the
474 denominator, but if it is set to the Scheme function
475 @code{fraction-tuplet-formatter}, @var{num}:@var{den} will be printed
479 @cindex @code{tupletNumberFormatFunction}
480 @cindex tuplet formatting
485 @cindex @code{\tupletUp}
487 @cindex @code{\tupletDown}
489 @cindex @code{\tupletBoth}
494 @internalsref{TupletBracket}, and @internalsref{TimeScaledMusic}.
498 Nested tuplets are not formatted automatically. In this case, outer
499 tuplet brackets should be moved manually.
501 @node Easy Notation note heads
502 @subsection Easy Notation note heads
504 @cindex easy notation
507 The `easy play' note head includes a note name inside the head. It is
508 used in music aimed at beginners:
510 @lilypond[singleline,verbatim,26pt]
512 \notes { c'2 e'4 f' | g'1 }
513 \paper { \translator { \EasyNotation } }
517 The @code{EasyNotation} variable overrides a @internalsref{Score} context.
518 You probably will want to print it with magnification or a
519 large font size to make it more readable. To print with
520 magnification, you must create a DVI file (with @file{lilypond}) and
521 then enlarge it with something like @file{dvips -x 2000 file.dvi}.
522 See the @code{dvips} documentation for more details. To print with a
523 larger font, see @ref{Font Size}.
529 If you view the result with Xdvi, then staff lines will show through
530 the letters. Printing the PostScript file obtained does produce the
534 @node Easier music entry
535 @section Easier music entry
538 When entering music it is easy to introduce errors. This section deals
539 with tricks and features of the input language that were added solely
540 to help entering music, and find and correct mistakes.
542 It is also possible to use external programs, for example GUI
543 interfaces, or MIDI transcription programs, to enter or edit
544 music. Refer to the website for more information. Finally, there are
545 tools make debugging easier, by linking the input file and the output
546 shown on screen. See @ref{Point and click} for more information.
553 * Skipping corrected music::
554 * Automatic note splitting ::
560 @node Relative octaves
561 @subsection Relative octaves
563 @cindex relative octave specification
565 Octaves are specified by adding @code{'} and @code{,} to pitch names.
566 When you copy existing music, it is easy to accidentally put a pitch
567 in the wrong octave and hard to find such an error. The relative
568 octave mode prevents these errors: a single error puts the rest of the
569 piece off by one octave:
571 @cindex @code{\relative}
573 \relative @var{startpitch} @var{musicexpr}
576 The octave of notes that appear in @var{musicexpr} are calculated as
577 follows: If no octave changing marks are used, the basic interval
578 between this and the last note is always taken to be a fourth or less
579 (; this distance is determined without regarding alterations: a
580 @code{fisis} following a @code{ceses} will be put above the
583 The octave changing marks @code{'} and @code{,} can be added to raise
584 or lower the pitch by an extra octave. Upon entering relative mode,
585 an absolute starting pitch must be specified that will act as the
586 predecessor of the first note of @var{musicexpr}.
588 Here is the relative mode shown in action:
589 @lilypond[fragment,singleline,verbatim,center]
595 Octave changing marks are used for intervals greater than a fourth:
596 @lilypond[fragment,verbatim,center]
601 If the preceding item is a chord, the first note of the chord is used
602 to determine the first note of the next chord:
604 @lilypond[fragment,verbatim,center]
611 @cindex @code{\notes}
613 The pitch after the @code{\relative} contains a note name. To parse
614 the pitch as a note name, you have to be in note mode, so there must
615 be a surrounding @code{\notes} keyword (which is not
618 The relative conversion will not affect @code{\transpose},
619 @code{\chords} or @code{\relative} sections in its argument. If you
620 want to use relative within transposed music, you must place an
621 additional @code{\relative} inside the @code{\transpose}.
624 @subsection Octave check
627 Octave checks make octave errors easier to correct.
633 This checks that @var{pitch} (without octave) yields @var{pitch} (with
634 octave) in \relative mode. If not, a warning is printed, and the
635 octave is corrected, for example, the first check is passed
636 successfully. The second check fails with an error message. The
637 octave is adjusted so the following notes are in the correct octave
648 The octave of a note following an octave check is determined with
649 respect to the note preceding it. In the next fragment, the last note
650 is a @code{a'}, above central C. Hence, the @code{\octave} check may
651 be deleted without changing the meaning of the piece.
653 @lilypond[verbatim,fragment]
664 @subsection Bar check
668 @cindex @code{barCheckSynchronize}
671 Bar checks help detect errors in the durations. A bar check is
672 entered using the bar symbol, `@code{|}'. Whenever it is encountered
673 during interpretation, it should fall on a measure boundary. If it
674 does not, a warning is printed. Depending on the value of
675 @code{barCheckSynchronize}, the beginning of the measure will be
678 In the next example, the second bar check will signal an error:
680 \time 3/4 c2 e4 | g2 |
685 @cindex skipTypesetting
687 Failed bar checks are caused by entering incorrect
688 durations. Incorrect durations often completely garble up the score,
689 especially if it is polyphonic, so you should start correcting the
690 score by scanning for failed bar checks and incorrect durations. To
691 speed up this process, you can use @code{skipTypesetting}, described
694 @node Skipping corrected music
695 @subsection Skipping corrected music
697 The property @code{Score.skipTypesetting} can be used to switch on and
698 off typesetting completely during the interpretation phase. When
699 typesetting is switched off, the music is processed much more quickly.
700 This can be used to skip over the parts of a score that have already
701 been checked for errors:
703 @lilypond[fragment,singleline,verbatim]
705 \property Score.skipTypesetting = ##t
707 \property Score.skipTypesetting = ##f
711 @node Automatic note splitting
712 @subsection Automatic note splitting
714 Long notes can be converted automatically to tied notes. This is done
715 by replacing the @internalsref{Note_heads_engraver} by the
716 @internalsref{Completion_heads_engraver}:
719 \paper @{ \translator @{
721 \remove "Note_heads_engraver"
722 \consists "Completion_heads_engraver"
726 which will make long notes tied in the following example:
729 c2. c8 d4 e f g a b c8 c2 b4 a g16 f4 e d c8. c2
736 c2. c8 d4 e f g a b c8 c2 b4 a g16 f4 e d c8. c2
738 \paper { \translator {
740 \remove "Note_heads_engraver"
741 \consists "Completion_heads_engraver"
746 This engraver splits all running notes at the bar line, and inserts
747 ties. One of its uses is to debug complex scores: if the measures are
748 not entirely filled, then the ties exactly show how much each measure
753 Not all durations (especially those containing tuplets) can be
754 represented exactly; the engraver will not insert tuplets.
760 @section Staff notation
762 This section describes music notation that occurs on staff level,
763 such as keys, clefs and time signatures.
765 @cindex Staff notation
779 @subsection Staff symbol
781 @cindex adjusting staff symbol
782 @cindex StaffSymbol, using \property
784 Notes, dynamic signs, etc. are grouped
785 with a set of horizontal lines, into a staff (plural `staves'). In our
786 system, these lines are drawn using a separate layout object called
790 @cindex staff lines, setting number of
791 @cindex staff lines, setting thickness of
792 @cindex thickness of staff lines, setting
793 @cindex number of staff lines, setting
795 This object is created whenever a @internalsref{Staff} context is
796 created. The appearance of the staff symbol cannot be changed by
797 using @code{\override} or @code{\set}. At the moment that
798 @code{\property Staff} is interpreted, a @internalsref{Staff} context
799 is made, and the @internalsref{StaffSymbol} is created before any
800 @code{\override} is effective. Properties can be changed in a
801 @code{\translator} definition, or by using @code{\outputproperty}.
805 If a staff is ended halfway a piece, the staff symbol may not end
806 exactly on the barline.
810 @subsection Key signature
811 @cindex Key signature
815 The key signature indicates the scale in which a piece is played. It
816 is denoted by a set of alterations (flats or sharps) at the start of
821 Setting or changing the key signature is done with the @code{\key}
824 @code{\key} @var{pitch} @var{type}
827 @cindex @code{\minor}
828 @cindex @code{\major}
829 @cindex @code{\minor}
830 @cindex @code{\ionian}
831 @cindex @code{\locrian}
832 @cindex @code{\aeolian}
833 @cindex @code{\mixolydian}
834 @cindex @code{\lydian}
835 @cindex @code{\phrygian}
836 @cindex @code{\dorian}
838 Here, @var{type} should be @code{\major} or @code{\minor} to get
839 @var{pitch}-major or @var{pitch}-minor, respectively.
840 The standard mode names @code{\ionian},
841 @code{\locrian}, @code{\aeolian}, @code{\mixolydian}, @code{\lydian},
842 @code{\phrygian}, and @code{\dorian} are also defined.
844 This command sets the context property
845 @internalsref{Staff}.@code{keySignature}. Non-standard key signatures
846 can be specified by setting this property directly.
848 Accidentals and key signatures often confuse new users, because
849 unaltered notes get natural signs depending on the keysignature. The
850 tutorial explains why this is so in @ref{More about pitches}.
854 The ordering of a key cancellation is wrong when it is combined with
855 repeat bar lines. The cancellation is also printed after a line break.
859 @internalsref{KeyChangeEvent}, and @internalsref{KeySignature}.
861 @cindex @code{keySignature}
868 The clef indicates which lines of the staff correspond to which
873 The clef can be set or changed with the @code{\clef} command:
874 @lilypond[fragment,verbatim]
875 \key f\major c''2 \clef alto g'2
878 Supported clef-names include:
879 @c Moved standard clefs to the top /MB
883 @item treble, violin, G, G2
896 G clef on 1st line, so-called French violin clef
901 @cindex mezzosoprano clef
904 @cindex baritone clef
907 @cindex varbaritone clef
916 By adding @code{_8} or @code{^8} to the clef name, the clef is
917 transposed one octave down or up, respectively, and @code{_15} and
918 @code{^15} transposes by two octaves. The argument @var{clefname}
919 must be enclosed in quotes when it contains underscores or digits. For
923 @cindex choral tenor clef
924 @lilypond[verbatim,fragment,relative]
928 This command is equivalent to setting @code{clefGlyph},
929 @code{clefPosition} (which controls the Y position of the clef),
930 @code{centralCPosition} and @code{clefOctavation}. A clef is printed
931 when any of these properties are changed.
935 The object for this symbol is @internalsref{Clef}.
939 @node Ottava brackets
940 @subsection Ottava brackets
942 ``Ottava'' brackets introduce an extra transposition of an octave for
943 the staff. They are created by invoking the function
944 @code{set-octavation}:
950 @lilypond[verbatim,fragment]
959 Internally the @code{set-octavation} function sets the properties
960 @code{ottavation} (eg. to @code{"8va"}) and
961 @code{centralCPosition}. The function also takes arguments -1 (for 8va
962 bassa) and 2 (for 15ma).
964 @internalsref{OttavaSpanner}.
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 @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 \property 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
1094 of barlines 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, singleline, verbatim]
1112 For allowing linebreaks, there is a special command,
1116 This will insert an invisible barline, and allow linebreaks at this
1119 In scores with many staves, a @code{\bar} command in one staff is
1120 automatically applied to all staves. The resulting bar lines are
1121 connected between different staves of a @internalsref{StaffGroup}:
1123 @lilypond[fragment, verbatim]
1124 << \context StaffGroup <<
1128 \new Staff { \clef bass c4 g e g } >>
1129 \new Staff { \clef bass c2 c2 } >>
1133 The command @code{\bar @var{bartype}} is a short cut for doing
1134 @code{\property Score.whichBar = @var{bartype}} Whenever
1135 @code{whichBar} is set to a string, a bar line of that type is
1136 created. At the start of a measure it is set to
1137 @code{defaultBarType}. The contents of @code{repeatCommands} are used
1138 to override default measure bars.
1140 Property @code{whichBar} can also be set directly, using @code{\property}
1141 or @code{\bar}. These settings take precedence over the automatic
1142 @code{whichBar} settings.
1145 @cindex repeatCommands
1146 @cindex defaultBarType
1148 You are encouraged to use @code{\repeat} for repetitions. See
1158 The bar line objects that are created at @internalsref{Staff} level
1159 are called @internalsref{BarLine}, the bar lines that span staves are
1160 @internalsref{SpanBar}s.
1162 @cindex bar lines at start of system
1163 @cindex start of system
1165 The barlines at the start of each system are
1166 @internalsref{SystemStartBar}, @internalsref{SystemStartBrace}, and
1167 @internalsref{SystemStartBracket}. They are spanner objects and
1168 typically must be tuned from a @code{\translator} block.
1175 The easiest way to enter fragments with more than one voice on a staff
1176 is to split chords using the separator @code{\\}. You can use it for
1177 small, short-lived voices or for single chords:
1179 @lilypond[verbatim,fragment]
1180 \context Staff \relative c'' {
1181 c4 << { f d e } \\ { b c2 } >>
1182 c4 << g' \\ b, \\ f' \\ d >>
1186 The separator causes @internalsref{Voice} contexts to be
1188 bear the names @code{"1"}, @code{"2"}, etc. In each of these
1189 contexts, vertical direction of slurs, stems, etc. is set
1192 This can also be done by instantiating @internalsref{Voice} contexts
1193 by hand, and using @code{\voiceOne}, up to @code{\voiceFour} to assign
1194 a stem directions and horizontal shift for each part:
1197 @lilypond[singleline, verbatim]
1199 \context Staff << \new Voice { \voiceOne cis2 b }
1200 \new Voice { \voiceThree b4 ais ~ ais4 gis4 }
1201 \new Voice { \voiceTwo fis4~ fis4 f ~ f } >>
1204 Normally, note heads with a different number of dots are not merged, but
1205 when the object property @code{merge-differently-dotted} is set in
1206 the @internalsref{NoteCollision} object, they are merged:
1207 @lilypond[verbatim,fragment,singleline]
1208 \relative c'' \context Voice << {
1210 \property Staff.NoteCollision \override
1211 #'merge-differently-dotted = ##t
1213 } \\ { g8.[ f16] g8.[ f16] }
1217 Similarly, you can merge half note heads with eighth notes, by setting
1218 @code{merge-differently-headed}:
1219 @lilypond[fragment, relative=2,verbatim]
1222 \property Staff.NoteCollision
1223 \override #'merge-differently-headed = ##t
1224 c8 c4. } \\ { c2 c2 } >>
1227 LilyPond also vertically shifts rests that are opposite of a stem:
1230 @lilypond[singleline,fragment,verbatim]
1231 \context Voice << c''4 \\ r4 >>
1239 @cindex @code{\oneVoice}
1241 @cindex @code{\voiceOne}
1243 @cindex @code{\voiceTwo}
1245 @cindex @code{\voiceThree}
1247 @cindex @code{\voiceFour}
1250 The following commands specify in what chords of the current voice
1251 should be shifted: the outer voice has @code{\shiftOff}, and the inner
1252 voices have @code{\shiftOn}, @code{\shiftOnn}, etc.
1255 @cindex @code{\shiftOn}
1257 @cindex @code{\shiftOnn}
1259 @cindex @code{\shiftOnnn}
1261 @cindex @code{\shiftOff}
1268 The objects responsible for resolving collisions are
1269 @internalsref{NoteCollision} and @internalsref{RestCollision}. See
1270 also example files @inputfileref{input/regression,collision-dots.ly},
1271 @inputfileref{input/regression,collision-head-chords.ly},
1272 @inputfileref{input/regression,collision-heads.ly},
1273 @inputfileref{input/regression,collision-mesh.ly}, and
1274 @inputfileref{input/regression,collisions.ly}.
1279 Resolving collisions is a intricate subject, and only a few situations
1280 are handled. When LilyPond cannot cope, the @code{force-hshift}
1281 property of the @internalsref{NoteColumn} object and pitched rests can
1282 be used to override typesetting decisions.
1284 When using @code{merge-differently-headed} with an upstem 8th or a shorter
1285 note, and a downstem half note, the 8th note gets the wrong offset.
1290 Beams are used to group short notes into chunks that are aligned with
1291 the metrum. They are inserted automatically in most cases:
1293 @lilypond[fragment,verbatim, relative=2]
1294 \time 2/4 c8 c c c \time 6/8 c c c c8. c16 c8
1297 When these automatic decisions are not good enough, beaming can be
1298 entered explicitly. It is also possible to define beaming patterns
1299 that differ from the defaults.
1303 @internalsref{Beam}.
1306 @cindex Automatic beams
1307 @subsection Manual beams
1308 @cindex beams, manual
1312 In some cases it may be necessary to override the automatic beaming
1313 algorithm. For example, the auto beamer will not put beams over rests
1314 or bar lines. Such beams are specified by manually: the begin and end
1315 point are marked with @code{[} and @code{]}:
1317 @lilypond[fragment,relative,verbatim]
1319 r4 r8[ g' a r8] r8 g[ | a] r8
1323 @cindex @code{stemLeftBeamCount}
1325 Normally, beaming patterns within a beam are determined automatically.
1326 When this mechanism fouls up, the properties
1327 @code{Voice.stemLeftBeamCount} and @code{Voice.stemRightBeamCount} can
1328 be used to control the beam subdivision on a stem. If either property
1329 is set, its value will be used only once, and then it is erased.
1331 @lilypond[fragment,relative,verbatim]
1334 f8[ r16 \property Voice.stemLeftBeamCount = #1 f g a]
1337 @cindex @code{stemRightBeamCount}
1340 The property @code{subdivideBeams} can be set in order to subdivide
1341 all 16th or shorter beams at beat positions, as defined by the
1342 @code{beatLength} property . This accomplishes the same effect as
1343 twiddling with @code{stemLeftBeamCount} and @code{stemRightBeamCount},
1344 but it take less typing:
1347 @lilypond[relative=1,verbatim,noindent]
1349 \property Voice.subdivideBeams = ##t
1351 \property Score.beatLength = #(ly:make-moment 1 8)
1354 @cindex subdivideBeams
1356 Kneed beams are inserted automatically, when a large gap is detected
1357 between the note heads. This behavior can be tuned through the object
1358 property @code{auto-knee-gap}.
1360 Normally, line breaks are forbidden when beams cross bar lines. This
1361 behavior can be changed by setting @code{allowBeamBreak}.
1363 @cindex @code{allowBeamBreak}
1364 @cindex beams and line breaks
1366 @cindex beams, kneed
1368 @cindex auto-knee-gap
1374 @cindex Frenched staves
1376 Automatically kneed beams cannot be used together with hidden staves.
1381 * Setting automatic beam behavior ::
1385 @no de Beam typography
1386 @sub section Beam typography
1388 One of the strong points of LilyPond is how beams are formatted. Beams
1389 are quantized, meaning that the left and right endpoints beams start
1390 exactly on staff lines. Without quantization, small wedges of white
1391 space appear between the beam and staff line, and this looks untidy.
1393 Beams are also slope-damped: melodies that go up or down should also
1394 have beams that go up or down, but the slope of the beams should be
1395 less than the slope of the notes themselves.
1397 Some beams should be horizontal. These are so-called concave beams.
1399 [TODO: some pictures.]
1403 @node Setting automatic beam behavior
1404 @subsection Setting automatic beam behavior
1406 @cindex @code{autoBeamSettings}
1407 @cindex @code{(end * * * *)}
1408 @cindex @code{(begin * * * *)}
1409 @cindex automatic beams, tuning
1410 @cindex tuning automatic beaming
1412 @c [TODO: use \applycontext]
1414 In normal time signatures, automatic beams can start on any note but can
1415 only end in a few positions within the measure: beams can end on a beat,
1416 or at durations specified by the properties in
1417 @code{Voice.autoBeamSettings}. The defaults for @code{autoBeamSettings}
1418 are defined in @file{scm/auto-beam.scm}.
1420 The value of @code{autoBeamSettings} is changed using
1421 @code{\override} and restored with @code{\revert}:
1423 \property Voice.autoBeamSettings \override #'(@var{BE} @var{P} @var{Q} @var{N} @var{M}) = @var{dur}
1424 \property Voice.autoBeamSettings \revert #'(@var{BE} @var{P} @var{Q} @var{N} @var{M})
1426 Here, @var{BE} is the symbol @code{begin} or @code{end}. It determines
1427 whether the rule applies to begin or end-points. The quantity
1428 @var{P}/@var{Q} refers to the length of the beamed notes (and `@code{*
1429 *}' designates notes of any length), @var{N}/@var{M} refers to a time
1430 signature (wildcards, `@code{* *}' may be entered to designate all time
1433 For example, if automatic beams should end on every quarter note, use
1436 \property Voice.autoBeamSettings \override
1437 #'(end * * * *) = #(ly:make-moment 1 4)
1439 Since the duration of a quarter note is 1/4 of a whole note, it is
1440 entered as @code{(ly:make-moment 1 4)}.
1442 The same syntax can be used to specify beam starting points. In this
1443 example, automatic beams can only end on a dotted quarter note:
1445 \property Voice.autoBeamSettings \override
1446 #'(end * * * *) = #(ly:make-moment 3 8)
1448 In 4/4 time signature, this means that automatic beams could end only on
1449 3/8 and on the fourth beat of the measure (after 3/4, that is 2 times
1450 3/8 has passed within the measure).
1452 Rules can also be restricted to specific time signatures. A rule that
1453 should only be applied in @var{N}/@var{M} time signature is formed by
1454 replacing the second asterisks by @var{N} and @var{M}. For example, a
1455 rule for 6/8 time exclusively looks like
1457 \property Voice.autoBeamSettings \override
1458 #'(begin * * 6 8) = ...
1461 If a rule should be to applied only to certain types of beams, use the
1462 first pair of asterisks. Beams are classified according to the
1463 shortest note they contain. For a beam ending rule that only applies
1464 to beams with 32nd notes (and no shorter notes), use @code{(end 1 32 *
1467 If a score ends while an automatic beam has not been ended and is still
1468 accepting notes, this last beam will not be typeset at all.
1470 @cindex automatic beam generation
1472 @cindex @code{Voice.autoBeaming}
1475 For melodies that have lyrics, you may want to switch off
1476 automatic beaming. This is done by setting @code{Voice.autoBeaming} to
1481 @cindex @code{\autoBeamOff}
1482 @code{\autoBeamOff},
1483 @cindex @code{\autoBeamOn}
1489 The rules for ending a beam depend on the shortest note in a beam.
1490 So, while it is possible to have different ending rules for eight
1491 beams and sixteenth beams, a beam that contains both eight and
1492 sixteenth notes will use the rules for the sixteenth beam.
1494 In the example below, the autobeamer makes eight beams and sixteenth
1495 end at 3 eights; the third beam can only be corrected by specifying
1498 @lilypond[singleline,fragment,relative,noverbatim,quote]
1499 \property Voice.autoBeamSettings
1500 \override #'(end * * * *) = #(ly:make-moment 3 8)
1501 % rather show case where it goes wrong
1502 %\time 12/8 c'8 c c c16 c c c c c c[ c c c] c8[ c] c4
1503 \time 12/8 c'8 c c c16 c c c c c c c c c c8 c c4
1505 It is not possible to specify beaming parameters that act differently in
1506 different parts of a measure. This means that it is not possible to use
1507 automatic beaming in irregular meters such as @code{5/8}.
1510 @section Accidentals
1513 This section describes how to change the way that accidentals are
1514 inserted automatically before the running notes.
1518 * Using the predefined accidental variables::
1519 * Customized accidental rules::
1522 @node Using the predefined accidental variables
1523 @subsection Using the predefined accidental variables
1525 The constructs for describing the accidental typesetting rules are
1526 quite hairy, so non-experts should stick to the variables
1527 defined in @file{ly/property-init.ly}.
1528 @cindex @file{property-init.ly}
1530 The variables set properties in the ``@code{Current}'' context (see
1531 @ref{Context properties}). This means that the variables should
1532 normally be added right after the creation of the context in which the
1533 accidental typesetting described by the variable is to take
1534 effect. For example, if you want to use piano-accidentals in a piano
1535 staff then issue @code{\pianoAccidentals} first thing after the
1536 creation of the piano staff:
1539 \notes \relative c'' <<
1540 \new Staff @{ cis4 d e2 @}
1541 \context GrandStaff <<
1543 \new Staff @{ cis4 d e2 @}
1544 \new Staff @{ es2 c @}
1546 \new Staff @{ es2 c @}
1550 @lilypond[singleline]
1552 \notes \relative c'' <<
1553 \new Staff { cis4 d e2 }
1554 \context GrandStaff <<
1556 \new Staff { cis4 d e2 }
1557 \new Staff { es2 c }
1559 \new Staff { es2 c }
1564 minimumVerticalExtent = #'(-4.0 . 4.0)
1572 @item \defaultAccidentals
1573 @cindex @code{\defaultAccidentals}
1574 This is the default typesetting behaviour. It should correspond
1575 to 18th century common practice: Accidentals are
1576 remembered to the end of the measure in which they occur and
1577 only on their own octave.
1579 @item \voiceAccidentals
1580 @cindex @code{\voiceAccidentals}
1582 The normal behaviour is to
1583 remember the accidentals on Staff-level. This variable, however,
1584 typesets accidentals individually for each voice. Apart from that the
1585 rule is similar to @code{\defaultAccidentals}.
1587 This leads to some weird and often unwanted results
1588 because accidentals from one voice do not get cancelled in other
1590 @lilypond[singleline,relative,fragment,verbatim,quote]
1598 Hence you should only use @code{\voiceAccidentals} if the voices
1599 are to be read solely by individual musicians. If the staff is to be
1600 used by one musician (e.g. a conductor) then you use
1601 @code{\modernVoiceAccidentals} or @code{\modernVoiceCautionaries}
1604 @item \modernAccidentals
1605 @cindex @code{\modernAccidentals}
1606 This rule corresponds to the common practice in the 20th
1608 The rule is more complex than @code{\defaultAccidentals}.
1609 You get all the same accidentals, but temporary
1610 accidentals also get cancelled in other octaves. Furthermore,
1611 in the same octave, they also get cancelled in the following measure:
1612 @lilypond[singleline,fragment,verbatim]
1614 cis' c'' cis'2 | c'' c'
1617 @item \modernCautionaries
1618 @cindex @code{\modernCautionaries}
1619 This rule is similar to @code{\modernAccidentals}, but the
1620 ``extra'' accidentals (the ones not typeset by
1621 @code{\defaultAccidentals}) are typeset as cautionary accidentals.
1622 They are printed in reduced size or with parentheses:
1623 @lilypond[singleline,fragment,verbatim]
1625 cis' c'' cis'2 | c'' c'
1628 @cindex @code{\modernVoiceAccidentals}
1629 @item \modernVoiceAccidentals
1630 is used for multivoice accidentals to be read both by musicians
1631 playing one voice and musicians playing all voices. Accidentals are
1632 typeset for each voice, but they @emph{are} cancelled across voices in
1633 the same @internalsref{Staff}.
1635 @cindex @code{\modernVoiceCautionaries}
1636 @item \modernVoiceCautionaries
1637 is the same as @code{\modernVoiceAccidentals}, but with the extra
1638 accidentals (the ones not typeset by @code{\voiceAccidentals}) typeset
1639 as cautionaries. Even though all accidentals typeset by
1640 @code{\defaultAccidentals} @emph{are} typeset by this variable then
1641 some of them are typeset as cautionaries.
1643 @item \pianoAccidentals
1644 @cindex @code{\pianoAccidentals}
1645 20th century practice for piano notation. Very similar to
1646 @code{\modernAccidentals} but accidentals also get cancelled
1647 across the staves in the same @internalsref{GrandStaff} or
1648 @internalsref{PianoStaff}.
1650 @item \pianoCautionaries
1651 @cindex @code{\pianoCautionaries}
1652 As @code{\pianoAccidentals} but with the extra accidentals
1653 typeset as cautionaries.
1656 @cindex @code{\noResetKey}
1657 Same as @code{\defaultAccidentals} but with accidentals lasting
1658 ``forever'' and not only until the next measure:
1659 @lilypond[singleline,fragment,verbatim,relative]
1664 @item \forgetAccidentals
1665 @cindex @code{\forgetAccidentals}
1666 This is sort of the opposite of @code{\noResetKey}: Accidentals
1667 are not remembered at all---and hence all accidentals are
1668 typeset relative to the key signature, regardless of what was
1669 before in the music:
1670 @lilypond[singleline,fragment,verbatim,relative]
1672 \key d\major c4 c cis cis d d dis dis
1676 @node Customized accidental rules
1677 @subsection Customized accidental rules
1679 For determining when to print an accidental, several different rules
1680 are tried. The rule that gives the highest number of accidentals is
1681 used. Each rule consists of
1684 In which context is the rule applied. For example, if
1685 @var{context} is @internalsref{Score} then all staves share
1686 accidentals, and if @var{context} is @internalsref{Staff} then all
1687 voices in the same staff share accidentals, but staves do not.
1689 Whether the accidental changes all octaves or only the current
1692 Over how many barlines the accidental lasts.
1693 If @var{lazyness} is @code{-1} then the accidental is forget
1694 immediately, and if @var{lazyness} is @code{#t} then the accidental
1697 @c [TODO: should use +infinity for this case?]
1703 @cindex @code{\defaultAccidentals}
1704 @code{\defaultAccidentals},
1705 @cindex @code{\voiceAccidentals}
1706 @code{\voiceAccidentals},
1707 @cindex @code{\modernAccidentals}
1708 @code{\modernAccidentals},
1709 @cindex @code{\modernCautionaries}
1710 @code{\modernCautionaries},
1711 @cindex @code{\modernVoiceAccidentals}
1712 @code{\modernVoiceAccidentals},
1713 @cindex @code{\modernVoiceCautionaries}
1714 @code{\modernVoiceCautionaries},
1715 @cindex @code{\pianoAccidentals}
1716 @code{\pianoAccidentals},
1717 @cindex @code{\pianoCautionaries}
1718 @code{\pianoCautionaries},
1719 @cindex @code{\noResetKey}
1721 @cindex @code{\forgetAccidentals}
1722 @code{\forgetAccidentals}.
1726 @internalsref{Accidental_engraver}, @internalsref{Accidental}, and
1727 @internalsref{AccidentalPlacement}.
1732 Currently the simultaneous notes are considered to be entered in
1733 sequential mode. This means that in a chord the accidentals are
1734 typeset as if the notes in the chord happened once at a time - in the
1735 order in which they appear in the input file.
1737 This is only a problem when there are simultaneous notes whose
1738 accidentals depend on each other. The problem only occurs when using
1739 non-default accidentals. In the default scheme, accidentals only
1740 depend on other accidentals with the same pitch on the same staff, so
1741 no conflicts possible.
1743 This example shows two examples of the same music giving different
1744 accidentals depending on the order in which the notes occur in the
1747 @lilypond[singleline,fragment,verbatim]
1748 \property Staff.autoAccidentals = #'( Staff (any-octave . 0) )
1749 cis'4 <c'' c'> r2 | cis'4 <c' c''> r2
1750 | <cis' c''> r | <c'' cis'> r |
1753 This problem can be solved by manually inserting @code{!} and @code{?}
1754 for the problematic notes.
1756 @node Expressive marks
1757 @section Expressive marks
1760 @c todo: should change ordering
1761 @c where to put text spanners, metronome marks,
1770 * Analysis brackets::
1772 * Fingering instructions::
1783 A slur indicates that notes are to be played bound or @emph{legato}.
1787 They are entered using parentheses:
1788 @lilypond[relative 1,fragment,verbatim,center]
1789 f( g)( a) a8 b( a4 g2 f4)
1794 @c TODO: should explain that ^( and _( set directions
1795 @c should set attachments with ^ and _ ?
1797 Slurs avoid crossing stems, and are generally attached to note heads.
1798 However, in some situations with beams, slurs may be attached to stem
1799 ends. If you want to override this layout you can do this through the
1800 object property @code{attachment} of @internalsref{Slur} in
1801 @internalsref{Voice} context. Its value is a pair of symbols, specifying
1802 the attachment type of the left and right end points:
1804 @lilypond[fragment,relative,verbatim]
1806 \property Voice.Stem \set #'length = #5.5
1808 \property Voice.Slur \set #'attachment = #'(stem . stem)
1812 If a slur would strike through a stem or beam, the slur will be moved
1813 away upward or downward. If this happens, attaching the slur to the
1814 stems might look better:
1816 @lilypond[fragment,relative,verbatim]
1819 \property Voice.Slur \set #'attachment = #'(stem . stem)
1826 @cindex @code{\slurUp}
1828 @cindex @code{\slurDown}
1830 @cindex @code{\slurBoth}
1832 @cindex @code{\slurDotted}
1834 @cindex @code{\slurSolid}
1839 @seeinternals{Slur}, and @internalsref{SlurEvent}.
1844 Producing nice slurs is a difficult problem, and LilyPond currently
1845 uses a simple, empiric method to produce slurs. In some cases, its
1849 @cindex Adjusting slurs
1851 @node Phrasing slurs
1852 @subsection Phrasing slurs
1854 @cindex phrasing slurs
1855 @cindex phrasing marks
1857 A phrasing slur (or phrasing mark) connects chords and is used to
1858 indicate a musical sentence. It is started using @code{\(} and @code{\)}
1861 @lilypond[fragment,verbatim,center,relative]
1862 \time 6/4 c'\( d( e) f( e) d\)
1865 Typographically, the phrasing slur behaves almost exactly like a
1866 normal slur. However, they are treated as different objects. A
1867 @code{\slurUp} will have no effect on a phrasing slur; instead, you
1868 should use @code{\phrasingSlurUp}, @code{\phrasingSlurDown}, and
1869 @code{\phrasingSlurBoth}.
1871 The commands @code{\slurUp}, @code{\slurDown}, and @code{\slurBoth}
1872 will only affect normal slurs and not phrasing slurs.
1876 @cindex @code{\phrasingSlurUp}
1877 @code{\phrasingSlurUp},
1878 @cindex @code{\phrasingSlurDown}
1879 @code{\phrasingSlurDown},
1880 @cindex @code{\phrasingSlurBoth}
1881 @code{\phrasingSlurBoth},
1885 See also @internalsref{PhrasingSlur}, and
1886 @internalsref{PhrasingSlurEvent}.
1890 Phrasing slurs have the same limitations in their formatting as normal
1891 slurs. Putting phrasing slurs over rests leads to spurious warnings.
1894 @subsection Breath marks
1896 Breath marks are entered using @code{\breathe}:
1899 @lilypond[fragment,relative,verbatim]
1903 The glyph of the breath mark can be tweaked by overriding the
1904 @code{text} property of the @code{BreathingSign} layout object with
1905 any markup text. For example,
1906 @lilypond[fragment,verbatim,relative]
1908 \property Voice.BreathingSign \override #'text
1909 = #(make-musicglyph-markup "scripts-rvarcomma")
1916 @internalsref{BreathingSign}, @internalsref{BreathingSignEvent}, and
1917 @inputfileref{input/regression,breathing-sign.ly}.
1920 @node Metronome marks
1921 @subsection Metronome marks
1924 @cindex beats per minute
1925 @cindex metronome marking
1927 Metronome settings can be entered as follows:
1929 \tempo @var{duration} = @var{perminute}
1932 In the MIDI output, they are interpreted as a tempo change, and in the
1933 paper output, a metronome marking is printed:
1934 @cindex @code{\tempo}
1935 @lilypond[fragment,verbatim]
1941 @internalsref{MetronomeChangeEvent}.
1946 @subsection Text spanners
1947 @cindex Text spanners
1949 Some performance indications, e.g. @i{rallentando} or @i{accelerando},
1950 are written as texts, and extended over many measures with dotted
1951 lines. You can create such texts using text spanners: attach
1952 @code{\startTextSpan} and @code{\stopTextSpan} to the
1953 start and ending note of the spanner.
1955 The string to be printed, as well as the style, is set through object
1958 @lilypond[fragment,relative,verbatim]
1960 \property Voice.TextSpanner \set #'direction = #-1
1961 \property Voice.TextSpanner \set #'edge-text = #'("rall " . "")
1962 c2\startTextSpan b c\stopTextSpan a }
1968 @internalsref{TextSpanEvent},
1969 @internalsref{TextSpanner}, and
1970 @inputfileref{input/regression,text-spanner.ly}.
1973 @node Analysis brackets
1974 @subsection Analysis brackets
1976 @cindex phrasing brackets
1977 @cindex musicological analysis
1978 @cindex note grouping bracket
1980 Brackets are used in musical analysis to indicate structure in musical
1981 pieces. LilyPond supports a simple form of nested horizontal brackets.
1982 To use this, add the @internalsref{Horizontal_bracket_engraver} to
1983 @internalsref{Staff} context. A bracket is started with
1984 @code{\startGroup} and closed with @code{\stopGroup}:
1986 @lilypond[singleline,verbatim]
1987 \score { \notes \relative c'' {
1988 c4\startGroup\startGroup
1991 c4\stopGroup\stopGroup
1993 \paper { \translator {
1994 \StaffContext \consists "Horizontal_bracket_engraver"
2000 @internalsref{HorizontalBracket}, @internalsref{NoteGroupingEvent}, and
2001 @inputfileref{input/regression,note-group-bracket.ly}.
2005 @subsection Articulations
2006 @cindex Articulations
2008 @cindex articulations
2012 A variety of symbols can appear above and below notes to indicate
2013 different characteristics of the performance. They are added to a note
2014 by adding a dash and the character signifying the
2015 articulation. They are demonstrated here:
2017 @lilypondfile[notexidoc]{script-abbreviations.ly}
2019 The meanings of these shorthands can be changed: see
2020 @file{ly/script-init.ly} for examples.
2023 The script is automatically placed, but if you need to force
2024 directions, you can use @code{_} to force them down, or @code{^} to
2026 @lilypond[fragment, verbatim]
2030 Other symbols can be added using the syntax
2031 @var{note}@code{\}@var{name}, e.g. @code{c4\fermata}. Again, they
2032 can be forced up or down using @code{^} and @code{_},
2035 @lilypond[verbatim,fragment,relative 2]
2036 c\fermata c^\fermata c_\fermata
2043 @cindex staccatissimo
2052 @cindex organ pedal marks
2061 @cindex prallmordent
2065 @cindex thumb marking
2070 @lilypondfile[notexidoc]{script-chart.ly}
2075 @cindex @code{\scriptUp}
2077 @cindex @code{\scriptDown}
2079 @cindex @code{\scriptBoth}
2084 @internalsref{ScriptEvent}, and @internalsref{Script}.
2088 These note ornaments appear in the printed output but have no
2089 effect on the MIDI rendering of the music.
2092 @node Fingering instructions
2093 @subsection Fingering instructions
2097 Fingering instructions can be entered using
2099 @var{note}-@var{digit}
2101 For finger changes, use markup texts:
2103 @lilypond[verbatim, singleline, fragment]
2104 c'4-1 c'4-2 c'4-3 c'4-4
2105 c'^\markup { \fontsize #-3 \number "2-3" }
2108 @cindex finger change
2113 You can use the thumb-script to indicate that a note should be
2114 played with your thumb (used in cello music):
2116 @lilypond[verbatim, singleline, fragment]
2117 <a' a''-3>8(_\thumb <b' b''-3>)_\thumb
2118 <c'' c'''-3>(_\thumb <d'' d'''-3>)_\thumb
2121 Fingerings for chords can also be added to individual notes
2122 of the chord by adding them after the pitches:
2123 @lilypond[verbatim,singleline,fragment,relative=1]
2124 < c-1 e-2 g-3 b-5 > 4
2127 Setting @code{fingeringOrientations} will put fingerings next
2130 @lilypond[verbatim,singleline,fragment,relative=1]
2131 \property Voice.fingeringOrientations = #'(left down)
2132 <c-1 es-2 g-4 bes-5 > 4
2133 \property Voice.fingeringOrientations = #'(up right down)
2134 <c-1 es-2 g-4 bes-5 > 4
2139 @internalsref{FingerEvent}, and @internalsref{Fingering}.
2143 @subsection Text scripts
2144 @cindex Text scripts
2146 It is possible to place arbitrary strings of text or markup text (see
2147 @ref{Text markup}) above or below notes by using a string:
2148 @code{c^"text"}. By default, these indications do not influence the
2149 note spacing, but by using the command @code{\fatText}, the widths
2150 will be taken into account:
2152 @lilypond[fragment,singleline,verbatim] \relative c' {
2153 c4^"longtext" \fatText c4_"longlongtext" c4 }
2156 It is possible to use @TeX{} commands in the strings, but this should
2157 be avoided because the exact dimensions of the string can then no
2163 @internalsref{TextScriptEvent}, @internalsref{TextScript}, and
2169 @subsection Grace notes
2172 @c should have blurb about accaciatura / appogiatura
2174 @cindex @code{\grace}
2178 Grace notes are ornaments that are written out. The most common ones
2179 are acciaccatura, which should be played as very short. It is denoted
2180 by a slurred small note with a slashed stem. The appoggiatura is a
2181 grace note that takes a fixed fraction of the main note, is and
2182 denoted as a slurred note in small print without a slash.
2183 They are entered with the commands @code{\acciaccatura} and
2184 @code{\appoggiatura}, as demonstrated in the following example:
2187 @cindex appoggiatura
2188 @cindex acciaccatura
2190 @lilypond[relative=2,verbatim,fragment]
2191 b4 \acciaccatura d8 c4 \appoggiatura e8 d4
2192 \acciaccatura { g16[ f] } e4
2195 Both are special forms of the @code{\grace} command. By prefixing this
2196 keyword to a music expression, a new one is formed, which will be
2197 printed in a smaller font and takes up no logical time in a measure.
2198 @lilypond[relative=2,verbatim,fragment]
2200 \grace { c16[ d16] } c2 c4
2204 Unlike @code{\acciaccatura} and @code{\appoggiatura}, the
2205 @code{\grace} command does not start a slur.
2207 Internally, timing for grace notes is done using a second, `grace'
2208 time. Every point in time consists of two rational numbers: one
2209 denotes the logical time, one denotes the grace timing. The above
2210 example is shown here with timing tuples:
2212 @lilypond[singleline]
2215 c4 \grace c16 c4 \grace {
2218 \new Lyrics \lyrics {
2221 ( \fraction 1 4 , \fraction -1 16 ) } 16 }
2222 \markup { (\fraction 1 4 , 0 ) } 4
2224 \markup { (\fraction 2 4 , \fraction "-1" 8 ) } 16
2225 \markup { (\fraction 2 4 , \fraction "-1" 16 ) } 16
2227 \markup { ( \fraction 2 4 , 0 ) }
2232 The placement of grace notes is synchronized between different staves.
2233 In the following example, there are two sixteenth graces notes for
2234 every eighth grace note:
2236 @lilypond[relative=2,verbatim,fragment]
2237 << \new Staff { e4 \grace { c16[ d e f] } e4 }
2238 \new Staff { c'4 \grace { g8[ b] } c4 } >>
2243 If you want to end a note with a grace, then the standard trick
2244 is to put the grace notes after a ``space note'', e.g.
2245 @lilypond[fragment,verbatim, relative=2]
2248 { s2 \grace { c16[ d] } } >>
2254 By adjusting the duration of the skip note (here it is a half-note),
2255 the space between the main-note and the grace is adjusted.
2258 A @code{\grace} section will introduce special typesetting settings,
2259 for example, to produce smaller type, and set directions. Hence, when
2260 introducing layout tweaks, they should be inside the grace section,
2262 @lilypond[fragment,verbatim,relative 1]
2265 \property Voice.Stem \override #'direction = #-1
2267 \property Voice.Stem \revert #'direction
2274 The overrides should also be reverted inside the grace section.
2276 If the layout of grace sections must be changed throughout the music,
2277 then this can be accomplished through the function
2278 @code{add-grace-property}. The following example
2279 undefines the Stem direction grace section, so stems do not always
2284 #(add-grace-property "Voice" Stem direction '())
2290 Another option is to change the variables @code{startGraceMusic},
2291 @code{stopGraceMusic}, @code{startAccacciaturaMusic},
2292 @code{stopAccacciaturaMusic}, @code{startAppoggiaturaMusic},
2293 @code{stopAppoggiaturaMstuic}. More information is in the file
2294 @file{ly/grace-init.ly}
2299 @internalsref{GraceMusic}.
2303 Grace notes cannot be used in the smallest size (@file{paper11.ly}).
2305 A score that starts with an @code{\grace} section needs an explicit
2306 @code{\context Voice} declaration, otherwise the main note and grace
2307 note end up on different staves.
2309 Grace note synchronization can also lead to surprises. Staff notation,
2310 such as key signatures, barlines, etc. are also synchronized. Take
2311 care when you mix staves with grace notes and staves without, for example,
2313 @lilypond[relative=2,verbatim,fragment]
2314 << \new Staff { e4 \bar "|:" \grace c16 d4 }
2315 \new Staff { c4 \bar "|:" d4 } >>
2318 Grace sections should only be used within sequential music
2319 expressions. Nesting or juxtaposing grace sections is not supported,
2320 and might produce crashes or other errors.
2322 Overriding settings cannot be done in separate styles for appoggiatura
2327 @subsection Glissando
2330 @cindex @code{\glissando}
2332 A glissando is a smooth change in pitch. It is denoted by a line or a
2333 wavy line between two notes.
2337 A glissando line can be requested by attaching a @code{\glissando} to
2340 @lilypond[fragment,relative,verbatim]
2346 @internalsref{Glissando}, and @internalsref{GlissandoEvent}.
2351 Adding additional texts (such as @emph{gliss.}) is not supported.
2355 @subsection Dynamics
2368 @cindex @code{\ffff}
2378 Absolute dynamic marks are specified using an variable after a
2379 note: @code{c4\ff}. The available dynamic marks are @code{\ppp},
2380 @code{\pp}, @code{\p}, @code{\mp}, @code{\mf}, @code{\f}, @code{\ff},
2381 @code{\fff}, @code{\fff}, @code{\fp}, @code{\sf}, @code{\sff},
2382 @code{\sp}, @code{\spp}, @code{\sfz}, and @code{\rfz}:
2384 @lilypond[verbatim,singleline,fragment,relative]
2385 c'\ppp c\pp c \p c\mp c\mf c\f c\ff c\fff
2391 @cindex @code{\decr}
2392 @cindex @code{\rced}
2399 A crescendo mark is started with @code{\<} and terminated with
2400 @code{\!}. A decrescendo is started with @code{\>} and also terminated
2401 with @code{\!}. Because these marks are bound to notes, if you must
2402 use spacer notes if multiple marks during one note are needed:
2404 @lilypond[fragment,verbatim,center,quote]
2405 c''\< c''\! d''\decr e''\rced
2406 << f''1 { s4 s4\< s4\! \> s4\! } >>
2408 This may give rise to very short hairpins. Use @code{minimum-length}
2409 in @internalsref{Voice}.@internalsref{Hairpin} to lengthen them, for
2413 \property Staff.Hairpin \override #'minimum-length = #5
2416 You can also use a text saying @emph{cresc.} instead of hairpins. Here
2417 is an example how to do it:
2419 @lilypond[fragment,relative=2,verbatim]
2420 c4 \cresc c4 c c c \endcresc c4
2426 You can also supply your own texts:
2427 @lilypond[fragment,relative,verbatim]
2429 \property Voice.crescendoText = \markup { \italic "cresc. poco" }
2430 \property Voice.crescendoSpanner = #'dashed-line
2440 @cindex @code{\dynamicUp}
2442 @cindex @code{\dynamicDown}
2443 @code{\dynamicDown},
2444 @cindex @code{\dynamicBoth}
2445 @code{\dynamicBoth}.
2447 @cindex direction, of dynamics
2451 @internalsref{CrescendoEvent}, @internalsref{DecrescendoEvent}, and
2452 @internalsref{AbsoluteDynamicEvent}.
2454 Dynamics are objects of @internalsref{DynamicText} and
2455 @internalsref{Hairpin}. Vertical positioning of these symbols is
2456 handled by the @internalsref{DynamicLineSpanner} object.
2458 If you want to adjust padding or vertical direction of the dynamics, you
2459 must set properties for the @internalsref{DynamicLineSpanner} object.
2467 @cindex @code{\repeat}
2470 Repetition is a central concept in music, and multiple notations exist
2471 for repetitions. In LilyPond, most of these notations can be captured
2472 in a uniform syntax. One of the advantages is that they can be
2473 rendered in MIDI accurately.
2475 The following types of repetition are supported:
2479 Repeated music is fully written (played) out. Useful for MIDI
2480 output, and entering repetitive music.
2483 This is the normal notation: Repeats are not written out, but
2484 alternative endings (voltas) are printed, left to right.
2488 Alternative endings are written stacked. This has limited use but may be
2489 used to typeset two lines of lyrics in songs with repeats, see
2490 @inputfileref{input,star-spangled-banner.ly}.
2497 Make beat or measure repeats. These look like percent signs.
2503 * Repeats and MIDI::
2504 * Manual repeat commands::
2506 * Tremolo subdivisions::
2511 @subsection Repeat syntax
2515 LilyPond has one syntactic construct for specifying different types of
2516 repeats. The syntax is
2519 \repeat @var{variant} @var{repeatcount} @var{repeatbody}
2522 If you have alternative endings, you may add
2523 @cindex @code{\alternative}
2525 \alternative @code{@{} @var{alternative1}
2527 @var{alternative3} @dots{} @code{@}}
2529 where each @var{alternative} is a music expression. If you do not
2530 give enough alternatives for all of the repeats, then the first
2531 alternative is assumed to be played more than once.
2533 Normal notation repeats are used like this:
2534 @lilypond[fragment,verbatim,relative 1]
2536 \repeat volta 2 { c4 d e f }
2537 \repeat volta 2 { f e d c }
2540 With alternative endings:
2541 @lilypond[fragment,verbatim,relative 1]
2543 \repeat volta 2 {c4 d e f}
2544 \alternative { {d2 d} {f f,} }
2548 @lilypond[fragment,verbatim,relative 1]
2551 \repeat volta 4 { e | c2 d2 | e2 f2 | }
2552 \alternative { { g4 g g } { a | a a a a | b2. } }
2558 If you do a nested repeat like
2567 then it is ambiguous to which @code{\repeat} the @code{\alternative}
2568 belongs. This ambiguity is resolved by always having the
2569 @code{\alternative} belong to the inner @code{\repeat}. For clarity,
2570 it is advisable to use braces in such situations.
2573 @node Repeats and MIDI
2574 @subsection Repeats and MIDI
2576 @cindex expanding repeats
2578 For instructions on how to unfold repeats for MIDI output, see the
2579 example file @inputfileref{input/test,unfold-all-repeats.ly}.
2584 Timing information is not remembered at the start of an alternative,
2585 so after a repeat timing information must be reset by hand, for
2586 example by setting @code{Score.measurePosition} or entering
2587 @code{\partial}. Similarly, slurs or ties are also not repeated.
2590 @node Manual repeat commands
2591 @subsection Manual repeat commands
2593 @cindex @code{repeatCommands}
2595 The property @code{repeatCommands} can be used to control the layout of
2596 repeats. Its value is a Scheme list of repeat commands, where each repeat
2600 @item the symbol @code{start-repeat},
2601 which prints a @code{|:} bar line,
2602 @item the symbol @code{end-repeat},
2603 which prints a @code{:|} bar line,
2604 @item the list @code{(volta @var{text})},
2605 which prints a volta bracket saying @var{text}: The text can be specified as
2606 a text string or as a markup text, see @ref{Text markup}. Do not
2607 forget to change the font, as the default number font does not contain
2608 alphabetic characters. Or,
2609 @item the list @code{(volta #f)}, which
2610 stops a running volta bracket:
2613 @lilypond[verbatim, fragment,relative 2]
2615 \property Score.repeatCommands = #'((volta "93") end-repeat)
2617 \property Score.repeatCommands = #'((volta #f))
2624 @internalsref{VoltaBracket}, @internalsref{RepeatedMusic},
2625 @internalsref{VoltaRepeatedMusic},
2626 @internalsref{UnfoldedRepeatedMusic}, and
2627 @internalsref{FoldedRepeatedMusic}.
2629 @node Tremolo repeats
2630 @subsection Tremolo repeats
2631 @cindex tremolo beams
2633 To place tremolo marks between notes, use @code{\repeat} with tremolo
2635 @lilypond[verbatim,center,singleline]
2637 \context Voice \notes\relative c' {
2638 \repeat "tremolo" 8 { c16 d16 }
2639 \repeat "tremolo" 4 { c16 d16 }
2640 \repeat "tremolo" 2 { c16 d16 }
2641 \repeat "tremolo" 4 c16
2648 Tremolo beams are @internalsref{Beam} objects. Single stem tremolos
2649 are @internalsref{StemTremolo}s. The music expression is
2650 @internalsref{TremoloEvent}.
2655 The single stem tremolo must be entered without @code{@{} and
2658 @node Tremolo subdivisions
2659 @subsection Tremolo subdivisions
2660 @cindex tremolo marks
2661 @cindex @code{tremoloFlags}
2663 Tremolo marks can be printed on a single note by adding
2664 `@code{:}[@var{length}]' after the note. The length must be at least 8.
2665 A @var{length} value of 8 gives one line across the note stem. If the
2666 length is omitted, then then the last value (stored in
2667 @code{Voice.tremoloFlags}) is used:
2669 @lilypond[verbatim,fragment,center]
2670 c'2:8 c':32 | c': c': |
2673 @c [TODO : stok is te kort bij 32en]
2677 Tremolos in this style do not carry over into the MIDI output.
2680 @node Measure repeats
2681 @subsection Measure repeats
2683 @cindex percent repeats
2684 @cindex measure repeats
2686 In the @code{percent} style, a note pattern can be repeated. It is
2687 printed once, and then the pattern is replaced with a special sign.
2688 Patterns of a one and two measures are replaced by percent-like signs,
2689 patterns that divide the measure length are replaced by slashes:
2691 @lilypond[verbatim,singleline]
2692 \context Voice { \repeat "percent" 4 { c'4 }
2693 \repeat "percent" 2 { c'2 es'2 f'4 fis'4 g'4 c''4 }
2699 @internalsref{RepeatSlash}, @internalsref{PercentRepeat},
2700 @internalsref{PercentRepeatedMusic}, and
2701 @internalsref{DoublePercentRepeat}.
2705 @node Rhythmic music
2706 @section Rhythmic music
2708 Sometimes you might want to show only the rhythm of a melody. This
2709 can be done with the rhythmic staff. All pitches of notes on such a
2710 staff are squashed, and the staff itself has a single line:
2712 @lilypond[fragment,relative,verbatim]
2713 \context RhythmicStaff {
2715 c4 e8 f g2 | r4 g r2 | g1:32 | r1 |
2720 * Percussion staves::
2721 * Percussion MIDI output::
2724 @node Percussion staves
2725 @subsection Percussion staves
2729 A percussion part for more than one instrument typically uses a
2730 multiline staff where each position in the staff refers to one piece
2735 Percussion staves are typeset with help of a set of Scheme
2736 functions. The system is based on the general MIDI drum-pitches.
2737 Include @file{drumpitch-init.ly} to use drum pitches. This file
2738 defines the pitches from the Scheme variable @code{drum-pitch-names},
2739 the definition of which can be read in @file{scm/drums.scm}. Each
2740 piece of percussion has a full name and an abbreviated name, and either
2741 the full name or the abbreviation may be used in input files.
2743 To typeset the music on a staff apply the function @code{drums->paper}
2744 to the percussion music. This function takes a list of percussion
2745 instrument names, notehead scripts and staff positions (that is:
2746 pitches relative to the C-clef) and transforms the input
2747 music by moving the pitch, changing the notehead and (optionally)
2750 @lilypond[singleline,verbatim,quote]
2751 \include "drumpitch-init.ly"
2752 up = \notes { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
2753 down = \notes { bassdrum4 snare8 bd r bd sn4 }
2755 \apply #(drums->paper 'drums) \context Staff <<
2757 \new Voice { \voiceOne \up }
2758 \new Voice { \voiceTwo \down }
2763 In the above example the music was transformed using the list @code{'drums}.
2764 The following lists are defined in @file{scm/drums.scm}:
2767 to typeset a typical drum kit on a five-line staff:
2770 \include "drumpitch-init.ly"
2771 nam = \lyrics { cymc cyms cymr hh hhc hho hhho hhp cb hc
2772 bd sn ss tomh tommh tomml toml tomfh tomfl }
2773 mus = \notes { cymc cyms cymr hh hhc hho hhho hhp cb hc
2774 bd sn ss tomh tommh tomml toml tomfh tomfl s16 }
2777 \apply #(drums->paper 'drums) \context Staff <<
2781 \context Lyrics \nam
2784 linewidth = 100.0\mm
2787 \remove Bar_engraver
2788 \remove Time_signature_engraver
2789 minimumVerticalExtent = #'(-4.0 . 5.0)
2793 \remove Stem_engraver
2799 The drum scheme supports six different toms. When there fewer toms, simply
2800 select the toms that produce the desired result, i.e. to get toms on
2801 the three middle lines you use @code{tommh}, @code{tomml} and
2804 Because general MIDI does not contain rimshots the sidestick is used
2805 for this purpose instead.
2807 to typeset timbales on a two line staff:
2809 @lilypond[singleline]
2810 \include "drumpitch-init.ly"
2811 nam = \lyrics { timh ssh timl ssl cb }
2812 mus = \notes { timh ssh timl ssl cb s16 }
2815 \apply #(drums->paper 'timbales) \context Staff <<
2819 \context Lyrics \nam
2824 \remove Bar_engraver
2825 \remove Time_signature_engraver
2826 StaffSymbol \override #'line-count = #2
2827 StaffSymbol \override #'staff-space = #2
2828 minimumVerticalExtent = #'(-3.0 . 4.0)
2832 \remove Stem_engraver
2839 to typeset congas on a two line staff:
2841 @lilypond[singleline]
2842 \include "drumpitch-init.ly"
2843 nam = \lyrics { cgh cgho cghm ssh cgl cglo cglm ssl }
2844 mus = \notes { cgh cgho cghm ssh cgl cglo cglm ssl s16 }
2847 \apply #(drums->paper 'congas) \context Staff <<
2851 \context Lyrics \nam
2856 \remove Bar_engraver
2857 \remove Time_signature_engraver
2858 StaffSymbol \override #'line-count = #2
2859 StaffSymbol \override #'staff-space = #2
2860 minimumVerticalExtent = #'(-3.0 . 4.0)
2864 \remove Stem_engraver
2870 to typeset bongos on a two line staff:
2872 @lilypond[singleline]
2873 \include "drumpitch-init.ly"
2874 nam = \lyrics { boh boho bohm ssh bol bolo bolm ssl }
2875 mus = \notes { boh boho bohm ssh bol bolo bolm ssl s16 }
2878 \apply #(drums->paper 'bongos) \context Staff <<
2882 \context Lyrics \nam
2887 \remove Bar_engraver
2888 \remove Time_signature_engraver
2889 StaffSymbol \override #'line-count = #2
2890 StaffSymbol \override #'staff-space = #2
2891 minimumVerticalExtent = #'(-3.0 . 4.0)
2895 \remove Stem_engraver
2901 to typeset all kinds of simple percussion on one line staves:
2902 @lilypond[singleline]
2903 \include "drumpitch-init.ly"
2904 nam = \lyrics { tri trio trim gui guis guil cb cl tamb cab mar hc }
2905 mus = \notes { tri trio trim gui guis guil cb cl tamb cab mar hc s16 }
2908 \apply #(drums->paper 'percussion) \context Staff <<
2912 \context Lyrics \nam
2917 \remove Bar_engraver
2918 \remove Time_signature_engraver
2919 StaffSymbol \override #'line-count = #1
2920 minimumVerticalExtent = #'(-2.0 . 3.0)
2924 \remove Stem_engraver
2931 If you do not like any of the predefined lists you can define your own
2932 list at the top of your file:
2934 @lilypond[singleline, verbatim]
2935 #(set-drum-kit 'mydrums `(
2936 (bassdrum default #f ,(ly:make-pitch -1 2 0))
2937 (snare default #f ,(ly:make-pitch 0 1 0))
2938 (hihat cross #f ,(ly:make-pitch 0 5 0))
2939 (pedalhihat xcircle "stopped" ,(ly:make-pitch 0 5 0))
2940 (lowtom diamond #f ,(ly:make-pitch -1 6 0))
2942 \include "drumpitch-init.ly"
2943 up = \notes { hh8 hh hh hh hhp4 hhp }
2944 down = \notes { bd4 sn bd toml8 toml }
2946 \apply #(drums->paper 'mydrums) \context Staff <<
2948 \new Voice { \voiceOne \up }
2949 \new Voice { \voiceTwo \down }
2954 To use a modified existing list, one can prepend modifications to the
2958 #(set-drum-kit 'mydrums (append `(
2959 (bassdrum default #f ,(ly:make-pitch -1 2 0))
2960 (lowtom diamond #f ,(ly:make-pitch -1 6 0))
2961 ) (get-drum-kit 'drums)))
2964 You can easily combine percussion notation with pitched notation.
2965 Indeed, the file @file{drumpitch-init.ly} replaces the normal pitch
2966 names, so you will have to reinclude @file{nederlands.ly} after the
2967 drum-pattern-definitions to enter normal notes:
2969 @lilypond[singleline,verbatim]
2970 \include "drumpitch-init.ly"
2971 up = \notes { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
2972 down = \notes { bassdrum4 snare8 bd r bd sn4 }
2973 \include "nederlands.ly"
2974 bass = \notes \transpose c c,, { a4. e8 r e g e }
2977 \apply #(drums->paper 'drums) \new Staff <<
2979 \new Voice { \voiceOne \up }
2980 \new Voice { \voiceTwo \down }
2982 \new Staff { \clef "F_8" \bass }
2987 @node Percussion MIDI output
2988 @subsection Percussion MIDI output
2990 In order to produce correct MIDI output you need to produce two score
2991 blocks---one for the paper and one for the MIDI output. To use the
2992 percussion channel you set the property @code{instrument} to
2993 @code{'drums}. Because the drum-pitches themselves are similar to the
2994 general MIDI pitches all you have to do is to insert the voices with
2995 none of the scheme functions to get the correct MIDI output:
2999 \apply #(drums->paper 'mydrums) \context Staff <<
3008 \property Staff.instrument = #'drums
3017 This scheme is a temporary implementation.
3021 @section Piano music
3023 Piano staves are two normal staves coupled with a brace. The staves
3024 are largely independent, but sometimes voices can cross between the
3025 two staves. The same notation is also used for harps and other key
3026 instruments. The @internalsref{PianoStaff} is especially built to
3027 handle this cross-staffing behavior. In this section we discuss the
3028 @internalsref{PianoStaff} and some other pianistic peculiarities.
3032 * Automatic staff changes::
3033 * Manual staff switches::
3036 * Staff switch lines::
3041 There is no support for putting chords across staves. You can get
3042 this result by increasing the length of the stem in the lower stave so
3043 it reaches the stem in the upper stave, or vice versa. An example is
3044 included with the distribution as @inputfileref{input/test,stem-cross-staff.ly}.
3046 Dynamics are not centered, but kludges do exist. See
3047 @inputfileref{input/template,piano-dynamics.ly}.
3049 @cindex cross staff stem
3050 @cindex stem, cross staff
3053 @c fixme: should have hyperlinks as well.
3059 @node Automatic staff changes
3060 @subsection Automatic staff changes
3061 @cindex Automatic staff changes
3063 Voices can switch automatically between the top and the bottom
3064 staff. The syntax for this is
3066 \autochange Staff \context Voice @{ @dots{}@var{music}@dots{} @}
3068 The two staffs of the piano staff must be named @code{up} and
3071 The autochanger switches on basis of pitch (central C is the turning
3072 point), and it looks ahead skipping over rests to switch in
3073 advance. Here is a practical example:
3075 @lilypond[verbatim,singleline,quote]
3076 \score { \notes \context PianoStaff <<
3077 \context Staff = "up" {
3078 \autochange Staff \context Voice = VA << \relative c' {
3079 g4 a b c d r4 a g } >> }
3080 \context Staff = "down" {
3087 In this example, spacer rests are used to prevent the bottom staff from
3088 terminating too soon.
3093 @internalsref{AutoChangeMusic}.
3097 The staff switches often do not end up in optimal places. For high
3098 quality output, staff switches should be specified manually.
3102 @node Manual staff switches
3103 @subsection Manual staff switches
3105 @cindex manual staff switches
3106 @cindex staff switch, manual
3108 Voices can be switched between staves manually, using the following command:
3110 \translator Staff = @var{staffname} @var{music}
3114 The string @var{staffname} is the name of the staff. It switches the
3115 current voice from its current staff to the Staff called
3116 @var{staffname}. Typically @var{staffname} is @code{"up"} or
3124 Pianos have pedals that alter the way sound are produced. Generally, a
3125 piano has three pedals, sustain, una corda, and sostenuto.
3129 Piano pedal instruction can be expressed by attaching
3130 @code{\sustainDown}, @code{\sustainUp}, @code{\unaCorda},
3131 @code{\treCorde}, @code{\sostenutoDown} and @code{\sostenutoUp} to a
3134 @lilypond[fragment,verbatim]
3135 c'4\sustainDown c'4\sustainUp
3138 What is printed can be modified by setting @code{pedal@var{X}Strings},
3139 where @var{X} is one of the pedal types: @code{Sustain},
3140 @code{Sostenuto} or @code{UnaCorda}. Refer to the generated
3141 documentation of @internalsref{SustainPedal} for more information.
3143 Pedals can also be indicated by a sequence of brackets, by setting the
3144 @code{pedalSustainStyle} property to @code{bracket} objects:
3146 @lilypond[fragment,verbatim]
3147 \property Staff.pedalSustainStyle = #'bracket
3148 c''4\sustainDown d''4 e''4
3149 a'4\sustainUp\sustainDown
3150 f'4 g'4 a'4\sustainUp
3153 A third style of pedal notation is a mixture of text and brackets,
3154 obtained by setting @code{pedal-type} to @code{mixed}:
3156 @lilypond[fragment,verbatim]
3157 \property Staff.pedalSustainStyle = #'mixed
3158 c''4\sustainDown d''4 e''4
3159 c'4\sustainUp\sustainDown
3160 f'4 g'4 a'4\sustainUp
3163 The default `*Ped' style for sustain and damper pedals corresponds to
3164 @code{\pedal-type = #'text}. However, @code{mixed} is the default style
3165 for a sostenuto pedal:
3167 @lilypond[fragment,verbatim]
3168 c''4\sostenutoDown d''4 e''4 c'4 f'4 g'4 a'4\sostenutoUp
3171 For fine-tuning of the appearance of a pedal bracket, the properties
3172 @code{edge-width}, @code{edge-height}, and @code{shorten-pair} of
3173 @code{PianoPedalBracket} objects (see
3174 @internalsref{PianoPedalBracket} in the Program reference) can be modified. For example, the
3175 bracket may be extended to the end of the note head:
3177 @lilypond[fragment,verbatim]
3178 \property Staff.PianoPedalBracket \override
3179 #'shorten-pair = #'(0 . -1.0)
3180 c''4\sostenutoDown d''4 e''4 c'4
3181 f'4 g'4 a'4\sostenutoUp
3185 @subsection Arpeggio
3188 @cindex broken arpeggio
3189 @cindex @code{\arpeggio}
3191 You can specify an arpeggio sign on a chord by attaching an
3192 @code{\arpeggio} to a chord:
3195 @lilypond[fragment,relative,verbatim]
3199 When an arpeggio crosses staves, you attach an arpeggio to the chords
3200 in both staves, and set
3201 @internalsref{PianoStaff}.@code{connectArpeggios}:
3203 @lilypond[fragment,relative,verbatim]
3204 \context PianoStaff <<
3205 \property PianoStaff.connectArpeggios = ##t
3206 \new Staff { <c' e g c>\arpeggio }
3207 \new Staff { \clef bass <c,, e g>\arpeggio }
3211 The direction of the arpeggio is sometimes denoted by adding an
3212 arrowhead to the wiggly line. This can be typeset by setting
3213 @code{arpeggio-direction}:
3215 @lilypond[fragment,relative,verbatim]
3217 \property Voice.Arpeggio \set #'arpeggio-direction = #1
3219 \property Voice.Arpeggio \set #'arpeggio-direction = #-1
3224 A square bracket on the left indicates that the player should not
3225 arpeggiate the chord. To draw these brackets, set the
3226 @code{molecule-callback} property of @code{Arpeggio} or
3227 @code{PianoStaff.Arpeggio} objects to @code{\arpeggioBracket}, and use
3228 @code{\arpeggio} statements within the chords as before:
3230 @lilypond[fragment,relative,verbatim]
3231 \property PianoStaff.Arpeggio \override
3232 #'molecule-callback = \arpeggioBracket
3238 @cindex @code{\arpeggioBracket}
3239 @code{\arpeggioBracket},
3240 @cindex @code{\arpeggio}
3245 @internalsref{ArpeggioEvent} music expressions lead to
3246 @internalsref{Arpeggio} objects. Cross staff arpeggios are
3247 @internalsref{PianoStaff}.@internalsref{Arpeggio}.
3251 It is not possible to mix connected arpeggios and unconnected
3252 arpeggios in one @internalsref{PianoStaff} at the same time.
3254 @node Staff switch lines
3255 @subsection Staff switch lines
3258 @cindex follow voice
3259 @cindex staff switching
3262 @cindex @code{followVoice}
3264 Whenever a voice switches to another staff a line connecting the notes
3265 can be printed automatically. This is enabled if the property
3266 @code{PianoStaff.followVoice} is set to true:
3268 @lilypond[fragment,relative,verbatim]
3269 \context PianoStaff <<
3270 \property PianoStaff.followVoice = ##t
3271 \context Staff \context Voice {
3273 \translator Staff=two
3276 \context Staff=two { \clef bass \skip 1*2 }
3280 The associated object is @internalsref{VoiceFollower}.
3284 @cindex @code{\showStaffSwitch}
3285 @code{\showStaffSwitch},
3286 @cindex @code{\hideStaffSwitch}
3287 @code{\hideStaffSwitch}.
3291 @section Vocal music
3293 This section discusses how to enter and print lyrics.
3297 * The Lyrics context::
3302 @node Entering lyrics
3303 @subsection Entering lyrics
3307 @cindex @code{\lyrics}
3310 Lyrics are entered in a special input mode. This mode is is introduced
3311 by the keyword @code{\lyrics}. In this mode you can enter lyrics, with
3312 punctuation and accents without any hassle. Syllables are entered like
3313 notes, but with pitches replaced by text. For example,
3315 \lyrics @{ Twin-4 kle4 twin- kle litt- le star2 @}
3318 A word in Lyrics mode begins with: an alphabetic character, @code{_},
3319 @code{?}, @code{!}, @code{:}, @code{'}, the control characters @code{^A}
3320 through @code{^F}, @code{^Q} through @code{^W}, @code{^Y}, @code{^^},
3321 any 8-bit character with ASCII code over 127, or a two-character
3322 combination of a backslash followed by one of @code{`}, @code{'},
3323 @code{"}, or @code{^}.
3325 Subsequent characters of a word can be any character that is not a digit
3326 and not white space. One important consequence of this is that a word
3327 can end with @code{@}}. The following example is usually a bug. The
3328 syllable includes a @code{@}}, and hence the opening brace is not balanced:
3330 \lyrics @{ twinkle@}
3333 @cindex @code{\property}, in @code{\lyrics}
3334 Similarly, a period following a alphabetic sequence, is included in the
3335 resulting string. As a consequence, spaces must be inserted around
3336 @code{\property} commands:
3338 \property Lyrics . LyricText \set #'font-shape = #'italic
3342 @cindex spaces, in lyrics
3343 @cindex quotes, in lyrics
3345 Any @code{_} character which appears in an unquoted word is converted
3346 to a space. This provides a mechanism for introducing spaces into words
3347 without using quotes. Quoted words can also be used in Lyrics mode to
3348 specify words that cannot be written with the above rules:
3351 \lyrics @{ He said: "\"Let" my peo ple "go\"" @}
3355 Hyphens can be entered as ordinary hyphens at the end of a syllable, i.e.
3360 These will be attached to the end of the first syllable.
3362 Centered hyphens are entered using the special `@code{-}@code{-}' lyric
3363 as a separate word between syllables. The hyphen will have variable
3364 length depending on the space between the syllables and it will be
3365 centered between the syllables.
3370 When a lyric is sung over many notes (this is called a melisma), this is
3371 indicated with a horizontal line centered between a syllable and the
3372 next one. Such a line is called an extender line, and it is entered as
3377 @internalsref{LyricEvent}, @internalsref{HyphenEvent}, and
3378 @internalsref{ExtenderEvent}.
3382 The definition of lyrics mode is too complex.
3384 @node The Lyrics context
3385 @subsection The Lyrics context
3387 Lyrics are printed by interpreting them in @internalsref{Lyrics} context:
3389 \context Lyrics \lyrics @dots{}
3392 @cindex automatic syllable durations
3393 @cindex @code{\addlyrics}
3394 @cindex lyrics and melodies
3396 This will place the lyrics according to the durations that were
3397 entered. The lyrics can also be aligned under a given melody
3398 automatically. In this case, it is no longer necessary to enter the
3399 correct duration for each syllable. This is achieved by combining the
3400 melody and the lyrics with the @code{\addlyrics} expression:
3404 \context Lyrics @dots{}
3407 @cindex staff order, with @code{\addlyrics}
3409 Normally, this will put the lyrics below the staff. For different or
3410 more complex orderings, the best way is to setup the hierarchy of
3411 staves and lyrics first, e.g.
3413 \context ChoirStaff \notes <<
3414 \context Lyrics = sopr @{ s1 @}
3415 \context Staff = soprStaff @{ s1 @}
3416 \context Lyrics = tenor @{ s1 @}
3417 \context Staff = tenorStaff @{ s1 @}
3420 and then combine the appropriate melodies and lyric lines:
3423 \context Staff = soprStaff @emph{the music}
3424 \context Lyrics = sopr @emph{the lyrics}
3427 putting both together, you would get
3429 \context ChoirStaff \notes <<
3430 \context Lyrics = @dots{}
3431 \context Staff = @dots{}
3437 @cindex choral score
3439 A complete example of a SATB score setup is in the file
3440 @inputfileref{input/template,satb.ly}.
3444 @internalsref{LyricCombineMusic}, @internalsref{Lyrics}, and
3445 @inputfileref{input/template,satb.ly}.
3449 @code{\addlyrics} is not automatic enough: melismata are not detected
3450 automatically, and melismata are not stopped when they hit a rest. A
3451 melisma on the last note in a melody is not printed.
3455 @subsection More stanzas
3458 @cindex phrasing, in lyrics
3460 When multiple stanzas are printed underneath each other, the vertical
3461 groups of syllables should be aligned around punctuation. This can be
3462 done automatically when corresponding lyric lines and melodies are
3465 To this end, give the @internalsref{Voice} context an identity:
3467 \context Voice = duet @{
3472 Then set the @internalsref{LyricsVoice} contexts to names starting with
3473 that identity followed by a dash. In the preceding example, the
3474 @internalsref{Voice} identity is @code{duet}, so the identities of the
3475 @internalsref{LyricsVoice}s are marked @code{duet-1} and @code{duet-2}:
3477 \context LyricsVoice = "duet-1" @{
3478 Hi, my name is bert. @}
3479 \context LyricsVoice = "duet-2" @{
3480 Ooooo, ch\'e -- ri, je t'aime. @}
3482 The convention for naming @internalsref{LyricsVoice} and
3483 @internalsref{Voice} must also be used to get melismata correct in
3484 conjunction with rests.
3486 The complete example is shown here:
3487 @lilypond[singleline,verbatim]
3490 \notes \relative c'' \context Voice = duet { \time 3/4
3492 \lyrics \context Lyrics <<
3493 \context LyricsVoice = "duet-1" {
3494 \property LyricsVoice . stanza = "Bert"
3495 Hi, my name is bert. }
3496 \context LyricsVoice = "duet-2" {
3497 \property LyricsVoice . stanza = "Ernie"
3498 Ooooo, ch\'e -- ri, je t'aime. }
3503 Stanza numbers, or the names of the singers can be added by setting
3504 @code{LyricsVoice.Stanza} (for the first system) and
3505 @code{LyricsVoice.stz} for the following systems. Notice how dots are
3506 surrounded with spaces in @code{\lyrics} mode:
3509 \property LyricsVoice . stanza = "Bert"
3511 \property LyricsVoice . stanza = "Ernie"
3514 To make empty spaces in lyrics, use @code{\skip}.
3522 Input for lyrics introduces a syntactical ambiguity:
3529 is interpreted as assigning a string identifier @code{\foo} such that
3530 it contains @code{"bar"}. However, it could also be interpreted as
3531 making or a music identifier @code{\foo} containing the syllable
3532 `bar'. The force the latter interpretation, use
3542 The term @emph{ambitus} denotes a range of pitches for a given voice in
3543 a part of music. It also may denote the pitch range that a musical
3544 instrument is capable of playing. Most musical instruments have their
3545 ambitus standardized (or at least there is agreement upon the minimal
3546 ambitus of a particular type of instrument), such that a composer or
3547 arranger of a piece of music can easily meet the ambitus constraints of
3548 the targeted instrument. However, the ambitus of the human voice
3549 depends on individual physiological state, including education and
3550 training of the voice. Therefore, a singer potentially has to check for
3551 each piece of music if the ambitus of that piece meets his individual
3552 capabilities. This is why the ambitus of a piece may be of particular
3553 value to vocal performers.
3555 The ambitus is typically notated on a per-voice basis at the very
3556 beginning of a piece, e.g. nearby the initial clef or time signature of
3557 each staff. The range is graphically specified by two noteheads, that
3558 represent the minimum and maximum pitch. Some publishers use a textual
3559 notation: they put the range in words in front of the corresponding
3560 staff. LilyPond only supports the graphical ambitus notation.
3562 To apply, add the @internalsref{Ambitus_engraver} to the
3563 @internalsref{Voice} context, i.e.
3569 \consists Ambitus_engraver
3574 This results in the following output:
3575 @lilypond[singleline]
3576 upper = \notes \relative c {
3579 as'' c e2 bes f cis d4 e f2 g
3581 lower = \notes \relative c {
3584 e'4 b g a c es fis a cis b a g f e d2
3587 \context ChoirStaff {
3589 \new Staff { \upper }
3590 \new Staff { \lower }
3596 \consists Ambitus_engraver
3602 If you have multiple voices in a single staff, and you want a single
3603 ambitus per staff rather than per each voice, then add the
3604 @internalsref{Ambitus_engraver} to the @internalsref{Staff} context
3605 rather than to the @internalsref{Voice} context.
3607 It is possible to tune individual ambiti for multiple voices on a
3608 single staff, for example by erasing or shifting them horizontally. An
3609 example is in @inputfileref{input/test,ambitus-mixed.ly}
3613 @internalsref{Ambitus}, @inputfileref{input/regression,ambitus.ly},
3614 @inputfileref{input/test,ambitus-mixed.ly}.
3618 There is no collision handling in the case of multiple per-voice
3624 Tablature notation is used for notating music for plucked string
3625 instruments. It notates pitches not by using note heads, but by
3626 indicating on which string and fret a note must be played. LilyPond
3627 offers limited support for tablature.
3630 * Tablatures basic::
3631 * Non-guitar tablatures::
3634 @node Tablatures basic
3635 @subsection Tablatures basic
3636 @cindex Tablatures basic
3638 The string number associated to a note is given as a backslash
3639 followed by a number, e.g. @code{c4\3} for a C quarter on the third
3640 string. By default, string 1 is the highest one, and the tuning
3641 defaults to the standard guitar tuning (with 6 strings). The notes
3642 are printed as tablature, by using @internalsref{TabStaff} and
3643 @internalsref{TabVoice} contexts:
3645 @lilypond[fragment,verbatim]
3646 \notes \context TabStaff {
3652 When no string is specified, the first string that does not give a
3653 fret number less than @code{minimumFret} is selected. The default
3654 value for @code{minimumFret} is 0:
3658 e8 fis gis a b cis' dis' e'
3659 \property TabStaff.minimumFret = #8
3660 e8 fis gis a b cis' dis' e'
3665 e8 fis gis a b cis' dis' e'
3666 \property TabStaff.minimumFret = #8
3667 e8 fis gis a b cis' dis' e'
3670 \context StaffGroup <<
3671 \context Staff { \clef "G_8" \frag }
3672 \context TabStaff { \frag }
3679 @internalsref{TabStaff}, @internalsref{TabVoice}, and
3680 @internalsref{StringNumberEvent}.
3684 Chords are not handled in a special way, and hence the automatic
3685 string selector may easily select the same string to two notes in a
3689 @node Non-guitar tablatures
3690 @subsection Non-guitar tablatures
3691 @cindex Non-guitar tablatures
3693 You can change the number of strings, by setting the number of lines
3694 in the @internalsref{TabStaff} (the @code{line-count} property of
3695 @internalsref{TabStaff} can only be changed using
3696 @code{\outputproperty}, for more information, see @ref{Tuning
3699 You can change the tuning of the strings. A string tuning is given as
3700 a Scheme list with one integer number for each string, the number
3701 being the pitch (measured in semitones relative to central C) of an
3702 open string. The numbers specified for @code{stringTuning} are the
3703 numbers of semitones to subtract or add, starting the specified pitch
3704 by default middle C, in string order. Thus, the notes are e, a, d, and
3707 @lilypond[fragment,verbatim]
3708 \context TabStaff <<
3710 \outputproperty #(make-type-checker 'staff-symbol-interface)
3712 \property TabStaff.stringTunings = #'(-5 -10 -15 -20)
3715 a,4 c' a e' e c' a e'
3720 It is possible to change the Scheme function to format the tablature
3721 note text. The default is @code{fret-number-tablature-format}, which
3722 uses the fret number. For instruments that do not use this notation,
3723 you can create a special tablature formatting function. This function
3724 takes three argument: string number, string tuning and note pitch.
3728 No guitar special effects have been implemented.
3733 @section Chord names
3736 LilyPond has support for both printing chord names. Chords may be
3737 entered in musical chord notation, i.e. @code{< .. >}, but they can
3738 also be entered by name. Internally, the chords are represented as a
3739 set of pitches, so they can be transposed:
3742 @lilypond[verbatim,singleline]
3743 twoWays = \notes \transpose c c' {
3753 << \context ChordNames \twoWays
3754 \context Voice \twoWays >> }
3757 This example also shows that the chord printing routines do not try to
3758 be intelligent. The last chord (@code{f bes d}) is not interpreted as
3764 * Printing chord names::
3769 @subsection Chords mode
3772 Chord mode is a mode where you can input sets of pitches using common
3773 names. It is introduced by the keyword @code{\chords}.
3774 In chords mode, a chord is entered by the root, which is entered
3775 like a common pitch:
3776 @lilypond[fragment,verbatim,quote, relative=1]
3777 \chords { es4. d8 c2 }
3782 Other chords may be entered by suffixing a colon, and introducing a
3783 modifier, and optionally, a number:
3785 @lilypond[fragment,verbatim,quote]
3786 \chords { e1:m e1:7 e1:m7 }
3788 The first number following the root is taken to be the `type' of the
3789 chord, thirds are added to the root until it reaches the specified
3791 @lilypond[fragment,verbatim]
3792 \chords { c:3 c:5 c:6 c:7 c:8 c:9 c:10 c:11 }
3795 @cindex root of chord
3796 @cindex additions, in chords
3797 @cindex removals, in chords
3799 More complex chords may also be constructed adding separate steps
3800 to a chord. Additions are added after the number following
3801 the colon, and are separated by dots:
3803 @lilypond[verbatim,fragment,quote]
3804 \chords { c:5.6 c:3.7.8 c:3.6.13 }
3806 Chord steps can be altered by suffixing a @code{-} or @code{+} sign
3808 @lilypond[verbatim,fragment,quote]
3809 \chords { c:7+ c:5+.3- c:3-.5-.7- }
3811 Removals are specified similarly, and are introduced by a caret. They
3812 must come after the additions:
3813 @lilypond[verbatim,fragment]
3814 \chords { c^3 c:7^5 c:9^3.5 }
3817 Modifiers can be used to change pitches. The following modifiers are
3821 is the minor chord. This modifier lowers the 3rd and (if present) the 7th step.
3823 is the diminished chord. This modifier lowers the 3rd, 5th and (if present)
3826 is the augmented chord. This modifier raises the 5th step.
3828 is the major 7th chord. This modifier raises the 7th step if present.
3830 is the suspended 4th or 2nd. This modifier removes the 3rd
3831 step. Append either @code{2} or @code{4} to add the 2nd or 4th step to
3834 Modifiers can be mixed with additions:
3835 @lilypond[verbatim,fragment]
3836 \chords { c:sus4 c:7sus4 c:dim7 c:m6 }
3839 @cindex modifiers, in chords.
3846 Since an unaltered 11 does not sound good when combined with an
3847 unaltered 13, the 11 is removed in this case (unless it is added
3850 @lilypond[fragment,verbatim]
3851 \chords { c:13 c:13.11 c:m13 }
3856 An inversion (putting one pitch of the chord on the bottom), as well
3857 as bass notes, can be specified by appending
3858 @code{/}@var{pitch} to the chord:
3859 @lilypond[fragment,verbatim,center]
3860 \chords { c1 c/g c/f }
3864 A bass note can be added instead of transposed out of the chord,
3865 by using @code{/+}@var{pitch}.
3867 @lilypond[fragment,verbatim,center]
3868 \chords { c1 c/+g c/+f }
3871 Chords is a mode similar to @code{\lyrics}, @code{\notes} etc. Most
3872 of the commands continue to work, for example, @code{r} and
3873 @code{\skip} can be used to insert rests and spaces, and
3874 @code{\property} may be used to change various settings.
3880 Each step can only be present in a chord once. The following
3881 simply produces the augmented chord, since @code{5+} is interpreted
3884 @lilypond[verbatim,fragment]
3885 \chords { c:5.5-.5+ }
3889 @node Printing chord names
3890 @subsection Printing chord names
3892 @cindex printing chord names
3896 For displaying printed chord names, use the @internalsref{ChordNames} context.
3897 The chords may be entered either using the notation
3898 described above, or directly using @code{<} and @code{>}:
3900 @lilypond[verbatim,singleline]
3902 \chords {a1 b c} <d' f' a'> <e' g' b'>
3906 \context ChordNames \scheme
3907 \context Staff \scheme
3912 You can make the chord changes stand out by setting
3913 @internalsref{ChordNames}.@code{chordChanges} to true. This will only
3914 display chord names when there is a change in the chords scheme and at
3915 the start of a new line:
3917 @lilypond[verbatim, linewidth=9cm]
3919 c1:m c:m \break c:m c:m d
3923 \context ChordNames {
3924 \property ChordNames.chordChanges = ##t
3926 \context Staff \transpose c c' \scheme
3931 The default chord name layout is a system for Jazz music, proposed by
3932 Klaus Ignatzek (see @ref{Literature list}). It can be tuned through the
3933 following properties:
3936 @cindex chordNameExceptions
3937 @item chordNameExceptions
3938 This is a list that contains the chords that have special formatting.
3940 @inputfileref{input/regression,chord-name-exceptions.ly}.
3941 @cindex exceptions, chord names.
3944 @cindex majorSevenSymbol
3945 @item majorSevenSymbol
3946 This property contains the markup object used for the 7th step, when
3947 it is major. Predefined options are @code{whiteTriangleMarkup} and
3948 @code{blackTriangleMarkup}. See
3949 @inputfileref{input/regression,chord-name-major7.ly} for an example.
3951 @cindex chordNameSeparator
3952 @item chordNameSeparator
3953 Different parts of a chord name are normally separated by a
3954 slash. By setting @code{chordNameSeparator}, you can specify other
3956 @lilypond[fragment,verbatim]
3957 \context ChordNames \chords {
3959 \property ChordNames.chordNameSeparator
3960 = \markup { \typewriter "|" }
3964 @cindex chordRootNamer
3965 @item chordRootNamer
3966 The root of a chord is usually printed as a letter with an optional
3967 alteration. The transformation from pitch to letter is done by this
3968 function. Special note names (for example, the German ``H'' for a
3969 B-chord) can be produced by storing a new function in this property.
3971 The pre-defined variables @code{\germanChords},
3972 @code{\semiGermanChords} set these variables.
3975 @cindex chordNoteNamer
3976 @item chordNoteNamer
3977 The default is to print single pitch, e.g. the bass note, using the
3978 @code{chordRootNamer}. The @code{chordNoteNamer} property can be set
3979 to a specialized function to change this behavior. For example, the
3980 base can be printed in lower case.
3985 There are also two other chord name schemes implemented: an alternate
3986 Jazz chord notation, and a systematic scheme called Banter chords. The
3987 alternate jazz notation is also shown on the chart in @ref{Chord name
3988 chart}. Turning on these styles is described in the input file
3989 @inputfileref{input/test,chord-names-jazz.ly}.
3993 @cindex chords, jazz
3998 @cindex @code{\germanChords}
3999 @code{\germanChords},
4000 @cindex @code{\semiGermanChords}
4001 @code{\semiGermanChords}.
4008 @inputfileref{input/regression,chord-name-major7.ly},
4009 @inputfileref{input/regression,chord-name-exceptions.ly},
4010 @inputfileref{input/test,chord-names-jazz.ly},
4011 @inputfileref{input/test,chord-names-german.ly},
4012 @file{scm/chords-ignatzek.scm}, and @file{scm/chord-entry.scm}.
4017 Chord names are determined solely from the list of pitches. Chord
4018 inversions are not identified, and neither are added bass notes. This
4019 may result in strange chord names when chords are entered with the
4020 @code{< .. >} syntax.
4025 @node Orchestral music
4026 @section Orchestral music
4028 @cindex Writing parts
4030 Orchestral music involves some special notation, both in the full
4031 score and the individual parts. This section explains how to tackle
4032 some common problems in orchestral music.
4037 * Multiple staff contexts::
4040 * Instrument names::
4042 * Multi measure rests::
4043 * Automatic part combining::
4045 * Different editions from one source::
4046 * Sound output for transposing instruments::
4049 @node Multiple staff contexts
4050 @subsection Multiple staff contexts
4052 Polyphonic scores consist of many staves. These staves can be
4053 constructed in three different ways:
4055 @item The group is started with a brace at the left. This is done with the
4056 @internalsref{GrandStaff} context.
4057 @item The group is started with a bracket. This is done with the
4058 @internalsref{StaffGroup} context
4059 @item The group is started with a vertical line. This is the default
4063 @cindex Staff, multiple
4064 @cindex bracket, vertical
4065 @cindex brace, vertical
4072 @node Rehearsal marks
4073 @subsection Rehearsal marks
4074 @cindex Rehearsal marks
4076 @cindex @code{\mark}
4078 To print a rehearsal mark, use the @code{\mark} command:
4079 @lilypond[fragment,verbatim]
4089 The mark is incremented automatically if you use @code{\mark
4090 \default}. The value to use is stored in the property
4091 @code{rehearsalMark} is used and automatically incremented.
4093 The @code{\mark} command can also be used to put signs like coda,
4094 segno and fermatas on a barline. Use @code{\markup} to
4095 to access the appropriate symbol:
4097 @lilypond[fragment,verbatim,relative=1]
4098 c1 \mark \markup { \musicglyph #"scripts-ufermata" }
4102 In this case, during line breaks,
4103 marks must also be printed at the end of the line, and not at the
4104 beginning. Use the following to force that behavior:
4106 \property Score.RehearsalMark \override
4107 #'break-visibility = #begin-of-line-invisible
4110 See @inputfileref{input/test,boxed-molecule.ly} for putting boxes
4116 @cindex barlines, putting symbols on
4120 @internalsref{MarkEvent}, @internalsref{RehearsalMark}, and
4121 @inputfileref{input/test,boxed-molecule.ly}.
4125 @subsection Bar numbers
4129 @cindex measure numbers
4130 @cindex currentBarNumber
4132 Bar numbers are printed by default at the start of the line. The
4133 number itself is stored in the
4134 @code{currentBarNumber} property,
4135 which is normally updated automatically for every measure.
4137 Bar numbers can be typeset at regular intervals instead of at the
4138 beginning of each line. This is illustrated in the following example,
4139 whose source is available as
4140 @inputfileref{input/test,bar-number-regular-interval.ly}:
4142 @lilypondfile[notexidoc]{bar-number-regular-interval.ly}
4147 @internalsref{BarNumber},
4148 @inputfileref{input/test,bar-number-every-five-reset.ly}, and
4149 @inputfileref{input/test,bar-number-regular-interval.ly}.
4153 Bar numbers can collide with the @internalsref{StaffGroup} bracket, if
4154 there is one at the top. To solve this, the
4155 @code{padding} property of @internalsref{BarNumber} can be
4156 used to position the number correctly.
4158 @node Instrument names
4159 @subsection Instrument names
4161 In an orchestral score, instrument names are printed left side of the
4164 This can be achieved by setting @internalsref{Staff}.@code{instrument}
4165 and @internalsref{Staff}.@code{instr}. This will print a string before
4166 the start of the staff. For the first start, @code{instrument} is
4167 used, for the next ones @code{instr} is used:
4170 @lilypond[verbatim,singleline]
4171 \property Staff.instrument = "ploink " { c''4 }
4175 You can also use markup texts to construct more complicated instrument
4179 @lilypond[fragment,verbatim,singleline]
4181 \property Staff.instrument = \markup {
4182 \column < "Clarinetti"
4184 \smaller \musicglyph #"accidentals--1"
4195 @internalsref{InstrumentName}.
4199 When you put a name on a grand staff or piano staff the width of the
4200 brace is not taken into account. You must add extra spaces to the end of
4201 the name to avoid a collision.
4204 @subsection Transpose
4206 @cindex transposition of pitches
4207 @cindex @code{\transpose}
4209 A music expression can be transposed with @code{\transpose}. The syntax
4212 \transpose @var{from} @var{to} @var{musicexpr}
4215 This means that @var{musicexpr} is transposed by the interval
4216 between @var{from} and @var{to}.
4218 @code{\transpose} distinguishes between enharmonic pitches: both
4219 @code{\transpose c cis} or @code{\transpose c des} will transpose up
4220 half a tone. The first version will print sharps and the second
4221 version will print flats:
4223 @lilypond[singleline, verbatim]
4224 mus =\notes { \key d \major cis d fis g }
4225 \score { \notes \context Staff {
4228 \transpose c g' \mus
4229 \transpose c f' \mus
4235 @internalsref{TransposedMusic}, and @internalsref{UntransposableMusic}.
4239 If you want to use both @code{\transpose} and @code{\relative}, then
4240 you must put @code{\transpose} outside of @code{\relative}, since
4241 @code{\relative} will have no effect music that appears inside a
4247 @node Multi measure rests
4248 @subsection Multi measure rests
4249 @cindex multi measure rests
4250 @cindex Rests, multi measure
4254 Multi measure rests are entered using `@code{R}'. It is specifically
4255 meant for full bar rests and for entering parts: the rest can expand
4256 to fill a score with rests, or it can be printed as a single
4257 multimeasure rest. This expansion is controlled by the property
4258 @code{Score.skipBars}. If this is set to true, empty measures will not
4259 be expanded, and the appropriate number is added automatically:
4261 @lilypond[fragment,verbatim]
4262 \time 4/4 r1 | R1 | R1*2
4263 \property Score.skipBars = ##t R1*17 R1*4
4266 The @code{1} in @code{R1} is similar to the duration notation used for
4267 notes. Hence, for time signatures other than 4/4, you must enter other
4268 durations. This can be done with augmentation dots or fractions:
4270 @lilypond[fragment,verbatim]
4271 \property Score.skipBars = ##t
4279 An @code{R} spanning a single measure is printed as either a whole rest
4280 or a breve, centered in the measure regardless of the time signature.
4282 @cindex text on multi-measure rest
4283 @cindex script on multi-measure rest
4284 @cindex fermata on multi-measure rest
4286 Texts can be added to multi-measure rests by using the
4287 @var{note}-@code{markup} syntax (see @ref{Text markup}). In this case, the number is
4288 replaced. If you need both texts and the number, you must add the
4289 number by hand. A variable (@code{\fermataMarkup}) is provided for
4293 @lilypond[verbatim,fragment]
4295 R2._\markup { "Ad lib" }
4300 @cindex whole rests for a full measure
4304 @internalsref{MultiMeasureRestEvent},
4305 @internalsref{MultiMeasureTextEvent},
4306 @internalsref{MultiMeasureRestMusicGroup}, and
4307 @internalsref{MultiMeasureRest}.
4309 The layout object @internalsref{MultiMeasureRestNumber} is for the
4310 default number, and @internalsref{MultiMeasureRestText} for user
4315 It is not possible to use fingerings (e.g. @code{R1-4}) to put numbers
4316 over multi-measure rests.
4318 @cindex condensing rests
4320 There is no way to automatically condense multiple rests into a single
4321 multimeasure rest. Multi measure rests do not take part in rest
4324 Be careful when entering multimeasure rests followed by whole
4325 notes. The following will enter two notes lasting four measures each:
4329 When @code{skipBars} is set, then the result will look OK, but the
4330 bar numbering will be off.
4332 @node Automatic part combining
4333 @subsection Automatic part combining
4334 @cindex automatic part combining
4335 @cindex part combiner
4338 Automatic part combining is used to merge two parts of music onto a
4339 staff. It is aimed at typesetting orchestral scores. When the two
4340 parts are identical for a period of time, only one is shown. In
4341 places where the two parts differ, they are typeset as separate
4342 voices, and stem directions are set automatically. Also, solo and
4343 @emph{a due} parts are identified and can be marked.
4347 The syntax for part combining is
4350 \partcombine @var{context} @var{musicexpr1} @var{musicexpr2}
4352 where the pieces of music @var{musicexpr1} and @var{musicexpr2} will be
4353 combined into one context of type @var{context}. The music expressions
4354 must be interpreted by contexts whose names should start with @code{one}
4357 The following example demonstrates the basic functionality of the part
4358 combiner: putting parts on one staff, and setting stem directions and
4361 @lilypond[verbatim,singleline,fragment]
4363 \context Voice=one \partcombine Voice
4364 \context Thread=one \relative c'' {
4367 \context Thread=two \relative c'' {
4373 The first @code{g} appears only once, although it was
4374 specified twice (once in each part). Stem, slur and tie directions are
4375 set automatically, depending whether there is a solo or unisono. The
4376 first part (with context called @code{one}) always gets up stems, and
4377 `solo', while the second (called @code{two}) always gets down stems and
4380 If you just want the merging parts, and not the textual markings, you
4381 may set the property @var{soloADue} to false:
4383 @lilypond[verbatim,singleline,fragment]
4385 \property Staff.soloADue = ##f
4386 \context Voice=one \partcombine Voice
4387 \context Thread=one \relative c'' {
4390 \context Thread=two \relative c'' {
4398 @internalsref{PartCombineMusic},
4399 @internalsref{Thread_devnull_engraver}, and
4400 @internalsref{Voice_devnull_engraver} and @internalsref{A2_engraver}.
4404 The syntax for naming contexts in inconsistent with the syntax for
4407 In @code{soloADue} mode, when the two voices play the same notes on and
4408 off, the part combiner may typeset @code{a2} more than once in a
4411 @lilypond[fragment,singleline]
4413 \context Voice=one \partcombine Voice
4414 \context Thread=one \relative c'' {
4417 \context Thread=two \relative c'' {
4423 The part combiner is rather buggy, and it will be replaced by a better
4424 mechanism in the near future.
4426 @cindex @code{Thread_devnull_engraver}
4427 @cindex @code{Voice_engraver}
4428 @cindex @code{A2_engraver}
4431 @subsection Hiding staves
4433 @cindex Frenched scores
4434 @cindex Hiding staves
4436 In orchestral scores, staff lines that only have rests are usually
4437 removed. This saves some space. This style is called `French Score'.
4438 For @internalsref{Lyrics}, @internalsref{LyricsVoice},
4439 @internalsref{ChordNames} and @internalsref{FiguredBass}, this is
4440 switched on by default. When these line of these contexts turn out
4441 empty after the line-breaking process, they are removed.
4443 For normal staves, a specialized @internalsref{Staff} context is
4444 available, which does the same: staves containing nothing (or only
4445 multi measure rests) are removed. The context definition is stored in
4446 @code{\RemoveEmptyStaffContext} variable. Observe how the second staff
4447 in this example disappears in the second line:
4452 \notes \relative c' <<
4453 \new Staff { e4 f g a \break c1 }
4454 \new Staff { c4 d e f \break R1 }
4458 \translator { \RemoveEmptyStaffContext }
4463 The first page shows all staffs in full. If they should be removed
4464 from the first page too, set @code{remove-first} to false
4465 in @internalsref{RemoveEmptyVerticalGroup}.
4467 @node Different editions from one source
4468 @subsection Different editions from one source
4470 The @code{\tag} command marks music expressions with a name. These
4471 tagged expressions can be filtered out later. With this mechanism it
4472 is possible to make different versions of the same music source.
4474 In the following example, we see two versions of a piece of music, one
4475 for the full score, and one with cue notes for the instrumental part:
4483 \property Voice.fontSize = #-1
4491 The same can be applied to articulations, texts, etc.: they are
4494 -\tag #@var{your-tag}
4496 to an articulation, for example,
4501 This defines a note with a conditional fingering indication.
4503 By applying the @code{remove-tag} function, tagged expressions can be
4504 filtered. For example,
4508 \apply #(remove-tag 'score) @var{the music}
4509 \apply #(remove-tag 'part) @var{the music}
4514 @lilypondfile[notexidoc]{tag-filter.ly}
4516 The argument of the @code{\tag} command should be a symbol, or a list
4517 of symbols, for example,
4519 \tag #'(original-part transposed-part) @dots{}
4524 @inputfileref{input/regression,tag-filter.ly}
4527 @node Sound output for transposing instruments
4528 @subsection Sound output for transposing instruments
4530 When you want to make a MIDI file from a score containing transposed
4531 and untransposed instruments, you have to instruct LilyPond the pitch
4532 offset (in semitones) for the transposed instruments. This is done
4533 using the @code{transposing} property. It does not affect printed
4536 @cindex @code{transposing}
4539 \property Staff.instrument = #"Cl. in B-flat"
4540 \property Staff.transposing = #-2
4544 @node Ancient notation
4545 @section Ancient notation
4547 @cindex Vaticana, Editio
4548 @cindex Medicaea, Editio
4553 @c [TODO: write more comprehensive introduction on ancient notation]
4555 Support for ancient notation is still under heavy development.
4556 Regardless of all of the current limitations (see the bugs section
4557 below for details), it includes features for mensural
4558 notation and Gregorian Chant notation. There is also limited support
4559 for figured bass notation.
4561 Many graphical objects provide a @code{style} property, see
4562 @ref{Ancient note heads}, @ref{Ancient accidentals}, @ref{Ancient
4563 rests}, @ref{Ancient clefs}, @ref{Ancient flags} and @ref{Ancient time
4564 signatures}. By manipulating such a grob property, the typographical
4565 appearance of the affected graphical objects can be accomodated for a
4566 specific notation flavour without need for introducing any new
4570 Other aspects of ancient notation can not that easily be expressed as
4571 in terms of just changing a style property of a graphical object.
4572 Therefore, some notational concepts are introduced specifically for
4573 ancient notation, see @ref{Custodes}, @ref{Divisiones},
4574 @ref{Ligatures}, and @ref{Figured bass}.
4578 * Ancient note heads::
4579 * Ancient accidentals::
4583 * Ancient time signatures::
4588 * Vaticana style contexts::
4591 If this all is way too much of documentation for you, and you just
4592 want to dive into typesetting without worrying too much about the
4593 details on how to customize a context, then you may have a look at the
4594 predefined contexts (see @ref{Vaticana style contexts}). Use them to
4595 set up predefined style-specific voice and staff contexts, and
4596 directly go ahead with the note entry.
4600 Ligatures need special spacing that has not yet been implemented. As
4601 a result, there is too much space between ligatures most of the time,
4602 and line breaking often is unsatisfactory. Also, lyrics do not
4603 correctly align with ligatures.
4605 Accidentals must not be printed within a ligature, but instead need to
4606 be collected and printed in front of it.
4608 Augmentum dots within ligatures are not handled correctly.
4611 @node Ancient note heads
4612 @subsection Ancient note heads
4618 For ancient notation, a note head style other than the @code{default}
4619 style may be chosen. This is accomplished by setting the @code{style}
4620 property of the NoteHead object to the desired value (@code{baroque},
4621 @code{neo_mensural} or @code{mensural}). The @code{baroque} style
4622 differs from the @code{default} style only in using a square shape for
4623 @code{\breve} note heads. The @code{neo_mensural} style differs from
4624 the @code{baroque} style in that it uses rhomboidal heads for whole
4625 notes and all smaller durations. Stems are centered on the note
4626 heads. This style is in particular useful when transcribing mensural
4627 music, e.g. for the incipit. The @code{mensural} style finally
4628 produces note heads that mimick the look of note heads in historic
4629 printings of the 16th century.
4631 The following example demonstrates the @code{neo_mensural} style:
4633 @lilypond[fragment,singleline,verbatim]
4634 \property Voice.NoteHead \set #'style = #'neo_mensural
4635 a'\longa a'\breve a'1 a'2 a'4 a'8 a'16
4638 When typesetting a piece in Gregorian Chant notation, a Gregorian
4639 ligature engraver will automatically select the proper note heads,
4640 such there is no need to explicitly set the note head style. Still,
4641 the note head style can be set e.g. to @code{vaticana_punctum} to
4642 produce punctum neumes. Similarly, a mensural ligature engraver is
4643 used to automatically assemble mensural ligatures. See
4644 @ref{Ligatures} for how ligature engravers work.
4648 @inputfileref{input/regression,note-head-style.ly} gives an overview
4649 over all available note head styles.
4651 @ref{Percussion staves} use note head styles of their own that are
4652 frequently used in contemporary music notation.
4654 @node Ancient accidentals
4655 @subsection Ancient accidentals
4661 Use the @code{style} property of grob @internalsref{Accidental} to
4662 select ancient accidentals. Supported styles are
4663 @code{mensural}, @code{vaticana}, @code{hufnagel} and @code{medicaea}.
4665 @lilypond[singleline,26pt]
4673 { " " \musicglyph #"accidentals-vaticana-1"
4674 " " \musicglyph #"accidentals-vaticana0" }
4678 { " " \musicglyph #"accidentals-medicaea-1" }
4682 { " " \musicglyph #"accidentals-hufnagel-1" }
4686 { " " \musicglyph #"accidentals-mensural-1"
4687 " " \musicglyph #"accidentals-mensural1" }
4696 \remove "Bar_number_engraver"
4700 \remove "Clef_engraver"
4701 \remove "Key_engraver"
4702 \remove "Time_signature_engraver"
4703 \remove "Staff_symbol_engraver"
4704 minimumVerticalExtent = ##f
4710 As shown, not all accidentals are supported by each style. When
4711 trying to access an unsupported accidental, LilyPond will switch to a
4712 different style, as demonstrated in
4713 @inputfileref{input/test,ancient-accidentals.ly}.
4715 Similarly to local accidentals, the style of the key signature can be
4716 controlled by the @code{style} property of the
4717 @internalsref{KeySignature} grob.
4721 @ref{Pitches}, @ref{Chromatic alterations} and @ref{Accidentals} give
4722 a general introduction into the use of accidentals. @ref{Key
4723 signature} gives a general introduction into the use of key
4728 @subsection Ancient rests
4734 Use the @code{style} property of grob @internalsref{Rest} to select
4735 ancient accidentals. Supported styles are @code{classical},
4736 @code{neo_mensural} and @code{mensural}. @code{classical} differs
4737 from the @code{default} style only in that the quarter rest looks like
4738 a horizontally mirrored 8th rest. The @code{neo_mensural} style suits
4739 well for e.g. the incipit of a transcribed mensural piece of music.
4740 The @code{mensural} style finally mimicks the appearance of rests as
4741 in historic prints of the 16th century.
4743 The following example demonstrates the @code{neo_mensural} style:
4745 @lilypond[fragment,singleline,verbatim]
4746 \property Voice.Rest \set #'style = #'neo_mensural
4747 r\longa r\breve r1 r2 r4 r8 r16
4750 There are no 32th and 64th rests specifically for the mensural or
4751 neo-mensural style. Instead, the rests from the default style will be
4752 taken. See @inputfileref{input/test,rests.ly} for a chart of all
4755 There are no rests in Gregorian Chant notation; instead, it uses
4760 @ref{Rests} gives a general introduction into the use of rests.
4764 @subsection Ancient clefs
4770 LilyPond supports a variety of clefs, many of them ancient.
4772 The following table shows all ancient clefs that are supported via the
4773 @code{\clef} command. Some of the clefs use the same glyph, but
4774 differ only with respect to the line they are printed on. In such
4775 cases, a trailing number in the name is used to enumerate these clefs.
4776 Still, you can manually force a clef glyph to be typeset on an
4777 arbitrary line, as described in @ref{Clef}. The note printed to the
4778 right side of each clef in the example column denotes the @code{c'}
4779 with respect to that clef.
4781 @multitable @columnfractions .3 .3 .3 .1
4785 @b{Description} @tab
4786 @b{Supported Clefs} @tab
4790 @code{clefs-neo_mensural_c} @tab
4791 modern style mensural C clef @tab
4792 @code{neo_mensural_c1}, @code{neo_mensural_c2},
4793 @code{neo_mensural_c3}, @code{neo_mensural_c4} @tab
4794 @lilypond[relative 0, notime]
4795 \property Staff.TimeSignature \set #'transparent = ##t
4796 \clef "neo_mensural_c2" c
4800 @code{clefs-petrucci_c1}
4801 @code{clefs-petrucci_c2}
4802 @code{clefs-petrucci_c3}
4803 @code{clefs-petrucci_c4}
4804 @code{clefs-petrucci_c5}
4807 petrucci style mensural C clefs, for use on different stafflines
4808 (the examples shows the 2nd staffline C clef).
4818 @lilypond[relative 0, notime]
4819 \property Staff.TimeSignature \set #'transparent = ##t
4820 \clef "petrucci_c2" c
4824 @code{clefs-petrucci_f} @tab
4825 petrucci style mensural F clef @tab
4826 @code{petrucci_f} @tab
4827 @lilypond[relative 0, notime]
4828 \property Staff.TimeSignature \set #'transparent = ##t
4829 \clef "petrucci_f" c
4833 @code{clefs-petrucci_g} @tab
4834 petrucci style mensural G clef @tab
4835 @code{petrucci_g} @tab
4836 @lilypond[relative 0, notime]
4837 \property Staff.TimeSignature \set #'transparent = ##t
4838 \clef "petrucci_g" c
4842 @code{clefs-mensural_c} @tab
4843 historic style mensural C clef @tab
4844 @code{mensural_c1}, @code{mensural_c2}, @code{mensural_c3},
4845 @code{mensural_c4} @tab
4846 @lilypond[relative 0, notime]
4847 \property Staff.TimeSignature \set #'transparent = ##t
4848 \clef "mensural_c2" c
4852 @code{clefs-mensural_f} @tab
4853 historic style mensural F clef @tab
4854 @code{mensural_f} @tab
4855 @lilypond[relative 0, notime]
4856 \property Staff.TimeSignature \set #'transparent = ##t
4857 \clef "mensural_f" c
4861 @code{clefs-mensural_g} @tab
4862 historic style mensural G clef @tab
4863 @code{mensural_g} @tab
4864 @lilypond[relative 0, notime]
4865 \property Staff.TimeSignature \set #'transparent = ##t
4866 \clef "mensural_g" c
4870 @code{clefs-vaticana_do} @tab
4871 Editio Vaticana style do clef @tab
4872 @code{vaticana_do1}, @code{vaticana_do2}, @code{vaticana_do3} @tab
4873 @lilypond[relative 0, notime]
4875 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4876 \property Staff.TimeSignature \set #'transparent = ##t
4877 \clef "vaticana_do2" c
4881 @code{clefs-vaticana_fa} @tab
4882 Editio Vaticana style fa clef @tab
4883 @code{vaticana_fa1}, @code{vaticana_fa2} @tab
4884 @lilypond[relative 0, notime]
4886 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4887 \property Staff.TimeSignature \set #'transparent = ##t
4888 \clef "vaticana_fa2" c
4892 @code{clefs-medicaea_do} @tab
4893 Editio Medicaea style do clef @tab
4894 @code{medicaea_do1}, @code{medicaea_do2}, @code{medicaea_do3} @tab
4895 @lilypond[relative 0, notime]
4897 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4898 \property Staff.TimeSignature \set #'transparent = ##t
4899 \clef "medicaea_do2" c
4903 @code{clefs-medicaea_fa} @tab
4904 Editio Medicaea style fa clef @tab
4905 @code{medicaea_fa1}, @code{medicaea_fa2} @tab
4906 @lilypond[relative 0, notime]
4908 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4909 \property Staff.TimeSignature \set #'transparent = ##t
4910 \clef "medicaea_fa2" c
4914 @code{clefs-hufnagel_do} @tab
4915 historic style hufnagel do clef @tab
4916 @code{hufnagel_do1}, @code{hufnagel_do2}, @code{hufnagel_do3} @tab
4917 @lilypond[relative 0, notime]
4919 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4920 \property Staff.TimeSignature \set #'transparent = ##t
4921 \clef "hufnagel_do2" c
4925 @code{clefs-hufnagel_fa} @tab
4926 historic style hufnagel fa clef @tab
4927 @code{hufnagel_fa1}, @code{hufnagel_fa2} @tab
4928 @lilypond[relative 0, notime]
4930 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4931 \property Staff.TimeSignature \set #'transparent = ##t
4932 \clef "hufnagel_fa2" c
4936 @code{clefs-hufnagel_do_fa} @tab
4937 historic style hufnagel combined do/fa clef @tab
4938 @code{hufnagel_do_fa} @tab
4939 @lilypond[relative 0, notime]
4940 \property Staff.TimeSignature \set #'transparent = ##t
4941 \clef "hufnagel_do_fa" c
4946 @c --- This should go somewhere else: ---
4947 @c @item modern style percussion clef (glyph: @code{clefs-percussion})
4950 @c @code{percussion}
4952 @c @lilypond{\property Staff.TimeSignature \set #'transparent = ##t \clef "percussion" c'}
4954 @c @item modern style tab clef (glyph: @code{clefs-tab})
4959 @c @lilypond{\context Staff \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #6 \property Staff.TimeSignature \set #'transparent = ##t \clef "tab" c'}
4961 @emph{Modern style} means ``as is typeset in contemporary editions of
4962 transcribed mensural music''.
4964 @emph{Petrucci style} means ``inspired by printings published by the
4965 famous engraver Petrucci (1466-1539)''.
4967 @emph{Historic style} means ``as was typeset or written in historic
4968 editions (other than those of Petrucci)''.
4970 @emph{Editio XXX style} means ``as is/was printed in Editio XXX''.
4972 Petrucci used C clefs with differently balanced left-side vertical
4973 beams, depending on which staffline it is printed.
4977 For modern clefs, see @ref{Clef}. For the percussion clef, see
4978 @ref{Percussion staves}. For the @code{TAB} clef, see
4983 @subsection Ancient flags
4989 Use the @code{flag-style} property of grob @internalsref{Stem} to
4990 select ancient flags. Besides the @code{default} flag style,
4991 only @code{mensural} style is supported:
4993 @lilypond[fragment,singleline,verbatim]
4994 \property Voice.Stem \set #'flag-style = #'mensural
4995 \property Voice.Stem \set #'thickness = #1.0
4996 \property Voice.NoteHead \set #'style = #'mensural
4998 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
4999 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5002 Note that the innermost flare of each mensural flag always is
5003 vertically aligned with a staff line. If you do not like this
5004 behaviour, you can set the @code{adjust-if-on-staffline} property of
5005 grob @internalsref{Stem} to @code{##f}. Then, the vertical position
5006 of the end of each flare is different between notes on staff lines and
5007 notes between staff lines:
5009 @lilypond[fragment,singleline]
5010 \property Voice.Stem \set #'flag-style = #'mensural
5011 \property Voice.Stem \set #'thickness = #1.0
5012 \property Voice.Stem \set #'adjust-if-on-staffline = ##f
5013 \property Voice.NoteHead \set #'style = #'mensural
5015 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
5016 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5019 There is no particular flag style for neo-mensural notation. Hence,
5020 when typesetting e.g. the incipit of a transcibed piece of mensural
5021 music, the default flag style should be used. There are no flags in
5022 Gregorian Chant notation.
5025 @node Ancient time signatures
5026 @subsection Ancient time signatures
5028 @cindex time signatures
5032 There is limited support for mensural time signatures. The
5033 glyphs are hard-wired to particular time fractions. In other words,
5034 to get a particular mensural signature glyph with the @code{\time n/m}
5035 command, @code{n} and @code{m} have to be chosen according to the
5041 \property Score.timing = ##f
5042 \property Score.barAlways = ##t
5043 s_\markup { "$\\backslash$time 4/4" }
5044 ^\markup { " " \musicglyph #"timesig-neo\_mensural4/4" }
5046 s_\markup { "$\\backslash$time 2/2" }
5047 ^\markup { " " \musicglyph #"timesig-neo\_mensural2/2" }
5049 s_\markup { "$\\backslash$time 6/4" }
5050 ^\markup { " " \musicglyph #"timesig-neo\_mensural6/4" }
5052 s_\markup { "$\\backslash$time 6/8" }
5053 ^\markup { " " \musicglyph #"timesig-neo\_mensural6/8" }
5055 s_\markup { "$\\backslash$time 3/2" }
5056 ^\markup { " " \musicglyph #"timesig-neo\_mensural3/2" }
5058 s_\markup { "$\\backslash$time 3/4" }
5059 ^\markup { " " \musicglyph #"timesig-neo\_mensural3/4" }
5061 s_\markup { "$\\backslash$time 9/4" }
5062 ^\markup { " " \musicglyph #"timesig-neo\_mensural9/4" }
5064 s_\markup { "$\\backslash$time 9/8" }
5065 ^\markup { " " \musicglyph #"timesig-neo\_mensural9/8" }
5067 s_\markup { "$\\backslash$time 4/8" }
5068 ^\markup { " " \musicglyph #"timesig-neo\_mensural4/8" }
5070 s_\markup { "$\\backslash$time 2/4" }
5071 ^\markup { " " \musicglyph #"timesig-neo\_mensural2/4" }
5079 \remove Staff_symbol_engraver
5080 \remove Clef_engraver
5081 \remove Time_signature_engraver
5087 Use the @code{style} property of grob @internalsref{TimeSignature} to
5088 select ancient time signatures. Supported styles are
5089 @code{neo_mensural} and @code{mensural}. The above table uses the
5090 @code{neo_mensural} style. This style is appropriate e.g. for the
5091 incipit of transcriptions of mensural pieces. The @code{mensural}
5092 style mimicks the look of historical printings of the 16th century.
5094 @inputfileref{input/test,time.ly} gives an overview over all available
5095 ancient and modern styles.
5099 @ref{Time signature} gives a general introduction into the use of time
5104 Mensural signature glyphs are mapped to time fractions in a
5105 hard-wired way. This mapping is sensible, but still arbitrary: given
5106 a mensural time signature, the time fraction represents a modern meter
5107 that usually will be a good choice when transcribing a mensural piece
5108 of music. For a particular piece of mensural music, however, the
5109 mapping may be unsatisfactory. In particular, the mapping assumes a
5110 fixed transcription of durations (e.g. brevis = half note in 2/2,
5111 i.e. 4:1). Some glyphs (such as the alternate glyph for 6/8 meter)
5112 are not at all accessible through the @code{\time} command.
5114 Mensural time signatures are supported typographically, but not yet
5115 musically. The internal representation of durations is
5116 based on a purely binary system; a ternary division such as 1 brevis =
5117 3 semibrevis (tempus perfectum) or 1 semibrevis = 3 minima (cum
5118 prolatione maiori) is not correctly handled: event times in ternary
5119 modes will be badly computed, resulting e.g. in horizontally
5120 misaligned note heads, and bar checks are likely to erroneously fail.
5122 The syntax and semantics of the @code{\time} command for mensural
5123 music is subject to change.
5126 @subsection Custodes
5131 A @emph{custos} (plural: @emph{custodes}; latin word for `guard') is a
5132 symbol that appears at the end of a staff. It anticipates the pitch
5133 of the first note(s) of the following line and thus helps the player
5134 or singer to manage line breaks during performance, thus enhancing
5135 readability of a score.
5137 Custodes were frequently used in music notation until the 17th
5138 century. Nowadays, they have survived only in a few particular forms
5139 of musical notation such as contemporary editions of Gregorian chant
5140 like the @emph{editio vaticana}. There are different custos glyphs
5141 used in different flavours of notational style.
5145 For typesetting custodes, just put a @internalsref{Custos_engraver} into the
5146 @internalsref{Staff} context when declaring the @code{\paper} block,
5147 as shown in the following example:
5153 \consists Custos_engraver
5154 Custos \override #'style = #'mensural
5159 The result looks like this:
5165 \property Staff.Custos \set #'style = #'mensural
5172 \consists Custos_engraver
5179 The custos glyph is selected by the @code{style} property. The styles
5180 supported are @code{vaticana}, @code{medicaea}, @code{hufnagel} and
5181 @code{mensural}. They are demonstrated in the following fragment:
5191 { " " \musicglyph #"custodes-vaticana-u0" }
5195 { " " \musicglyph #"custodes-medicaea-u0" }
5199 { " " \musicglyph #"custodes-hufnagel-u0" }
5203 { " " \musicglyph #"custodes-mensural-u0" }
5212 \remove "Bar_number_engraver"
5216 \remove "Clef_engraver"
5217 \remove "Key_engraver"
5218 \remove "Time_signature_engraver"
5219 \remove "Staff_symbol_engraver"
5220 minimumVerticalExtent = ##f
5226 If the boolean property @code{adjust-if-on-staffline} is set to
5227 @code{#t} (which it is by default), lily typesets slightly different
5228 variants of the custos glyph, depending on whether the custos, is
5229 typeset on or between stafflines. The glyph will
5230 optically fit well into the staff, with the appendage on the right of
5231 the custos always ending at the same vertical position between two
5232 stafflines regardless of the pitch. If you set
5233 @code{adjust-if-on-staffline} to @code{#f}, then
5234 a compromise between both forms is used.
5236 Just like stems can be attached to noteheads in two directions
5237 @emph{up} and @emph{down}, each custos glyph is available with its
5238 appendage pointing either up or down. If the pitch of a custos is
5239 above a selectable position, the appendage will point downwards; if
5240 the pitch is below this position, the appendage will point upwards.
5241 Use property @code{neutral-position} to select this position. By
5242 default, it is set to @code{0}, such that the neutral position is the
5243 center of the staff. Use property @code{neutral-direction} to control
5244 what happens if a custos is typeset on the neutral position itself.
5245 By default, this property is set to @code{-1}, such that the appendage
5246 will point downwards. If set to @code{1}, the appendage will point
5247 upwards. Other values such as @code{0} are reserved for future
5248 extensions and should not be used.
5252 @internalsref{Custos} and @inputfileref{input/regression,custos.ly}.
5256 @subsection Divisiones
5262 A @emph{divisio} (plural: @emph{divisiones}; latin word for
5263 `division') is a staff context symbol that is used to structure
5264 Gregorian music into phrases and sections. The musical meaning of
5265 @emph{divisio minima}, @emph{divisio maior} and @emph{divisio maxima}
5266 can be characterized as short, medium and long pause, somewhat like
5267 @ref{Breath marks}. The @emph{finalis} sign not only marks the end of
5268 a chant, but is also frequently used within a single
5269 antiphonal/responsorial chant to mark the end of each section.
5273 To use divisiones, include the file @code{gregorian-init.ly}. It
5274 contains definitions that you can apply by just inserting
5275 @code{\divisioMinima}, @code{\divisioMaior}, @code{\divisioMaxima},
5276 and @code{\finalis} at proper places in the input. Some editions use
5277 @emph{virgula} or @emph{caesura} instead of divisio minima.
5278 Therefore, @code{gregorian-init.ly} also defines @code{\virgula} and
5281 @lilypondfile[notexidoc]{divisiones.ly}
5285 @cindex @code{\virgula}
5287 @cindex @code{\caesura}
5289 @cindex @code{\divisioMinima}
5290 @code{\divisioMinima},
5291 @cindex @code{\divisioMaior}
5292 @code{\divisioMaior},
5293 @cindex @code{\divisioMaxima}
5294 @code{\divisioMaxima},
5295 @cindex @code{\finalis}
5300 @internalsref{BreathingSign}, @internalsref{BreathingSignEvent},
5301 @inputfileref{input/test,divisiones.ly}, and @ref{Breath marks}.
5304 @subsection Ligatures
5308 @c TODO: Should double check if I recalled things correctly when I wrote
5309 @c down the following paragraph by heart.
5311 In musical terminology, a ligature is a coherent graphical symbol that
5312 represents at least two distinct notes. Ligatures originally appeared
5313 in the manuscripts of Gregorian chant notation roughly since the 9th
5314 century as an allusion to the accent symbols of greek lyric poetry to
5315 denote ascending or descending sequences of notes. Both, the shape
5316 and the exact meaning of ligatures changed tremendously during the
5317 following centuries: In early notation, ligatures were used for
5318 monophonic tunes (Gregorian chant) and very soon denoted also the way
5319 of performance in the sense of articulation. With upcoming
5320 multiphony, the need for a metric system arised, since multiple voices
5321 of a piece have to be synchronized some way. New notation systems
5322 were invented that used the manifold shapes of ligatures to now denote
5323 rhythmical patterns (e.g. black mensural notation, mannered notation,
5324 ars nova). With the invention of the metric system of the white
5325 mensural notation, the need for ligatures to denote such patterns
5326 disappeared. Nevertheless, ligatures were still in use in the
5327 mensural system for a couple of decades until they finally disappeared
5328 during the late 16th / early 17th century. Still, ligatures have
5329 survived in contemporary editions of Gregorian chant such as the
5330 Editio Vaticana from 1905/08.
5334 Syntactically, ligatures are simply enclosed by @code{\[} and
5335 @code{\]}. Some ligature styles (such as Editio Vaticana) may need
5336 additional input syntax specific for this particular type of ligature.
5337 By default, the @internalsref{LigatureBracket} engraver just puts a
5338 square bracket above the ligature:
5340 @lilypond[singleline,verbatim]
5342 \notes \transpose c c' {
5350 To select a specific style of ligatures, a proper ligature engraver
5351 has to be added to the @internalsref{Voice} context, as explained in
5352 the following subsections. Only white mensural ligatures
5353 are supported with certain limitations. Support for Editio Vaticana
5354 will be added in the future.
5357 * White mensural ligatures::
5358 * Gregorian square neumes ligatures::
5361 @node White mensural ligatures
5362 @subsubsection White mensural ligatures
5364 @cindex Mensural ligatures
5365 @cindex White mensural ligatures
5367 There is limited support for white mensural ligatures. The
5368 implementation is still experimental; it may output strange
5369 warnings or even crash in some cases or produce weird results on more
5374 To engrave white mensural ligatures, in the paper block the
5375 @internalsref{Mensural_ligature_engraver} has to be put into the
5376 @internalsref{Voice} context, and remove the
5377 @internalsref{Ligature_bracket_engraver}:
5383 \remove Ligature_bracket_engraver
5384 \consists Mensural_ligature_engraver
5389 There is no additional input language to describe the shape of a
5390 white mensural ligature. The shape is rather determined solely from
5391 the pitch and duration of the enclosed notes. While this approach may
5392 take a new user a while to get accustomed, it has the great advantage
5393 that the full musical information of the ligature is known internally.
5394 This is not only required for correct MIDI output, but also allows for
5395 automatic transcription of the ligatures.
5400 \property Score.timing = ##f
5401 \property Score.defaultBarType = "empty"
5402 \property Voice.NoteHead \set #'style = #'neo_mensural
5403 \property Staff.TimeSignature \set #'style = #'neo_mensural
5405 \[ g\longa c\breve a\breve f\breve d'\longa \]
5407 \[ e1 f1 a\breve g\longa \]
5409 @lilypond[singleline]
5411 \notes \transpose c c' {
5412 \property Score.timing = ##f
5413 \property Score.defaultBarType = "empty"
5414 \property Voice.NoteHead \set #'style = #'neo_mensural
5415 \property Staff.TimeSignature \set #'style = #'neo_mensural
5417 \[ g\longa c\breve a\breve f\breve d'\longa \]
5419 \[ e1 f1 a\breve g\longa \]
5424 \remove Ligature_bracket_engraver
5425 \consists Mensural_ligature_engraver
5431 Without replacing @internalsref{Ligature_bracket_engraver} with
5432 @internalsref{Mensural_ligature_engraver}, the same music transcribes
5435 @lilypond[singleline]
5437 \notes \transpose c c' {
5438 \property Score.timing = ##f
5439 \property Score.defaultBarType = "empty"
5440 \property Voice.NoteHead \set #'style = #'neo_mensural
5441 \property Staff.TimeSignature \set #'style = #'neo_mensural
5443 \[ g\longa c\breve a\breve f\breve d'\longa \]
5445 \[ e1 f1 a\breve g\longa \]
5451 @node Gregorian square neumes ligatures
5452 @subsubsection Gregorian square neumes ligatures
5454 @cindex Square neumes ligatures
5455 @cindex Gregorian square neumes ligatures
5457 Gregorian square neumes notation (following the style of the Editio
5458 Vaticana) is under heavy development, but not yet really usable for
5459 production purposes. Core ligatures can already be typeset, but
5460 essential issues for serious typesetting are still under development,
5461 such as (among others) horizontal alignment of multiple ligatures,
5462 lyrics alignment and proper accidentals handling. Still, this section
5463 gives a sneak preview of what Gregorian chant may look like once it
5466 The following table contains the extended neumes table of the 2nd
5467 volume of the Antiphonale Romanum (@emph{Liber Hymnarius}), published
5468 1983 by the monks of Solesmes.
5470 @multitable @columnfractions .4 .2 .2 .2
5473 @b{Neuma aut@*Neumarum Elementa} @tab
5474 @b{Figurae@*Rectae} @tab
5475 @b{Figurae@*Liquescentes Auctae} @tab
5476 @b{Figurae@*Liquescentes Deminutae}
5478 @c TODO: \paper block is identical in all of the below examples.
5479 @c Therefore, it should somehow be included rather than duplicated all
5482 @c why not make identifiers in ly/engraver-init.ly? --hwn
5484 @c Because it's just used to typeset plain notes without
5485 @c a staff for demonstration purposes rather than something
5486 @c special of Gregorian chant notation. --jr
5491 @lilypond[noindent, 26pt, nofragment, linewidth=1.5cm]
5492 \include "gregorian-init.ly"
5494 \notes \transpose c c' {
5497 \noBreak s^\markup {"a"} \noBreak
5499 % Punctum Inclinatum
5501 \noBreak s^\markup {"b"}
5507 \remove "Bar_number_engraver"
5511 \remove "Clef_engraver"
5512 \remove "Key_engraver"
5513 StaffSymbol \set #'transparent = ##t
5514 \remove "Time_signature_engraver"
5515 \remove "Bar_engraver"
5516 minimumVerticalExtent = ##f
5520 \remove Ligature_bracket_engraver
5521 \consists Vaticana_ligature_engraver
5522 NoteHead \set #'style = #'vaticana_punctum
5523 Stem \set #'transparent = ##t
5529 @lilypond[noindent, 26pt, nofragment, linewidth=2.5cm]
5530 \include "gregorian-init.ly"
5532 \notes \transpose c c' {
5533 % Punctum Auctum Ascendens
5534 \[ \auctum \ascendens b \]
5535 \noBreak s^\markup {"c"} \noBreak
5537 % Punctum Auctum Descendens
5538 \[ \auctum \descendens b \]
5539 \noBreak s^\markup {"d"} \noBreak
5541 % Punctum Inclinatum Auctum
5542 \[ \inclinatum \auctum b \]
5543 \noBreak s^\markup {"e"}
5549 \remove "Bar_number_engraver"
5553 \remove "Clef_engraver"
5554 \remove "Key_engraver"
5555 StaffSymbol \set #'transparent = ##t
5556 \remove "Time_signature_engraver"
5557 \remove "Bar_engraver"
5558 minimumVerticalExtent = ##f
5562 \remove Ligature_bracket_engraver
5563 \consists Vaticana_ligature_engraver
5564 NoteHead \set #'style = #'vaticana_punctum
5565 Stem \set #'transparent = ##t
5571 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5572 \include "gregorian-init.ly"
5574 \notes \transpose c c' {
5575 % Punctum Inclinatum Parvum
5576 \[ \inclinatum \deminutum b \]
5577 \noBreak s^\markup {"f"}
5583 \remove "Bar_number_engraver"
5587 \remove "Clef_engraver"
5588 \remove "Key_engraver"
5589 StaffSymbol \set #'transparent = ##t
5590 \remove "Time_signature_engraver"
5591 \remove "Bar_engraver"
5592 minimumVerticalExtent = ##f
5596 \remove Ligature_bracket_engraver
5597 \consists Vaticana_ligature_engraver
5598 NoteHead \set #'style = #'vaticana_punctum
5599 Stem \set #'transparent = ##t
5608 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5609 \include "gregorian-init.ly"
5611 \notes \transpose c c' {
5614 \noBreak s^\markup {"g"}
5620 \remove "Bar_number_engraver"
5624 \remove "Clef_engraver"
5625 \remove "Key_engraver"
5626 StaffSymbol \set #'transparent = ##t
5627 \remove "Time_signature_engraver"
5628 \remove "Bar_engraver"
5629 minimumVerticalExtent = ##f
5633 \remove Ligature_bracket_engraver
5634 \consists Vaticana_ligature_engraver
5635 NoteHead \set #'style = #'vaticana_punctum
5636 Stem \set #'transparent = ##t
5645 @code{3. Apostropha vel Stropha}
5647 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5648 \include "gregorian-init.ly"
5650 \notes \transpose c c' {
5653 \noBreak s^\markup {"h"}
5659 \remove "Bar_number_engraver"
5663 \remove "Clef_engraver"
5664 \remove "Key_engraver"
5665 StaffSymbol \set #'transparent = ##t
5666 \remove "Time_signature_engraver"
5667 \remove "Bar_engraver"
5668 minimumVerticalExtent = ##f
5672 \remove Ligature_bracket_engraver
5673 \consists Vaticana_ligature_engraver
5674 NoteHead \set #'style = #'vaticana_punctum
5675 Stem \set #'transparent = ##t
5681 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5682 \include "gregorian-init.ly"
5684 \notes \transpose c c' {
5686 \[ \stropha \auctum b \]
5687 \noBreak s^\markup {"i"}
5693 \remove "Bar_number_engraver"
5697 \remove "Clef_engraver"
5698 \remove "Key_engraver"
5699 StaffSymbol \set #'transparent = ##t
5700 \remove "Time_signature_engraver"
5701 \remove "Bar_engraver"
5702 minimumVerticalExtent = ##f
5706 \remove Ligature_bracket_engraver
5707 \consists Vaticana_ligature_engraver
5708 NoteHead \set #'style = #'vaticana_punctum
5709 Stem \set #'transparent = ##t
5719 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5720 \include "gregorian-init.ly"
5722 \notes \transpose c c' {
5725 \noBreak s^\markup {"j"}
5731 \remove "Bar_number_engraver"
5735 \remove "Clef_engraver"
5736 \remove "Key_engraver"
5737 StaffSymbol \set #'transparent = ##t
5738 \remove "Time_signature_engraver"
5739 \remove "Bar_engraver"
5740 minimumVerticalExtent = ##f
5744 \remove Ligature_bracket_engraver
5745 \consists Vaticana_ligature_engraver
5746 NoteHead \set #'style = #'vaticana_punctum
5747 Stem \set #'transparent = ##t
5756 @code{5. Clivis vel Flexa}
5758 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5759 \include "gregorian-init.ly"
5761 \notes \transpose c c' {
5770 \remove "Bar_number_engraver"
5774 \remove "Clef_engraver"
5775 \remove "Key_engraver"
5776 StaffSymbol \set #'transparent = ##t
5777 \remove "Time_signature_engraver"
5778 \remove "Bar_engraver"
5779 minimumVerticalExtent = ##f
5783 \remove Ligature_bracket_engraver
5784 \consists Vaticana_ligature_engraver
5785 NoteHead \set #'style = #'vaticana_punctum
5786 Stem \set #'transparent = ##t
5792 @lilypond[noindent, 26pt, nofragment, linewidth=2.0cm]
5793 \include "gregorian-init.ly"
5795 \notes \transpose c c' {
5796 % Clivis Aucta Descendens
5797 \[ b \flexa \auctum \descendens g \]
5798 \noBreak s^\markup {"l"} \noBreak
5800 % Clivis Aucta Ascendens
5801 \[ b \flexa \auctum \ascendens g \]
5802 \noBreak s^\markup {"m"}
5808 \remove "Bar_number_engraver"
5812 \remove "Clef_engraver"
5813 \remove "Key_engraver"
5814 StaffSymbol \set #'transparent = ##t
5815 \remove "Time_signature_engraver"
5816 \remove "Bar_engraver"
5817 minimumVerticalExtent = ##f
5821 \remove Ligature_bracket_engraver
5822 \consists Vaticana_ligature_engraver
5823 NoteHead \set #'style = #'vaticana_punctum
5824 Stem \set #'transparent = ##t
5830 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5831 \include "gregorian-init.ly"
5833 \notes \transpose c c' {
5835 \[ b \flexa \deminutum g \]
5842 \remove "Bar_number_engraver"
5846 \remove "Clef_engraver"
5847 \remove "Key_engraver"
5848 StaffSymbol \set #'transparent = ##t
5849 \remove "Time_signature_engraver"
5850 \remove "Bar_engraver"
5851 minimumVerticalExtent = ##f
5855 \remove Ligature_bracket_engraver
5856 \consists Vaticana_ligature_engraver
5857 NoteHead \set #'style = #'vaticana_punctum
5858 Stem \set #'transparent = ##t
5865 @code{6. Podatus vel Pes}
5867 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5868 \include "gregorian-init.ly"
5870 \notes \transpose c c' {
5879 \remove "Bar_number_engraver"
5883 \remove "Clef_engraver"
5884 \remove "Key_engraver"
5885 StaffSymbol \set #'transparent = ##t
5886 \remove "Time_signature_engraver"
5887 \remove "Bar_engraver"
5888 minimumVerticalExtent = ##f
5892 \remove Ligature_bracket_engraver
5893 \consists Vaticana_ligature_engraver
5894 NoteHead \set #'style = #'vaticana_punctum
5895 Stem \set #'transparent = ##t
5901 @lilypond[noindent, 26pt, nofragment, linewidth=2.0cm]
5902 \include "gregorian-init.ly"
5904 \notes \transpose c c' {
5905 % Pes Auctus Descendens
5906 \[ g \pes \auctum \descendens b \]
5907 \noBreak s^\markup {"p"} \noBreak
5909 % Pes Auctus Ascendens
5910 \[ g \pes \auctum \ascendens b \]
5911 \noBreak s^\markup {"q"}
5917 \remove "Bar_number_engraver"
5921 \remove "Clef_engraver"
5922 \remove "Key_engraver"
5923 StaffSymbol \set #'transparent = ##t
5924 \remove "Time_signature_engraver"
5925 \remove "Bar_engraver"
5926 minimumVerticalExtent = ##f
5930 \remove Ligature_bracket_engraver
5931 \consists Vaticana_ligature_engraver
5932 NoteHead \set #'style = #'vaticana_punctum
5933 Stem \set #'transparent = ##t
5939 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5940 \include "gregorian-init.ly"
5942 \notes \transpose c c' {
5944 \[ g \pes \deminutum b \]
5951 \remove "Bar_number_engraver"
5955 \remove "Clef_engraver"
5956 \remove "Key_engraver"
5957 StaffSymbol \set #'transparent = ##t
5958 \remove "Time_signature_engraver"
5959 \remove "Bar_engraver"
5960 minimumVerticalExtent = ##f
5964 \remove Ligature_bracket_engraver
5965 \consists Vaticana_ligature_engraver
5966 NoteHead \set #'style = #'vaticana_punctum
5967 Stem \set #'transparent = ##t
5974 @code{7. Pes Quassus}
5976 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5977 \include "gregorian-init.ly"
5979 \notes \transpose c c' {
5981 \[ \oriscus g \pes \virga b \]
5988 \remove "Bar_number_engraver"
5992 \remove "Clef_engraver"
5993 \remove "Key_engraver"
5994 StaffSymbol \set #'transparent = ##t
5995 \remove "Time_signature_engraver"
5996 \remove "Bar_engraver"
5997 minimumVerticalExtent = ##f
6001 \remove Ligature_bracket_engraver
6002 \consists Vaticana_ligature_engraver
6003 NoteHead \set #'style = #'vaticana_punctum
6004 Stem \set #'transparent = ##t
6010 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6011 \include "gregorian-init.ly"
6013 \notes \transpose c c' {
6014 % Pes Quassus Auctus Descendens
6015 \[ \oriscus g \pes \auctum \descendens b \]
6022 \remove "Bar_number_engraver"
6026 \remove "Clef_engraver"
6027 \remove "Key_engraver"
6028 StaffSymbol \set #'transparent = ##t
6029 \remove "Time_signature_engraver"
6030 \remove "Bar_engraver"
6031 minimumVerticalExtent = ##f
6035 \remove Ligature_bracket_engraver
6036 \consists Vaticana_ligature_engraver
6037 NoteHead \set #'style = #'vaticana_punctum
6038 Stem \set #'transparent = ##t
6046 @code{8. Quilisma Pes}
6048 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6049 \include "gregorian-init.ly"
6051 \notes \transpose c c' {
6053 \[ \quilisma g \pes b \]
6060 \remove "Bar_number_engraver"
6064 \remove "Clef_engraver"
6065 \remove "Key_engraver"
6066 StaffSymbol \set #'transparent = ##t
6067 \remove "Time_signature_engraver"
6068 \remove "Bar_engraver"
6069 minimumVerticalExtent = ##f
6073 \remove Ligature_bracket_engraver
6074 \consists Vaticana_ligature_engraver
6075 NoteHead \set #'style = #'vaticana_punctum
6076 Stem \set #'transparent = ##t
6082 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6083 \include "gregorian-init.ly"
6085 \notes \transpose c c' {
6086 % Quilisma Pes Auctus Descendens
6087 \[ \quilisma g \pes \auctum \descendens b \]
6094 \remove "Bar_number_engraver"
6098 \remove "Clef_engraver"
6099 \remove "Key_engraver"
6100 StaffSymbol \set #'transparent = ##t
6101 \remove "Time_signature_engraver"
6102 \remove "Bar_engraver"
6103 minimumVerticalExtent = ##f
6107 \remove Ligature_bracket_engraver
6108 \consists Vaticana_ligature_engraver
6109 NoteHead \set #'style = #'vaticana_punctum
6110 Stem \set #'transparent = ##t
6118 @code{9. Podatus Initio Debilis}
6120 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6121 \include "gregorian-init.ly"
6123 \notes \transpose c c' {
6124 % Pes Initio Debilis
6125 \[ \deminutum g \pes b \]
6132 \remove "Bar_number_engraver"
6136 \remove "Clef_engraver"
6137 \remove "Key_engraver"
6138 StaffSymbol \set #'transparent = ##t
6139 \remove "Time_signature_engraver"
6140 \remove "Bar_engraver"
6141 minimumVerticalExtent = ##f
6145 \remove Ligature_bracket_engraver
6146 \consists Vaticana_ligature_engraver
6147 NoteHead \set #'style = #'vaticana_punctum
6148 Stem \set #'transparent = ##t
6154 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6155 \include "gregorian-init.ly"
6157 \notes \transpose c c' {
6158 % Pes Auctus Descendens Initio Debilis
6159 \[ \deminutum g \pes \auctum \descendens b \]
6166 \remove "Bar_number_engraver"
6170 \remove "Clef_engraver"
6171 \remove "Key_engraver"
6172 StaffSymbol \set #'transparent = ##t
6173 \remove "Time_signature_engraver"
6174 \remove "Bar_engraver"
6175 minimumVerticalExtent = ##f
6179 \remove Ligature_bracket_engraver
6180 \consists Vaticana_ligature_engraver
6181 NoteHead \set #'style = #'vaticana_punctum
6182 Stem \set #'transparent = ##t
6192 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6193 \include "gregorian-init.ly"
6195 \notes \transpose c c' {
6197 \[ a \pes b \flexa g \]
6204 \remove "Bar_number_engraver"
6208 \remove "Clef_engraver"
6209 \remove "Key_engraver"
6210 StaffSymbol \set #'transparent = ##t
6211 \remove "Time_signature_engraver"
6212 \remove "Bar_engraver"
6213 minimumVerticalExtent = ##f
6217 \remove Ligature_bracket_engraver
6218 \consists Vaticana_ligature_engraver
6219 NoteHead \set #'style = #'vaticana_punctum
6220 Stem \set #'transparent = ##t
6226 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6227 \include "gregorian-init.ly"
6229 \notes \transpose c c' {
6230 % Torculus Auctus Descendens
6231 \[ a \pes b \flexa \auctum \descendens g \]
6238 \remove "Bar_number_engraver"
6242 \remove "Clef_engraver"
6243 \remove "Key_engraver"
6244 StaffSymbol \set #'transparent = ##t
6245 \remove "Time_signature_engraver"
6246 \remove "Bar_engraver"
6247 minimumVerticalExtent = ##f
6251 \remove Ligature_bracket_engraver
6252 \consists Vaticana_ligature_engraver
6253 NoteHead \set #'style = #'vaticana_punctum
6254 Stem \set #'transparent = ##t
6260 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6261 \include "gregorian-init.ly"
6263 \notes \transpose c c' {
6264 % Torculus Deminutus
6265 \[ a \pes b \flexa \deminutum g \]
6272 \remove "Bar_number_engraver"
6276 \remove "Clef_engraver"
6277 \remove "Key_engraver"
6278 StaffSymbol \set #'transparent = ##t
6279 \remove "Time_signature_engraver"
6280 \remove "Bar_engraver"
6281 minimumVerticalExtent = ##f
6285 \remove Ligature_bracket_engraver
6286 \consists Vaticana_ligature_engraver
6287 NoteHead \set #'style = #'vaticana_punctum
6288 Stem \set #'transparent = ##t
6295 @code{11. Torculus Initio Debilis}
6297 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6298 \include "gregorian-init.ly"
6300 \notes \transpose c c' {
6301 % Torculus Initio Debilis
6302 \[ \deminutum a \pes b \flexa g \]
6309 \remove "Bar_number_engraver"
6313 \remove "Clef_engraver"
6314 \remove "Key_engraver"
6315 StaffSymbol \set #'transparent = ##t
6316 \remove "Time_signature_engraver"
6317 \remove "Bar_engraver"
6318 minimumVerticalExtent = ##f
6322 \remove Ligature_bracket_engraver
6323 \consists Vaticana_ligature_engraver
6324 NoteHead \set #'style = #'vaticana_punctum
6325 Stem \set #'transparent = ##t
6331 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6332 \include "gregorian-init.ly"
6334 \notes \transpose c c' {
6335 % Torculus Auctus Descendens Initio Debilis
6336 \[ \deminutum a \pes b \flexa \auctum \descendens g \]
6343 \remove "Bar_number_engraver"
6347 \remove "Clef_engraver"
6348 \remove "Key_engraver"
6349 StaffSymbol \set #'transparent = ##t
6350 \remove "Time_signature_engraver"
6351 \remove "Bar_engraver"
6352 minimumVerticalExtent = ##f
6356 \remove Ligature_bracket_engraver
6357 \consists Vaticana_ligature_engraver
6358 NoteHead \set #'style = #'vaticana_punctum
6359 Stem \set #'transparent = ##t
6365 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6366 \include "gregorian-init.ly"
6368 \notes \transpose c c' {
6369 % Torculus Deminutus Initio Debilis
6370 \[ \deminutum a \pes b \flexa \deminutum g \]
6377 \remove "Bar_number_engraver"
6381 \remove "Clef_engraver"
6382 \remove "Key_engraver"
6383 StaffSymbol \set #'transparent = ##t
6384 \remove "Time_signature_engraver"
6385 \remove "Bar_engraver"
6386 minimumVerticalExtent = ##f
6390 \remove Ligature_bracket_engraver
6391 \consists Vaticana_ligature_engraver
6392 NoteHead \set #'style = #'vaticana_punctum
6393 Stem \set #'transparent = ##t
6400 @code{12. Porrectus}
6402 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6403 \include "gregorian-init.ly"
6405 \notes \transpose c c' {
6407 \[ a \flexa g \pes b \]
6414 \remove "Bar_number_engraver"
6418 \remove "Clef_engraver"
6419 \remove "Key_engraver"
6420 StaffSymbol \set #'transparent = ##t
6421 \remove "Time_signature_engraver"
6422 \remove "Bar_engraver"
6423 minimumVerticalExtent = ##f
6427 \remove Ligature_bracket_engraver
6428 \consists Vaticana_ligature_engraver
6429 NoteHead \set #'style = #'vaticana_punctum
6430 Stem \set #'transparent = ##t
6436 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6437 \include "gregorian-init.ly"
6439 \notes \transpose c c' {
6440 % Porrectus Auctus Descendens
6441 \[ a \flexa g \pes \auctum \descendens b \]
6448 \remove "Bar_number_engraver"
6452 \remove "Clef_engraver"
6453 \remove "Key_engraver"
6454 StaffSymbol \set #'transparent = ##t
6455 \remove "Time_signature_engraver"
6456 \remove "Bar_engraver"
6457 minimumVerticalExtent = ##f
6461 \remove Ligature_bracket_engraver
6462 \consists Vaticana_ligature_engraver
6463 NoteHead \set #'style = #'vaticana_punctum
6464 Stem \set #'transparent = ##t
6470 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6471 \include "gregorian-init.ly"
6473 \notes \transpose c c' {
6474 % Porrectus Deminutus
6475 \[ a \flexa g \pes \deminutum b \]
6482 \remove "Bar_number_engraver"
6486 \remove "Clef_engraver"
6487 \remove "Key_engraver"
6488 StaffSymbol \set #'transparent = ##t
6489 \remove "Time_signature_engraver"
6490 \remove "Bar_engraver"
6491 minimumVerticalExtent = ##f
6495 \remove Ligature_bracket_engraver
6496 \consists Vaticana_ligature_engraver
6497 NoteHead \set #'style = #'vaticana_punctum
6498 Stem \set #'transparent = ##t
6507 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6508 \include "gregorian-init.ly"
6510 \notes \transpose c c' {
6512 \[ \virga b \inclinatum a \inclinatum g \]
6519 \remove "Bar_number_engraver"
6523 \remove "Clef_engraver"
6524 \remove "Key_engraver"
6525 StaffSymbol \set #'transparent = ##t
6526 \remove "Time_signature_engraver"
6527 \remove "Bar_engraver"
6528 minimumVerticalExtent = ##f
6532 \remove Ligature_bracket_engraver
6533 \consists Vaticana_ligature_engraver
6534 NoteHead \set #'style = #'vaticana_punctum
6535 Stem \set #'transparent = ##t
6541 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6542 \include "gregorian-init.ly"
6544 \notes \transpose c c' {
6546 \[ \virga b \inclinatum a \inclinatum \auctum g \]
6553 \remove "Bar_number_engraver"
6557 \remove "Clef_engraver"
6558 \remove "Key_engraver"
6559 StaffSymbol \set #'transparent = ##t
6560 \remove "Time_signature_engraver"
6561 \remove "Bar_engraver"
6562 minimumVerticalExtent = ##f
6566 \remove Ligature_bracket_engraver
6567 \consists Vaticana_ligature_engraver
6568 NoteHead \set #'style = #'vaticana_punctum
6569 Stem \set #'transparent = ##t
6575 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6576 \include "gregorian-init.ly"
6578 \notes \transpose c c' {
6579 % Climacus Deminutus
6580 \[ \virga b \inclinatum a \inclinatum \deminutum g \]
6587 \remove "Bar_number_engraver"
6591 \remove "Clef_engraver"
6592 \remove "Key_engraver"
6593 StaffSymbol \set #'transparent = ##t
6594 \remove "Time_signature_engraver"
6595 \remove "Bar_engraver"
6596 minimumVerticalExtent = ##f
6600 \remove Ligature_bracket_engraver
6601 \consists Vaticana_ligature_engraver
6602 NoteHead \set #'style = #'vaticana_punctum
6603 Stem \set #'transparent = ##t
6610 @code{14. Scandicus}
6612 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6613 \include "gregorian-init.ly"
6615 \notes \transpose c c' {
6617 \[ g \pes a \virga b \]
6624 \remove "Bar_number_engraver"
6628 \remove "Clef_engraver"
6629 \remove "Key_engraver"
6630 StaffSymbol \set #'transparent = ##t
6631 \remove "Time_signature_engraver"
6632 \remove "Bar_engraver"
6633 minimumVerticalExtent = ##f
6637 \remove Ligature_bracket_engraver
6638 \consists Vaticana_ligature_engraver
6639 NoteHead \set #'style = #'vaticana_punctum
6640 Stem \set #'transparent = ##t
6646 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6647 \include "gregorian-init.ly"
6649 \notes \transpose c c' {
6650 % Scandicus Auctus Descendens
6651 \[ g \pes a \pes \auctum \descendens b \]
6658 \remove "Bar_number_engraver"
6662 \remove "Clef_engraver"
6663 \remove "Key_engraver"
6664 StaffSymbol \set #'transparent = ##t
6665 \remove "Time_signature_engraver"
6666 \remove "Bar_engraver"
6667 minimumVerticalExtent = ##f
6671 \remove Ligature_bracket_engraver
6672 \consists Vaticana_ligature_engraver
6673 NoteHead \set #'style = #'vaticana_punctum
6674 Stem \set #'transparent = ##t
6680 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6681 \include "gregorian-init.ly"
6683 \notes \transpose c c' {
6684 % Scandicus Deminutus
6685 \[ g \pes a \pes \deminutum b \]
6692 \remove "Bar_number_engraver"
6696 \remove "Clef_engraver"
6697 \remove "Key_engraver"
6698 StaffSymbol \set #'transparent = ##t
6699 \remove "Time_signature_engraver"
6700 \remove "Bar_engraver"
6701 minimumVerticalExtent = ##f
6705 \remove Ligature_bracket_engraver
6706 \consists Vaticana_ligature_engraver
6707 NoteHead \set #'style = #'vaticana_punctum
6708 Stem \set #'transparent = ##t
6717 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6718 \include "gregorian-init.ly"
6720 \notes \transpose c c' {
6722 \[ g \oriscus a \pes \virga b \]
6729 \remove "Bar_number_engraver"
6733 \remove "Clef_engraver"
6734 \remove "Key_engraver"
6735 StaffSymbol \set #'transparent = ##t
6736 \remove "Time_signature_engraver"
6737 \remove "Bar_engraver"
6738 minimumVerticalExtent = ##f
6742 \remove Ligature_bracket_engraver
6743 \consists Vaticana_ligature_engraver
6744 NoteHead \set #'style = #'vaticana_punctum
6745 Stem \set #'transparent = ##t
6751 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6752 \include "gregorian-init.ly"
6754 \notes \transpose c c' {
6755 % Salicus Auctus Descendens
6756 \[ g \oriscus a \pes \auctum \descendens b \]
6763 \remove "Bar_number_engraver"
6767 \remove "Clef_engraver"
6768 \remove "Key_engraver"
6769 StaffSymbol \set #'transparent = ##t
6770 \remove "Time_signature_engraver"
6771 \remove "Bar_engraver"
6772 minimumVerticalExtent = ##f
6776 \remove Ligature_bracket_engraver
6777 \consists Vaticana_ligature_engraver
6778 NoteHead \set #'style = #'vaticana_punctum
6779 Stem \set #'transparent = ##t
6789 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6790 \include "gregorian-init.ly"
6792 \notes \transpose c c' {
6794 \[ \stropha b \stropha b \stropha a \]
6801 \remove "Bar_number_engraver"
6805 \remove "Clef_engraver"
6806 \remove "Key_engraver"
6807 StaffSymbol \set #'transparent = ##t
6808 \remove "Time_signature_engraver"
6809 \remove "Bar_engraver"
6810 minimumVerticalExtent = ##f
6814 \remove Ligature_bracket_engraver
6815 \consists Vaticana_ligature_engraver
6816 NoteHead \set #'style = #'vaticana_punctum
6817 Stem \set #'transparent = ##t
6829 Unlike most other neumes notation systems, the input language for
6830 neumes does not necessarily reflect directly the typographical
6831 appearance, but is designed to solely focuse on musical meaning. For
6832 example, @code{\[ a \pes b \flexa g \]} produces a Torculus consisting
6833 of three Punctum heads, while @code{\[ a \flexa g \pes b \]} produces
6834 a Porrectus with a curved flexa shape and only a single Punctum head.
6835 There is no command to explicitly typeset the curved flexa shape; the
6836 decision of when to typeset a curved flexa shape is purely taken from
6837 the musical input. The idea of this approach is to separate the
6838 musical aspects of the input from the notation style of the output.
6839 This way, the same input can be reused to typeset the same music in a
6840 different style of Gregorian chant notation such as Hufnagel (also
6841 known as German gothic neumes) or Medicaea (kind of a very simple
6842 forerunner of the Editio Vaticana). As soon as Hufnagel ligature
6843 engraver and Medicaea ligature engraver will have been implemented, it
6844 will be as simple as replacing the ligature engraver in the
6845 @internalsref{Voice} context to get the desired notation style from
6848 The following table shows the code fragments that produce the
6849 ligatures in the above neumes table. The letter in the first column
6850 in each line of the below table indicates to which ligature in the
6851 above table it refers. The second column gives the name of the
6852 ligature. The third column shows the code fragment that produces this
6853 ligature, using @code{g}, @code{a} and @code{b} as example pitches.
6855 @multitable @columnfractions .1 .4 .5
6869 Punctum Inclinatum @tab
6870 @code{\[ \inclinatum b \]}
6874 Punctum Auctum Ascendens @tab
6875 @code{\[ \auctum \ascendens b \]}
6879 Punctum Auctum Descendens @tab
6880 @code{\[ \auctum \descendens b \]}
6884 Punctum Inclinatum Auctum @tab
6885 @code{\[ \inclinatum \auctum b \]}
6889 Punctum Inclinatum Parvum @tab
6890 @code{\[ \inclinatum \deminutum b \]}
6895 @code{\[ \virga b \]}
6900 @code{\[ \stropha b \]}
6905 @code{\[ \stropha \auctum b \]}
6910 @code{\[ \oriscus b \]}
6914 Clivis vel Flexa @tab
6915 @code{\[ b \flexa g \]}
6919 Clivis Aucta Descendens @tab
6920 @code{\[ b \flexa \auctum \descendens g \]}
6924 Clivis Aucta Ascendens @tab
6925 @code{\[ b \flexa \auctum \ascendens g \]}
6930 @code{\[ b \flexa \deminutum g \]}
6934 Podatus vel Pes @tab
6935 @code{\[ g \pes b \]}
6939 Pes Auctus Descendens @tab
6940 @code{\[ g \pes \auctum \descendens b \]}
6944 Pes Auctus Ascendens @tab
6945 @code{\[ g \pes \auctum \ascendens b \]}
6950 @code{\[ g \pes \deminutum b \]}
6955 @code{\[ \oriscus g \pes \virga b \]}
6959 Pes Quassus Auctus Descendens @tab
6960 @code{\[ \oriscus g \pes \auctum \descendens b \]}
6965 @code{\[ \quilisma g \pes b \]}
6969 Quilisma Pes Auctus Descendens @tab
6970 @code{\[ \quilisma g \pes \auctum \descendens b \]}
6974 Pes Initio Debilis @tab
6975 @code{\[ \deminutum g \pes b \]}
6979 Pes Auctus Descendens Initio Debilis @tab
6980 @code{\[ \deminutum g \pes \auctum \descendens b \]}
6985 @code{\[ a \pes b \flexa g \]}
6989 Torculus Auctus Descendens @tab
6990 @code{\[ a \pes b \flexa \auctum \descendens g \]}
6994 Torculus Deminutus @tab
6995 @code{\[ a \pes b \flexa \deminutum g \]}
6999 Torculus Initio Debilis @tab
7000 @code{\[ \deminutum a \pes b \flexa g \]}
7004 Torculus Auctus Descendens Initio Debilis @tab
7005 @code{\[ \deminutum a \pes b \flexa \auctum \descendens g \]}
7009 Torculus Deminutus Initio Debilis @tab
7010 @code{\[ \deminutum a \pes b \flexa \deminutum g \]}
7015 @code{\[ a \flexa g \pes b \]}
7019 Porrectus Auctus Descendens @tab
7020 @code{\[ a \flexa g \pes \auctum \descendens b \]}
7024 Porrectus Deminutus @tab
7025 @code{\[ a \flexa g \pes \deminutum b \]}
7030 @code{\[ \virga b \inclinatum a \inclinatum g \]}
7034 Climacus Auctus @tab
7035 @code{\[ \virga b \inclinatum a \inclinatum \auctum g \]}
7039 Climacus Deminutus @tab
7040 @code{\[ \virga b \inclinatum a \inclinatum \deminutum g \]}
7045 @code{\[ g \pes a \virga b \]}
7049 Scandicus Auctus Descendens @tab
7050 @code{\[ g \pes a \pes \auctum \descendens b \]}
7054 Scandicus Deminutus @tab
7055 @code{\[ g \pes a \pes \deminutum b \]}
7060 @code{\[ g \oriscus a \pes \virga b \]}
7064 Salicus Auctus Descendens @tab
7065 @code{\[ g \oriscus a \pes \auctum \descendens b \]}
7070 @code{\[ \stropha b \stropha b \stropha a \]}
7076 The following head prefixes are supported:
7078 @cindex @code{\virga}
7080 @cindex @code{\stropha}
7082 @cindex @code{\inclinatum}
7084 @cindex @code{\auctum}
7086 @cindex @code{\descendens}
7088 @cindex @code{\ascendens}
7090 @cindex @code{\oriscus}
7092 @cindex @code{\quilisma}
7094 @cindex @code{\deminutum}
7097 Head prefixes can be accumulated, though restrictions apply. For
7098 example, either @code{\descendens} or @code{\ascendens} can be applied
7099 to a head, but not both to the same head.
7102 @cindex @code{\flexa}
7103 Two adjacent heads can be tied together with the @code{\pes} and
7104 @code{\flexa} infix commands for a rising and falling line of melody,
7109 Trigonus: apply equal spacing, regardless of pitch.
7112 @subsection Figured bass
7114 @cindex Basso continuo
7116 @c TODO: musicological blurb about FB
7120 LilyPond has limited support for figured bass:
7122 @lilypond[verbatim,fragment]
7124 \context Voice \notes { \clef bass dis4 c d ais}
7125 \context FiguredBass
7127 < 6 >4 < 7 >8 < 6+ [_!] >
7133 The support for figured bass consists of two parts: there is an input
7134 mode, introduced by @code{\figures}, where you can enter bass figures
7135 as numbers, and there is a context called @internalsref{FiguredBass} that
7136 takes care of making @internalsref{BassFigure} objects.
7138 In figures input mode, a group of bass figures is delimited by
7139 @code{<} and @code{>}. The duration is entered after the @code{>>}:
7144 \context FiguredBass
7148 Accidentals are added when you append @code{-}, @code{!} and @code{+}
7155 \context FiguredBass
7156 \figures { <4- 6+ 7!> }
7159 Spaces or dashes may be inserted by using @code{_}. Brackets are
7160 introduced with @code{[} and @code{]}:
7166 \context FiguredBass
7167 \figures { < [4 6] 8 [_! 12]> }
7170 Although the support for figured bass may superficially resemble chord
7171 support, it works much simpler. The @code{\figures} mode simply
7172 stores the numbers , and @internalsref{FiguredBass} context prints
7173 them as entered. There is no conversion to pitches, and no
7174 realizations of the bass are played in the MIDI file.
7176 Internally, the code produces markup texts. You can use any of the
7177 markup text properties to override formatting. For example, the
7178 vertical spacing of the figures may be set with @code{baseline-skip}.
7182 @internalsref{BassFigureEvent} music, @internalsref{BassFigure} object,
7183 and @internalsref{FiguredBass} context.
7187 Slash notation for alterations is not supported.
7190 @node Vaticana style contexts
7191 @subsection Vaticana style contexts
7193 @cindex VaticanaVoiceContext
7194 @cindex VaticanaStaffContext
7196 The predefined @code{VaticanaVoiceContext} and
7197 @code{VaticanaStaffContext} can be used to easily engrave a piece of
7198 Gregorian Chant in the style of the Editio Vaticana. These contexts
7199 initialize all relevant context properties and grob properties to
7200 proper values. With these contexts, you can immediately go ahead
7201 entering the chant, as the following short excerpt demonstrates:
7203 @lilypond[raggedright,verbatim,noindent]
7204 \include "gregorian-init.ly"
7207 \context VaticanaVoice {
7208 \property Score.BarNumber \set #'transparent = ##t
7210 \[ c'( c' \flexa a \] \[ a \flexa \deminutum g) \] f \divisioMinima
7211 \[ f( \pes a c' c' \pes d') \] c' \divisioMinima \break
7212 \[ c'( c' \flexa a \] \[ a \flexa \deminutum g) \] f \divisioMinima
7215 \context Lyrics \lyrics {
7216 San- ctus, San- ctus, San- ctus
7221 @node Contemporary notation
7222 @section Contemporary notation
7224 In the 20th century, composers have greatly expanded the musical
7225 vocabulary. With this expansion, many innovations in musical notation
7226 have been tried. The book by Stone (1980) gives a comprehensive
7227 overview (see @ref{Literature list}). In general, the use of new,
7228 innovative notation makes a piece harder to understand and perform and
7229 its use should therefore be avoided if possible. For this reason,
7230 support for contemporary notation in LilyPond is limited.
7239 @subsection Clusters
7243 In musical terminology, a @emph{cluster} denotes a range of
7244 simultaneously sounding pitches that may change over time. The set of
7245 available pitches to apply usually depends on the accoustic source.
7246 Thus, in piano music, a cluster typically consists of a continous range
7247 of the semitones as provided by the piano's fixed set of a chromatic
7248 scale. In choral music, each singer of the choir typically may sing an
7249 arbitrary pitch within the cluster's range that is not bound to any
7250 diatonic, chromatic or other scale. In electronic music, a cluster
7251 (theoretically) may even cover a continuous range of pitches, thus
7252 resulting in coloured noise, such as pink noise.
7254 Clusters can be denoted in the context of ordinary staff notation by
7255 engraving simple geometrical shapes that replace ordinary notation of
7256 notes. Ordinary notes as musical events specify starting time and
7257 duration of pitches; however, the duration of a note is expressed by the
7258 shape of the note head rather than by the horizontal graphical extent of
7259 the note symbol. In contrast, the shape of a cluster geometrically
7260 describes the development of a range of pitches (vertical extent) over
7261 time (horizontal extent). Still, the geometrical shape of a cluster
7262 covers the area in wich any single pitch contained in the cluster would
7263 be notated as an ordinary note. From this point of view, it is
7264 reasonable to specify a cluster as the envelope of a set of notes.
7268 A cluster is engraved as the envelope of a set of
7269 cluster-notes. Cluster notes are created by applying the function
7270 @code{notes-to-clusters} to a sequence of chords, e.g.
7272 @lilypond[relative 1,verbatim]
7273 \apply #notes-to-clusters { <c e > <b f'> }
7276 The following example (from
7277 @inputfileref{input/regression,cluster.ly}) shows what the result
7280 @lilypondfile[notexidoc]{cluster.ly}
7282 By default, @internalsref{Cluster_spanner_engraver} is in the
7283 @internalsref{Voice} context. This allows putting ordinary notes and
7284 clusters together in the same staff, even simultaneously. In such a
7285 case no attempt is made to automatically avoid collisions between
7286 ordinary notes and clusters.
7290 @internalsref{ClusterSpanner}, @internalsref{ClusterSpannerBeacon},
7291 @inputfileref{input/regression,cluster.ly},
7292 @internalsref{Cluster_spanner_engraver}, and @internalsref{ClusterNoteEvent}.
7296 Music expressions like @code{<< @{ g8 e8 @} a4 >>} are not printed
7297 accurately. Use @code{<g a>8 <e a>8} instead.
7302 @subsection Fermatas
7308 Contemporary music notation frequently uses special fermata symbols to
7309 indicate fermatas of differing lengths.
7313 The following are supported
7315 @lilypond[singleline]
7317 << \addlyrics \notes {
7337 \context Lyrics \lyrics {
7338 "shortfermata" "fermata" "longfermata" "verylongfermata"
7343 See @ref{Articulations} for general instructions how to apply scripts
7344 such as fermatas to a @code{\notes@{@}} block.
7347 @section Tuning output
7349 There are situations where default layout decisions are not
7350 sufficient. In this section we discuss ways to override these
7353 Formatting is internally done by manipulating so called objects
7354 (graphic objects). Each object carries with it a set of properties
7355 (object or layout properties) specific to that object. For example, a
7356 stem object has properties that specify its direction, length and
7359 The most direct way of tuning the output is by altering the values of
7360 these properties. There are two ways of doing that: first, you can
7361 temporarily change the definition of one type of object, thus
7362 affecting a whole set of objects. Second, you can select one specific
7363 object, and set a layout property in that object.
7365 Do not confuse layout properties with translation
7366 properties. Translation properties always use a mixed caps style
7367 naming, and are manipulated using @code{\property}:
7369 \property Context.propertyName = @var{value}
7371 Layout properties are use Scheme style variable naming, i.e. lower
7372 case words separated with dashes. They are symbols, and should always
7373 be quoted using @code{#'}. For example, this could be an imaginary
7374 layout property name:
7376 #'layout-property-name
7381 * Constructing a tweak::
7390 @node Tuning objects
7391 @subsection Tuning objects
7393 @cindex object description
7395 The definition of an object is a list of default object
7396 properties. For example, the definition of the Stem object (available
7397 in @file{scm/define-grobs.scm}), includes the following definitions
7398 for @internalsref{Stem}:
7402 (beamed-lengths . (0.0 2.5 2.0 1.5))
7403 (Y-extent-callback . ,Stem::height)
7408 Adding variables on top of this existing definition overrides the
7409 system default, and alters the resulting appearance of the layout
7415 Changing a variable for only one object is commonly achieved with
7419 \once \property @var{context}.@var{objectname}
7420 \override @var{symbol} = @var{value}
7422 Here @var{symbol} is a Scheme expression of symbol type, @var{context}
7423 and @var{objectname} is a string and @var{value} is a Scheme expression.
7424 This command applies a setting only during one moment in the score.
7426 In the following example, only one @internalsref{Stem} object is
7427 changed from its original setting:
7429 @lilypond[verbatim, fragment, relative=1]
7431 \once \property Voice.Stem \set #'thickness = #4
7435 @cindex @code{\once}
7437 For changing more objects, the same command, without @code{\once} can
7440 \property @var{context}.@var{objectname} \override @var{symbol} = @var{value}
7442 This command adds @code{@var{symbol} = @var{value}} to the definition
7443 of @var{objectname} in the context @var{context}, and this definition
7444 stays in place until it is removed.
7446 An existing definition may be removed by the following command:
7449 \property @var{context}.@var{objectname} \revert @var{symbol}
7452 All @code{\override} and @code{\revert} commands should be balanced.
7453 The @code{\set} shorthand performs a revert followed by an override,
7454 and is often more convenient to use
7457 \property @var{context}.@var{objectname} \set @var{symbol} = @var{value}
7461 @lilypond[verbatim,quote]
7462 c'4 \property Voice.Stem \override #'thickness = #4.0
7464 c'4 \property Voice.Stem \revert #'thickness
7468 The following example gives exactly the same result as the previous
7469 one (assuming the system default for stem thickness is 1.3):
7471 @lilypond[verbatim,quote]
7472 c'4 \property Voice.Stem \set #'thickness = #4.0
7474 c'4 \property Voice.Stem \set #'thickness = #1.3
7478 Reverting a setting which was not set in the first place has no
7479 effect. However, if the setting was set as a system default, this may
7480 remove the default value, and this may give surprising results,
7481 including crashes. In other words, @code{\override} and
7482 @code{\revert} must be carefully balanced. The following are examples
7483 of correct nesting of @code{\override}, @code{\set}, @code{\revert}:
7487 a clumsy but correct form:
7489 \override \revert \override \revert \override \revert
7493 shorter version of the same:
7495 \override \set \set \revert
7499 a short form, using only @code{\set}. This requires you to know the
7502 \set \set \set \set @var{to default value}
7506 if there is no default (i.e. by default, the object property is unset),
7509 \set \set \set \revert
7513 The object description is an Scheme association
7514 list. Since a Scheme list is a singly linked list, we can treat it as
7515 a stack, and @code{\override} and @code{\revert} are push and pop
7516 operations. The association list is stored in a normal context
7519 \property Voice.NoteHead = #'()
7521 will effectively erase @internalsref{NoteHead}s from the current
7522 @internalsref{Voice}. Typically, this will blank the object. However,
7523 this mechanism should not be used: it may cause crashes or other
7528 @internalsref{OverrideProperty}, @internalsref{RevertProperty},
7529 @internalsref{PropertySet}, @internalsref{All-backend-properties}, and
7530 @internalsref{All-layout-objects}.
7535 The backend is not very strict in type-checking object properties.
7536 Cyclic references in Scheme values for properties cause hangs and/or
7537 crashes. Reverting properties that are system defaults may also lead
7540 @node Constructing a tweak
7541 @subsection Constructing a tweak
7544 @cindex internal documentation
7545 @cindex finding graphical objects
7546 @cindex graphical object descriptions
7548 @cindex @code{\override}
7550 @cindex internal documentation
7554 Three pieces of information are required to use @code{\override} and
7555 @code{\set}: the name of the layout object, the context and the name
7556 of the property. We demonstrate how to glean this information from
7557 the notation manual and the generated documentation.
7559 The generated documentation is a set of HTML pages which should be
7560 included if you installed a binary distribution, typically in
7561 @file{/usr/share/doc/lilypond}. They are also available on the web:
7562 go to the @uref{http://lilypond.org,LilyPond website}, click
7563 ``Documentation'', select the correct version, and click then
7564 ``Program reference.'' It is advisable to bookmark the local HTML
7565 files. They will load faster than the ones on the web. If you use the
7566 version from the web, you must check whether the documentation matches
7567 the program version: it is generated from the definitions that the
7568 program uses, and therefore it is strongly tied to the LilyPond
7572 @c [TODO: revise for new site.]
7574 Suppose we want to move the fingering indication in the fragment below:
7576 @lilypond[relative=2,verbatim]
7582 If you visit the documentation of @code{Fingering} (in @ref{Fingering
7583 instructions}), you will notice that there is written:
7588 @internalsref{FingerEvent} and @internalsref{Fingering}.
7595 In other words, the fingerings once entered, are internally stored as
7596 @code{FingerEvent} music objects. When printed, a @code{Fingering}
7597 layout object is created for every @code{FingerEvent}.
7599 The Fingering object has a number of different functions, and each of
7600 those is captured in an interface. The interfaces are listed under
7601 @internalsref{Fingering} in the program reference.
7605 The @code{Fingering} object has a fixed size
7606 (@internalsref{item-interface}), the symbol is a piece of text
7607 (@internalsref{text-interface}), whose font can be set
7608 (@internalsref{font-interface}). It is centered horizontally
7609 (@internalsref{self-alignment-interface}), it is placed next to other
7610 objects (@internalsref{side-position-interface}) vertically, and its
7611 placement is coordinated with other scripts
7612 (@internalsref{text-script-interface}). It also has the standard
7613 @internalsref{grob-interface} (grob stands for Graphical object)
7615 @cindex graphical object
7616 @cindex layout object
7617 @cindex object, layout
7618 with all the variables that come with
7619 it. Finally, it denotes a fingering instruction, so it has
7620 @internalsref{finger-interface}.
7622 For the vertical placement, we have to look under
7623 @code{side-position-interface}:
7625 @code{side-position-interface}
7627 Position a victim object (this one) next to other objects (the
7628 support). In this case, the property @code{direction} signifies where to put the
7629 victim object relative to the support (left or right, up or down?)
7634 below this description, the variable @code{padding} is described as
7638 (dimension, in staff space)
7640 add this much extra space between objects that are next to each
7641 other. Default value: @code{0.6}
7645 By increasing the value of @code{padding}, we can move away the
7646 fingering. The following command inserts 3 staff spaces of white
7647 between the note and the fingering:
7649 \once \property Voice.Fingering \set #'padding = #3
7652 Inserting this command before the Fingering object is created,
7653 i.e. before @code{c2}, yields the following result:
7655 @lilypond[relative=2,fragment,verbatim]
7656 \once \property Voice.Fingering
7663 The context name @code{Voice} in the example above can be determined
7664 as follows. In the documentation for @internalsref{Fingering}, it says
7666 Fingering grobs are created by: @internalsref{Fingering_engraver}
7669 Clicking @code{Fingering_engraver} shows the documentation of
7670 the module responsible for interpreting the fingering instructions and
7671 translating them to a @code{Fingering} object. Such a module is called
7672 an @emph{engraver}. The documentation of the @code{Fingering_engraver}
7675 Fingering_engraver is part of contexts: Voice
7677 so tuning the settings for Fingering should be done with
7679 \property Voice.Fingering \set @dots{}
7682 Of course, the tweak may also done in a larger context than
7683 @code{Voice}, for example, @internalsref{Staff} or
7684 @internalsref{Score}.
7688 The program reference also contains alphabetical lists of
7689 @internalsref{Contexts}, @internalsref{All-layout-objects} and
7690 @internalsref{Music-expressions}, so you can also find which objects to
7691 tweak by browsing the internals document.
7695 @subsection Applyoutput
7697 The most versatile way of tuning an object is @code{\applyoutput}. Its
7700 \applyoutput @var{proc}
7704 where @var{proc} is a Scheme function, taking three arguments.
7706 When interpreted, the function @var{proc} is called for every layout
7707 object found in the context, with the following arguments:
7709 @item the layout object itself,
7710 @item the context where the layout object was created, and
7711 @item the context where @code{\applyoutput} is processed.
7714 In addition, the cause of the layout object, i.e. the music
7715 expression or object that was responsible for creating it, is in the
7716 object property @code{cause}. For example, for a note head, this is a
7717 @internalsref{NoteHead} event, and for a @internalsref{Stem} object,
7718 this is a @internalsref{NoteHead} object.
7722 @node Font selection
7723 @subsection Font selection
7725 The most common thing to change about the appearance of fonts is their
7726 size. The font size of any context can be easily changed by setting
7727 the @code{fontSize} property for that context. Its value is an
7728 integer: negative numbers make the font smaller, positive numbers
7729 larger. An example is given below:
7731 @lilypond[fragment,relative=1,verbatim,quote]
7732 c4 c4 \property Voice.fontSize = #-1
7735 This command will set @code{font-relative-size} (see below), and does
7736 not change the size of variable symbols, such as beams or slurs.
7739 One of the uses of @code{fontSize} is to get smaller symbol for cue
7740 notes. An elaborate example of those is in
7741 @inputfileref{input/test,cue-notes.ly}.
7743 @cindex magnification
7745 The size of the font may be scaled with the object property
7746 @code{font-magnification}. For example, @code{2.0} blows up all
7747 letters by a factor 2 in both directions.
7756 The font used for printing a object can be selected by setting
7757 @code{font-name}, e.g.
7759 \property Staff.TimeSignature
7760 \set #'font-name = #"cmr17"
7764 Any font can be used, as long as it is available to @TeX{}. Possible
7765 fonts include foreign fonts or fonts that do not belong to the
7766 Computer Modern font family.
7768 Font selection for the standard fonts, @TeX{}'s Computer Modern fonts,
7769 can also be adjusted with a more fine-grained mechanism. By setting
7770 the object properties described below, you can select a different font;
7771 all three mechanisms work for every object that supports
7772 @code{font-interface}:
7776 is a symbol indicating the general class of the typeface. Supported are
7777 @code{roman} (Computer Modern), @code{braces} (for piano staff
7778 braces), @code{music} (the standard music font, including ancient
7779 glyphs), @code{dynamic} (for dynamic signs) and @code{typewriter}.
7782 is a symbol indicating the shape of the font, there are typically several
7783 font shapes available for each font family. Choices are @code{italic},
7784 @code{caps} and @code{upright}.
7787 is a symbol indicating the series of the font. There are typically several
7788 font series for each font family and shape. Choices are @code{medium}
7791 @item font-relative-size
7792 is a number indicating the size relative the standard size. For example,
7793 with 20pt staff height, relative size -1 corresponds to 16pt staff
7794 height, and relative size +1 corresponds to 23 pt staff height.
7796 There are small differences in design between fonts designed for
7797 different sizes, hence @code{font-relative-size} is preferred over
7798 @code{font-magnification} for changing font sizes.
7801 @item font-design-size
7802 is a number indicating the design size of the font.
7804 This is a feature of the Computer Modern Font: each point size has a
7805 slightly different design. Smaller design sizes are relatively wider,
7806 which enhances readability.
7809 For any of these properties, the value @code{*} (i.e. the symbol
7810 @code{*}, entered as @code{#'*}), acts as a wildcard. This can be used
7811 to override default setting, which are always present. For example:
7813 \property Lyrics . LyricText \override #'font-series = #'bold
7814 \property Lyrics . LyricText \override #'font-family = #'typewriter
7815 \property Lyrics . LyricText \override #'font-shape = #'*
7818 @cindex @code{font-style}
7822 The following commands set @code{fontSize} for the current voice.
7824 @cindex @code{\tiny}
7826 @cindex @code{\small}
7828 @cindex @code{\normalsize}
7833 Relative size is not linked to any real size.
7835 There is no style sheet provided for other fonts besides the @TeX{}
7836 family, and the style sheet cannot be modified easily.
7838 @cindex font selection
7839 @cindex font magnification
7840 @cindex @code{font-interface}
7844 @subsection Text markup
7849 @cindex typeset text
7851 LilyPond has an internal mechanism to typeset texts. You can access it
7852 with the keyword @code{\markup}. Within markup mode, you can enter texts
7853 similar to lyrics: simply enter them, surrounded by spaces:
7856 @lilypond[verbatim,fragment,relative=1]
7857 c1^\markup { hello }
7858 c1_\markup { hi there }
7859 c1^\markup { hi \bold there, is \italic anyone home? }
7862 @cindex font switching
7864 The markup in the example demonstrates font switching commands. The
7865 command @code{\bold} and @code{\italic} only apply to the first
7866 following word; enclose a set of texts with braces to apply a command
7869 \markup @{ \bold @{ hi there @} @}
7873 For clarity, you can also do this for single arguments, e.g.
7875 \markup @{ is \italic @{ anyone @} home @}
7878 @cindex font size, texts
7880 The following size commands set absolute sizes:
7882 @cindex @code{\teeny}
7883 @cindex @code{\tiny}
7884 @cindex @code{\small}
7885 @cindex @code{\large}
7886 @cindex @code{\huge}
7896 You can also make letter larger or smaller relative to their neighbors,
7897 with the commands @code{\larger} and @code{\smaller}.
7901 @cindex font style, for texts
7902 @cindex @code{\bold}
7903 @cindex @code{\dynamic}
7904 @cindex @code{\number}
7905 @cindex @code{\italic}
7907 The following font change commands are defined:
7910 changes to the font used in dynamic signs. This font does not
7911 contain all characters of the alphabet, so when producing ``piu f'',
7912 the ``piu'' should be done in a different font.
7916 changes to the font used in time signatures. It only contains
7917 numbers and a few punctuation marks.
7919 changes @code{font-shape} to @code{italic}.
7921 changes @code{font-series} to @code{bold}.
7924 @cindex raising text
7925 @cindex lowering text
7927 @cindex translating text
7930 @cindex @code{\super}
7932 Raising and lowering texts can be done with @code{\super} and
7935 @lilypond[verbatim,fragment,relative=1]
7936 c1^\markup { E "=" mc \super "2" }
7939 @cindex @code{\raise}
7941 If you want to give an explicit amount for lowering or raising, use
7942 @code{\raise}. This command takes a Scheme valued first argument, and
7943 a markup object as second argument:
7945 @lilypond[verbatim,fragment,relative=1,quote]
7946 c1^\markup { C \small \raise #1.0 \bold { "9/7+" }}
7948 The argument to @code{\raise} is the vertical displacement amount,
7949 measured in (global) staff spaces. @code{\raise} and @code{\super}
7950 raise objects in relation to their surrounding markups. They cannot be
7951 used to move a single text up or down, when it is above or below a
7952 note, since the mechanism that positions it next to the note cancels
7953 any vertical shift. For vertical positioning, use the @code{padding}
7954 and/or @code{extra-offset} properties.
7956 Other commands taking single arguments include
7959 @item \bracket, \hbracket
7960 Bracket the argument markup with normal and horizontal brackets
7964 @cindex @code{\musicglyph}
7965 This is converted to a musical symbol, e.g. @code{\musicglyph
7966 #"accidentals-0"} will select the natural sign from the music font.
7967 See @ref{The Feta font} for a complete listing of the possible glyphs.
7969 This produces a single character, e.g. @code{\char #65} produces the
7972 @item \note @var{log} @var{dots} @var{dir}
7973 @cindex @code{\note}
7975 This produces a note with a stem pointing in @var{dir} direction, with
7976 duration log @var{log} and @var{dots} augmentation dots. The duration
7977 log is the negative 2-logarithm of the duration denominator. For
7978 example, a quarter note has log 2, an eighth note 3 and a breve has
7981 @item \hspace #@var{amount}
7982 @cindex @code{\hspace}
7983 This produces a invisible object taking horizontal space.
7985 \markup @{ A \hspace #2.0 B @}
7987 will put extra space between A and B, on top of the space that is
7988 normally inserted before elements on a line.
7990 @item \fontsize #@var{size}
7991 @cindex @code{\fontsize}
7992 This sets the relative font size, eg.
7994 A \fontsize #2 @{ B C @} D
7998 This will enlarge the B and the C by two steps.
7999 @item \translate #(cons @var{x} @var{y})
8001 This translates an object. Its first argument is a cons of numbers
8003 A \translate #(cons 2 -3) @{ B C @} D
8005 This moves `B C' 2 spaces to the right, and 3 down.
8007 @item \magnify #@var{mag}
8008 @cindex @code{\magnify}
8009 This sets the font magnification for the its argument. In the following
8010 example, the middle A will be 10% larger:
8012 A \magnify #1.1 @{ A @} A
8016 @item \override #(@var{key} . @var{value})
8017 @cindex @code{\override}
8018 This overrides a formatting property for its argument. The argument
8019 should be a key/value pair, e.g.
8021 m \override #'(font-family . math) m m
8025 In markup mode you can compose expressions, similar to mathematical
8026 expressions, XML documents and music expressions. The braces group
8027 notes into horizontal lines. Other types of lists also exist: you can
8028 stack expressions grouped with @code{<}, and @code{>} vertically with
8029 the command @code{\column}. Similarly, @code{\center} aligns texts by
8032 @lilypond[verbatim,fragment,relative=1]
8033 c1^\markup { \column < a bbbb c > }
8034 c1^\markup { \center < a bbbb c > }
8035 c1^\markup { \line < a b c > }
8038 The markup mechanism is extensible. Refer to
8039 @file{scm/new-markup.scm} for more information.
8045 @internalsref{Markup-functions}, and @file{scm/new-markup.scm}.
8052 Text layout is ultimately done by @TeX{}, which does kerning of
8053 letters. LilyPond does not account for kerning, so texts will be
8054 spaced slightly too wide.
8056 Syntax errors for markup mode are confusing.
8058 Markup texts cannot be used in the titling of the @code{\header}
8059 field. Titles are made by La@TeX{}, so La@TeX{} commands should be used
8066 @section Global layout
8068 The global layout determined by three factors: the page layout, the
8069 line breaks and the spacing. These all influence each other. The
8070 choice of spacing determines how densely each system of music is set,
8071 which influences where line breaks breaks are chosen, and thus
8072 ultimately how many pages a piece of music takes. In this section, the
8073 algorithm for spacing music is explained, and how spacing can be
8076 Globally spoken, this procedure happens in three steps: first,
8077 flexible distances (``springs'') are chosen, based on durations. All
8078 possible line breaking combination are tried, and the one with the
8079 best results---a layout that has uniform density and requires as
8080 little stretching or cramping as possible---is chosen. When the score
8081 is processed by @TeX{}, each page is filled with systems, and page breaks
8082 are chosen whenever the page gets full.
8087 * Vertical spacing::
8088 * Horizontal spacing::
8095 @node Vertical spacing
8096 @subsection Vertical spacing
8098 @cindex vertical spacing
8099 @cindex distance between staves
8100 @cindex staff distance
8101 @cindex between staves, distance
8102 @cindex staffs per page
8103 @cindex space between staves
8105 The height of each system is determined automatically by LilyPond, to
8106 keep systems from bumping into each other, some minimum distances are
8107 set. By changing these, you can put staves closer together, and thus
8108 put more systems onto one page.
8110 Normally staves are stacked vertically. To make
8111 staves maintain a distance, their vertical size is padded. This is
8112 done with the property @code{minimumVerticalExtent}. It takes a pair
8113 of numbers, so if you want to make it smaller from its, then you could
8116 \property Staff.minimumVerticalExtent = #'(-4 . 4)
8118 This sets the vertical size of the current staff to 4 staff-space on
8119 either side of the center staff line. The argument of
8120 @code{minimumVerticalExtent} is interpreted as an interval, where the
8121 center line is the 0, so the first number is generally negative. The
8122 staff can be made larger at the bottom by setting it to @code{(-6
8125 The piano staves are handled a little differently: to make cross-staff
8126 beaming work correctly, it is necessary that the distance between staves
8127 is fixed beforehand. This is also done with a
8128 @internalsref{VerticalAlignment} object, created in
8129 @internalsref{PianoStaff}. In this object the distance between the
8130 staves is fixed by setting @code{forced-distance}. If you want to
8131 override this, use a @code{\translator} block as follows:
8135 VerticalAlignment \override #'forced-distance = #9
8138 This would bring the staves together at a distance of 9 staff spaces,
8139 measured from the center line of each staff.
8143 Vertical alignment of staves is handled by the
8144 @internalsref{VerticalAlignment} object.
8148 @node Horizontal spacing
8149 @subsection Horizontal Spacing
8151 The spacing engine translates differences in durations into
8152 stretchable distances (``springs'') of differing lengths. Longer
8153 durations get more space, shorter durations get less. The shortest
8154 durations get a fixed amount of space (which is controlled by
8155 @code{shortest-duration-space} in the @internalsref{SpacingSpanner} object).
8156 /The longer the duration, the more space it gets: doubling a
8157 duration adds a fixed amount (this amount is controlled by
8158 @code{spacing-increment}) of space to the note.
8160 For example, the following piece contains lots of half, quarter and
8161 8th notes, the eighth note is followed by 1 note head width (NHW).
8162 The quarter note is followed by 2 NHW, the half by 3 NHW, etc.
8163 @lilypond[fragment, verbatim, relative=1] c2 c4. c8 c4. c8 c4. c8 c8
8167 Normally, @code{shortest-duration-space} is set to 1.2, which is the
8168 width of a note head, and @code{shortest-duration-space} is set to
8169 2.0, meaning that the shortest note gets 2 NHW (2 times
8170 @code{shortest-duration-space}) of space. For normal notes, this space
8171 is always counted from the left edge of the symbol, so the shortest
8172 notes are generally followed by one NHW of space.
8174 If one would follow the above procedure exactly, then adding a single
8175 32th note to a score that uses 8th and 16th notes, would widen up the
8176 entire score a lot. The shortest note is no longer a 16th, but a 32nd,
8177 thus adding 2 noteheads of space to every note. To prevent this, the
8178 shortest duration for spacing is not the shortest note in the score,
8179 but the most commonly found shortest note. Notes that are even
8180 shorter this are followed by a space that is proportonial to their
8181 duration relative to the common shortest note. So if we were to add
8182 only a few 16th notes to the example above, they would be followed by
8185 @lilypond[fragment, verbatim, relative=2]
8186 c2 c4. c8 c4. c16[ c] c4. c8 c8 c8 c4 c4 c4
8189 The most common shortest duration is determined as follows: in every
8190 measure, the shortest duration is determined. The most common short
8191 duration, is taken as the basis for the spacing, with the stipulation
8192 that this shortest duration should always be equal to or shorter than
8193 1/8th note. The shortest duration is printed when you run lilypond
8194 with @code{--verbose}. These durations may also be customized. If you
8195 set the @code{common-shortest-duration} in
8196 @internalsref{SpacingSpanner}, then this sets the base duration for
8197 spacing. The maximum duration for this base (normally 1/8th), is set
8198 through @code{base-shortest-duration}.
8200 @cindex @code{common-shortest-duration}
8201 @cindex @code{base-shortest-duration}
8202 @cindex @code{stem-spacing-correction}
8203 @cindex @code{spacing}
8205 In the introduction it was explained that stem directions influence
8206 spacing. This is controlled with @code{stem-spacing-correction}
8207 property in @internalsref{NoteSpacing}, which are generated for every
8208 @internalsref{Voice} context. The @code{StaffSpacing} object
8209 (generated at @internalsref{Staff} context) contains the same property
8210 for controlling the stem/barline spacing. The following example
8211 shows these corrections, once with default settings, and once with
8212 exaggerated corrections:
8218 \property Staff.NoteSpacing \override #'stem-spacing-correction
8220 \property Staff.StaffSpacing \override #'stem-spacing-correction
8225 \paper { raggedright = ##t } }
8228 @cindex SpacingSpanner, overriding properties
8230 Properties of the @internalsref{SpacingSpanner} must be overridden
8231 from the @code{\paper} block, since the @internalsref{SpacingSpanner} is
8232 created before any @code{\property} statements are interpreted.
8234 \paper @{ \translator @{
8236 SpacingSpanner \override #'spacing-increment = #3.0
8243 @internalsref{SpacingSpanner}, @internalsref{NoteSpacing},
8244 @internalsref{StaffSpacing}, @internalsref{SeparationItem}, and
8245 @internalsref{SeparatingGroupSpanner}.
8249 Spacing is determined on a score wide basis. If you have a score that
8250 changes its character (measured in durations) halfway during the
8251 score, the part containing the longer durations will be spaced too
8254 There is no convenient mechanism to manually override spacing.
8259 @subsection Font size
8260 @cindex font size, setting
8261 @cindex staff size, setting
8262 @cindex @code{paper} file
8264 The Feta font provides musical symbols at seven different sizes.
8265 These fonts are 11 point, 13 point, 16 point, 20 point, 23 point, and
8266 26 point. The point size of a font is the height of the corresponding
8267 staff (excluding line thicknesses).
8269 Definitions for these sizes are the files @file{paperSZ.ly}, where
8270 @code{SZ} is one of 11, 13, 16, 20, 23 and 26. If you include any
8271 of these files, the variables @code{paperEleven},
8272 @code{paperThirteen}, @code{paperSixteen},
8273 @code{paperTwenty}, @code{paperTwentythree}, and @code{paperTwentysix}
8274 are defined respectively. The default @code{\paper} block is also
8275 set. These files should be imported at toplevel, i.e.
8277 \include "paper26.ly"
8281 The default font size settings for each staff heights are generated
8282 from the 20pt style sheet. For more details, see the file
8283 @file{scm/font.scm}.
8287 @subsection Line breaking
8290 @cindex breaking lines
8292 Line breaks are normally computed automatically. They are chosen such
8293 that lines look neither cramped nor loose, and that consecutive lines
8294 have similar density.
8296 Occasionally you might want to override the automatic breaks; you can
8297 do this by specifying @code{\break}. This will force a line break at
8298 this point. Line breaks can only occur at places where there are bar
8299 lines. If you want to have a line break where there is no bar line,
8300 you can force an invisible bar line by entering @code{\bar
8301 ""}. Similarly, @code{\noBreak} forbids a line break at a
8305 @cindex regular line breaks
8306 @cindex four bar music.
8308 For linebreaks at regular intervals use @code{\break} separated by
8309 skips and repeated with @code{\repeat}:
8311 << \repeat unfold 7 @{ s1 * 4 \break @}
8312 @emph{the real music}
8317 This makes the following 28 measures (assuming 4/4 time) be broken every
8322 @internalsref{BreakEvent}.
8326 @subsection Page layout
8329 @cindex breaking pages
8331 @cindex @code{indent}
8332 @cindex @code{linewidth}
8334 The most basic settings influencing the spacing are @code{indent} and
8335 @code{linewidth}. They are set in the @code{\paper} block. They
8336 control the indentation of the first line of music, and the lengths of
8339 If @code{raggedright} is set to true in the @code{\paper}
8340 block, then the lines are justified at their natural length. This
8341 useful for short fragments, and for checking how tight the natural
8345 @cindex vertical spacing
8347 The page layout process happens outside the LilyPond formatting
8348 engine: variables controlling page layout are passed to the output,
8349 and are further interpreted by @code{lilypond} wrapper program. It
8350 responds to the following variables in the @code{\paper} block. The
8351 variable @code{textheight} sets the total height of the music on each
8352 page. The spacing between systems is controlled with
8353 @code{interscoreline}, its default is 16pt. The distance between the
8354 score lines will stretch in order to fill the full page
8355 @code{interscorelinefill} is set to a positive number. In that case
8356 @code{interscoreline} specifies the minimum spacing.
8358 @cindex @code{textheight}
8359 @cindex @code{interscoreline}
8360 @cindex @code{interscorelinefill}
8362 If the variable @code{lastpagefill} is defined,
8363 @c fixme: this should only be done if lastpagefill == #t
8364 systems are evenly distributed vertically on the last page. This
8365 might produce ugly results in case there are not enough systems on the
8366 last page. The @command{lilypond-book} command ignores
8367 @code{lastpagefill}. See @ref{lilypond-book manual} for more
8370 @cindex @code{lastpagefill}
8372 Page breaks are normally computed by @TeX{}, so they are not under
8373 direct control of LilyPond. However, you can insert a commands into
8374 the @file{.tex} output to instruct @TeX{} where to break pages. This
8375 is done by setting the @code{between-systems-strings} on the
8376 @internalsref{NonMusicalPaperColumn} where the system is broken.
8377 An example is shown in @inputfileref{input/regression,between-systems.ly}.
8378 The predefined command @code{\newpage} also does this.
8382 @cindex @code{papersize}
8384 To change the paper size, you must first set the @code{papersize} paper
8385 variable variable as in the example below. Set it to
8386 the strings @code{a4}, @code{letter}, or @code{legal}. After this
8387 specification, you must set the font as described above. If you want
8388 the default font, then use the 20 point font.
8391 \paper@{ papersize = "a4" @}
8392 \include "paper16.ly"
8395 The file @code{paper16.ly} will now include a file named @file{a4.ly}, which
8396 will set the paper variables @code{hsize} and @code{vsize} (used by
8397 @code{lilypond-book} and @code{lilypond}).
8402 @cindex @code{\newpage}
8408 @ref{Invoking lilypond},
8409 @inputfileref{input/regression,between-systems.ly}, and
8410 @internalsref{NonMusicalPaperColumn}.
8414 LilyPond has no concept of page layout, which makes it difficult to
8415 reliably choose page breaks in longer pieces.
8424 Entered music can also be converted to MIDI output. The performance
8425 is good enough for proof-hearing the music for errors.
8427 Ties, dynamics and tempo changes are interpreted. Dynamic marks,
8428 crescendi and decrescendi translate into MIDI volume levels. Dynamic
8429 marks translate to a fixed fraction of the available MIDI volume
8430 range, crescendi and decrescendi make the volume vary linearly between
8431 their two extremities. The fractions can be adjusted by
8432 @code{dynamicAbsoluteVolumeFunction} in @internalsref{Voice} context.
8433 For each type of MIDI instrument, a volume range can be defined. This
8434 gives a basic equalizer control, which can enhance the quality of
8435 the MIDI output remarkably. The equalizer can be controlled by
8436 setting @code{instrumentEqualizer}.
8440 Many musically interesting effects, such as swing, articulation,
8441 slurring, etc., are not translated to MIDI.
8446 * MIDI instrument names::
8451 @subsection MIDI block
8455 The MIDI block is analogous to the paper block, but it is somewhat
8456 simpler. The @code{\midi} block can contain:
8460 @item a @code{\tempo} definition, and
8461 @item context definitions.
8464 Assignments in the @code{\midi} block are not allowed.
8466 A number followed by a period is interpreted as a real number, so
8467 for setting the tempo for dotted notes, an extra space should be
8468 inserted, for example:
8471 \midi @{ \tempo 4 . = 120 @}
8475 @cindex context definition
8477 Context definitions follow precisely the same syntax as within the
8478 \paper block. Translation modules for sound are called performers.
8479 The contexts for MIDI output are defined in @file{ly/performer-init.ly}.
8482 @node MIDI instrument names
8483 @subsection MIDI instrument names
8485 @cindex instrument names
8486 @cindex @code{Staff.midiInstrument}
8487 @cindex @code{Staff.instrument}
8489 The MIDI instrument name is set by the @code{Staff.midiInstrument}
8490 property or, if that property is not set, the @code{Staff.instrument}
8491 property. The instrument name should be chosen from the list in
8492 @ref{MIDI instruments}.
8496 If the selected string does not exactly match, then LilyPond uses the
8497 default (Grand Piano). It is not possible to select an instrument by