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
15 * Easier music entry::
22 * Fingering instructions::
31 * Contemporary notation::
37 @c FIXME: Note entry vs Music entry at top level menu is confusing.
43 This chapter describes all the different types of notation supported
44 by LilyPond. It is intended as a reference for users that are already
45 somewhat familiar with using LilyPond.
51 * Chromatic alterations::
59 * Easy Notation note heads ::
67 A note is printed by specifying its pitch and then its duration:
68 @footnote{Notes constitute the most basic elements of LilyPond input,
69 but they do not form valid input on their own without a @code{\score}
70 block. However, for the sake of brevity and simplicity we will
71 generally omit @code{\score} blocks and @code{\paper} declarations in
74 @lilypond[fragment,verbatim]
83 @cindex Note specification
85 @cindex entering notes
87 The most common syntax for pitch entry is used in @code{\chords} and
88 @code{\notes} mode. In Note and Chord mode, pitches may be designated
89 by names. The notes are specified by the letters @code{a} through
90 @code{g}, while the octave is formed with notes ranging from @code{c}
91 to @code{b}. The pitch @code{c} is an octave below middle C and the
92 letters span the octave above that C:
94 @lilypond[fragment,verbatim]
96 a,4 b, c d e f g a b c' d' e' \clef treble f' g' a' b' c''
99 @cindex note names, Dutch
101 A sharp is formed by adding @code{-is} to the end of a pitch name and
102 a flat is formed by adding @code{-es}. Double sharps and double flats
103 are obtained by adding @code{-isis} or @code{-eses}. These
104 names are the Dutch note names. In Dutch, @code{aes} is contracted to
105 @code{as} in Dutch, but both forms are accepted. Similarly, both
106 @code{es} and @code{ees} are accepted.
108 There are predefined sets of note names for various other languages.
109 To use them, include the language specific init file. For
110 example: @code{\include "english.ly"}. The available language files
111 and the note names they define are:
116 Note Names sharp flat
117 nederlands.ly c d e f g a bes b -is -es
118 english.ly c d e f g a bf b -s/-sharp -f/-flat
120 deutsch.ly c d e f g a b h -is -es
121 norsk.ly c d e f g a b h -iss/-is -ess/-es
122 svenska.ly c d e f g a b h -iss -ess
123 italiano.ly do re mi fa sol la sib si -d -b
124 catalan.ly do re mi fa sol la sib si -d/-s -b
125 espanol.ly do re mi fa sol la sib si -s -b
134 The optional octave specification takes the form of a series of
135 single quote (`@code{'}') characters or a series of comma
136 (`@code{,}') characters. Each @code{'} raises the pitch by one
137 octave; each @code{,} lowers the pitch by an octave:
139 @lilypond[fragment,verbatim,center]
140 c' c'' es' g' as' gisis' ais'
144 There is also a verbose syntax for pitch specification:
147 @cindex @code{\pitch}
149 \pitch @var{scmpitch}
153 where @var{scmpitch} is a Scheme object of the @code{Pitch} type.
157 Notes can be hidden and unhidden with the following commands:
159 @cindex @code{\hideNotes}
161 @cindex @code{\unHideNotes}
168 @internalsref{NoteEvent}, and @internalsref{NoteHead}.
170 @node Chromatic alterations
171 @subsection Chromatic alterations
173 Normally accidentals are printed automatically, but you may also
174 print them manually. A reminder accidental
175 @cindex reminder accidental
177 can be forced by adding an exclamation mark @code{!}
178 after the pitch. A cautionary accidental
179 @cindex cautionary accidental
180 @cindex parenthesized accidental
181 (an accidental within parentheses) can be obtained by adding the
182 question mark `@code{?}' after the pitch:
184 @lilypond[fragment,verbatim]
185 cis' cis' cis'! cis'?
189 The automatic production of accidentals can be tuned in many
190 ways. For more information, refer to @ref{Accidentals}.
195 A chord is formed by a enclosing a set of pitches in @code{<} and
196 @code{>}. A chord may be followed by a duration, and a set of
197 articulations, just like simple notes.
207 Rests are entered like notes, with the note name @code{r}:
209 @lilypond[singleline,verbatim]
213 Whole bar rests, centered in middle of the bar,
214 must be done with multi measure rests. They are discussed in
215 @ref{Multi measure rests}.
218 A rest's vertical position may be explicitly specified by entering a
219 note with the @code{\rest} keyword appended. This makes manual
220 formatting in polyphonic music easier. Rest collision testing will
221 leave these rests alone:
223 @lilypond[singleline,verbatim]
229 @internalsref{RestEvent}, and @internalsref{Rest}.
236 @cindex Invisible rest
239 An invisible rest (also called a `skip') can be entered like a note
240 with note name `@code{s}' or with @code{\skip @var{duration}}:
242 @lilypond[singleline,verbatim]
246 The @code{s} syntax is only available in Note mode and Chord mode. In
247 other situations, you should use the @code{\skip} command:
249 @lilypond[singleline,verbatim]
252 { \time 4/8 \skip 2 \time 4/4 }
253 \notes\relative c'' { a2 a1 }
258 The skip command is merely an empty musical placeholder. It does not
259 produce any output, not even transparent output.
263 @internalsref{SkipEvent}.
268 @subsection Durations
272 @cindex @code{\duration}
275 In Note, Chord, and Lyrics mode, durations are designated by numbers
276 and dots: durations are entered as their reciprocal values. For example,
277 a quarter note is entered using a @code{4} (since it is a 1/4 note), while
278 a half note is entered using a @code{2} (since it is a 1/2 note). For notes
279 longer than a whole you must use variables:
281 @c FIXME: what is an identifier? I do not think it's been introduced yet.
282 @c and if it has, I obviously skipped that part. - Graham
286 c'1 c'2 c'4 c'8 c'16 c'32 c'64 c'64
288 r1 r2 r4 r8 r16 r32 r64 r64
293 \notes \relative c'' {
295 a1 a2 a4 a8 a16 a32 a64 a64
297 r1 r2 r4 r8 r16 r32 r64 r64
302 \remove "Clef_engraver"
303 \remove "Staff_symbol_engraver"
304 \remove "Time_signature_engraver"
305 \consists "Pitch_squash_engraver"
312 If the duration is omitted then it is set to the previously entered
313 duration. The default for the first note is a quarter note. The duration
314 can be followed by dots (`@code{.}') in order to obtain dotted note
318 @lilypond[fragment,verbatim,center]
319 a' b' c''8 b' a'4 a'4. b'4.. c'8.
324 You can alter the length of duration by a fraction @var{N/M}
325 appending `@code{*}@var{N/M}' (or `@code{*}@var{N}' if @var{M=1}). This
326 will not affect the appearance of the notes or rests produced.
327 In the following example, the first three notes take up exactly two
329 @lilypond[fragment,relative 2,verbatim]
331 a4*2/3 gis4*2/3 a4*2/3
335 Durations can also be produced using the verbose syntax
336 @code{\duration @var{Scheme object}}:
337 @lilypond[verbatim,fragment]
338 c'\duration #(ly:make-duration 4 1)
345 Dots are normally moved up to avoid staff lines, except in polyphonic
346 situations. The following commands may be used to force a particular
349 @cindex @code{\dotsUp}
351 @cindex @code{\dotsDown}
353 @cindex @code{\dotsBoth}
358 @internalsref{Dots}, and @internalsref{DotColumn}.
362 In dense chords, dots can overlap.
367 Whenever a note is found, a
368 @internalsref{Stem} object is created automatically. For whole notes
369 and rests, stem objects are also created, but in those cases, the stem
374 @cindex @code{\stemUp}
376 @cindex @code{\stemDown}
378 @cindex @code{\stemBoth}
389 A tie connects two adjacent note heads of the same pitch. The tie in
390 effect extends the length of a note. Ties should not be confused with
391 slurs, which indicate articulation, or phrasing slurs, which indicate
392 musical phrasing. A tie is entered using the tilde symbol `@code{~}':
394 @lilypond[fragment,verbatim,center]
395 e' ~ e' <c' e' g'> ~ <c' e' g'>
398 When a tie is applied to a chord, all note heads whose pitches match
399 are connected. When no note heads match, no ties will be created.
401 In its meaning a tie is just a way of extending a note duration, similar
402 to the augmentation dot; in the following example there are two ways of
403 notating exactly the same concept:
405 @lilypond[fragment, singleline,quote]
406 \time 3/4 c'2. c'2 ~ c'4
408 If you need to tie a lot of notes over bars, it may be easier to use automatic
409 note splitting (See @ref{Automatic note splitting}).
414 @cindex @code{\tieUp}
416 @cindex @code{\tieDown}
418 @cindex @code{\tieBoth}
420 @cindex @code{\tieDotted}
422 @cindex @code{\tieSolid}
427 @internalsref{TieEvent}, @internalsref{NewTieEvent},
428 @internalsref{Tie}, and @ref{Automatic note splitting}.
431 ties created for a chord, see @inputfileref{input/test,tie-sparse.ly}.
435 Tieing only a subset of the note heads of a pair of chords is not
436 supported in a simple way. It can be achieved by moving the
437 tie-engraver into the @internalsref{Thread} context and turning on and
438 off ties per @internalsref{Thread}.
440 Switching staves when a tie is active, will not produce a slanted tie.
442 Formatting of ties is a difficult subject. The results are often not
452 @cindex @code{\times}
454 Tuplets are made out of a music expression by multiplying all durations
457 @cindex @code{\times}
459 \times @var{fraction} @var{musicexpr}
462 The duration of @var{musicexpr} will be multiplied by the fraction.
463 In the sheet music, the fraction's denominator will be printed over
464 the notes, optionally with a bracket. The most common tuplet is the
465 triplet in which 3 notes have the length of 2, so the notes are 2/3
466 of their written length:
468 @lilypond[fragment,verbatim,center]
469 g'4 \times 2/3 {c'4 c' c'} d'4 d'4
472 The property @code{tupletSpannerDuration} specifies how long each
473 bracket should last. With this, you can make lots of tuplets while
474 typing @code{\times} only once, saving lots of typing. In the next
475 example, there are two triplets shown, while @code{\times} was only
478 @lilypond[fragment, relative, singleline, verbatim]
479 \property Voice.tupletSpannerDuration = #(ly:make-moment 1 4)
480 \times 2/3 { c'8 c c c c c }
483 The format of the number is determined by the property
484 @code{tupletNumberFormatFunction}. The default prints only the
485 denominator, but if it is set to the Scheme function
486 @code{fraction-tuplet-formatter}, @var{num}:@var{den} will be printed
490 @cindex @code{tupletNumberFormatFunction}
491 @cindex tuplet formatting
496 @cindex @code{\tupletUp}
498 @cindex @code{\tupletDown}
500 @cindex @code{\tupletBoth}
505 @internalsref{TupletBracket}, and @internalsref{TimeScaledMusic}.
509 Nested tuplets are not formatted automatically. In this case, outer
510 tuplet brackets should be moved manually.
512 @node Easy Notation note heads
513 @subsection Easy Notation note heads
515 @cindex easy notation
518 The `easy play' note head includes a note name inside the head. It is
519 used in music aimed at beginners:
521 @lilypond[singleline,verbatim,26pt]
523 \notes { c'2 e'4 f' | g'1 }
524 \paper { \translator { \EasyNotation } }
528 The @code{EasyNotation} variable overrides a @internalsref{Score} context.
529 You probably will want to print it with magnification or a
530 large font size to make it more readable. To print with
531 magnification, you must create a DVI file (with @file{lilypond}) and
532 then enlarge it with something like @file{dvips -x 2000 file.dvi}.
533 See the @code{dvips} documentation for more details. To print with a
534 larger font, see @ref{Font Size}.
540 If you view the result with Xdvi, then staff lines will show through
541 the letters. Printing the PostScript file obtained does produce the
545 @node Easier music entry
546 @section Easier music entry
549 When entering music it is easy to introduce errors. This section deals
550 with tricks and features of the input language that help when entering
551 music, and find and correct mistakes. Some features of the input
552 language ease entering music, but also have other applications. They
553 are not described in this section.
555 It is also possible to use external programs, for example GUI
556 interfaces, or MIDI transcription programs, to enter or edit
557 music. Refer to the website for more information. Finally, there are
558 tools make debugging easier, by linking the input file and the output
559 shown on screen. See @ref{Point and click} for more information.
566 * Skipping corrected music::
567 * Automatic note splitting ::
573 @node Relative octaves
574 @subsection Relative octaves
576 @cindex relative octave specification
578 Octaves are specified by adding @code{'} and @code{,} to pitch names.
579 When you copy existing music, it is easy to accidentally put a pitch
580 in the wrong octave and hard to find such an error. The relative
581 octave mode prevents these errors: a single error puts the rest of the
582 piece off by one octave:
584 @cindex @code{\relative}
586 \relative @var{startpitch} @var{musicexpr}
589 The octave of notes that appear in @var{musicexpr} are calculated as
590 follows: If no octave changing marks are used, the basic interval
591 between this and the last note is always taken to be a fourth or less
592 (; this distance is determined without regarding alterations: a
593 @code{fisis} following a @code{ceses} will be put above the
596 The octave changing marks @code{'} and @code{,} can be added to raise
597 or lower the pitch by an extra octave. Upon entering relative mode,
598 an absolute starting pitch must be specified that will act as the
599 predecessor of the first note of @var{musicexpr}.
601 Here is the relative mode shown in action:
602 @lilypond[fragment,singleline,verbatim,center]
608 Octave changing marks are used for intervals greater than a fourth:
609 @lilypond[fragment,verbatim,center]
614 If the preceding item is a chord, the first note of the chord is used
615 to determine the first note of the next chord:
617 @lilypond[fragment,verbatim,center]
624 @cindex @code{\notes}
626 The pitch after the @code{\relative} contains a note name. To parse
627 the pitch as a note name, you have to be in note mode, so there must
628 be a surrounding @code{\notes} keyword (which is not
631 The relative conversion will not affect @code{\transpose},
632 @code{\chords} or @code{\relative} sections in its argument. If you
633 want to use relative within transposed music, you must place an
634 additional @code{\relative} inside the @code{\transpose}.
637 @subsection Octave check
640 Octave checks make octave errors easier to correct.
646 This checks that @var{pitch} (without octave) yields @var{pitch} (with
647 octave) in \relative mode. If not, a warning is printed, and the
648 octave is corrected, for example, the first check is passed
649 successfully. The second check fails with an error message. The
650 octave is adjusted so the following notes are in the correct octave
661 The octave of a note following an octave check is determined with
662 respect to the note preceding it. In the next fragment, the last note
663 is a @code{a'}, above central C. Hence, the @code{\octave} check may
664 be deleted without changing the meaning of the piece.
666 @lilypond[verbatim,fragment]
677 @subsection Bar check
681 @cindex @code{barCheckSynchronize}
684 Bar checks help detect errors in the durations. A bar check is
685 entered using the bar symbol, `@code{|}'. Whenever it is encountered
686 during interpretation, it should fall on a measure boundary. If it
687 does not, a warning is printed. Depending on the value of
688 @code{barCheckSynchronize}, the beginning of the measure will be
691 In the next example, the second bar check will signal an error:
693 \time 3/4 c2 e4 | g2 |
698 @cindex skipTypesetting
700 Failed bar checks are caused by entering incorrect
701 durations. Incorrect durations often completely garble up the score,
702 especially if it is polyphonic, so you should start correcting the
703 score by scanning for failed bar checks and incorrect durations. To
704 speed up this process, you can use @code{skipTypesetting}, described
707 @node Skipping corrected music
708 @subsection Skipping corrected music
710 The property @code{Score.skipTypesetting} can be used to switch on and
711 off typesetting completely during the interpretation phase. When
712 typesetting is switched off, the music is processed much more quickly.
713 This can be used to skip over the parts of a score that have already
714 been checked for errors:
716 @lilypond[fragment,singleline,verbatim]
718 \property Score.skipTypesetting = ##t
720 \property Score.skipTypesetting = ##f
724 @node Automatic note splitting
725 @subsection Automatic note splitting
727 Long notes can be converted automatically to tied notes. This is done
728 by replacing the @internalsref{Note_heads_engraver} by the
729 @internalsref{Completion_heads_engraver}:
732 \paper @{ \translator @{
734 \remove "Note_heads_engraver"
735 \consists "Completion_heads_engraver"
739 which will make long notes tied in the following example:
742 c2. c8 d4 e f g a b c8 c2 b4 a g16 f4 e d c8. c2
749 c2. c8 d4 e f g a b c8 c2 b4 a g16 f4 e d c8. c2
751 \paper { \translator {
753 \remove "Note_heads_engraver"
754 \consists "Completion_heads_engraver"
759 This engraver splits all running notes at the bar line, and inserts
760 ties. One of its uses is to debug complex scores: if the measures are
761 not entirely filled, then the ties exactly show how much each measure
766 Not all durations (especially those containing tuplets) can be
767 represented exactly; the engraver will not insert tuplets.
773 @section Staff notation
775 This section describes music notation that occurs on staff level,
776 such as keys, clefs and time signatures.
778 @cindex Staff notation
792 @subsection Staff symbol
794 @cindex adjusting staff symbol
795 @cindex StaffSymbol, using \property
797 Notes, dynamic signs, etc. are grouped
798 with a set of horizontal lines, into a staff (plural `staves'). In our
799 system, these lines are drawn using a separate layout object called
803 @cindex staff lines, setting number of
804 @cindex staff lines, setting thickness of
805 @cindex thickness of staff lines, setting
806 @cindex number of staff lines, setting
808 This object is created whenever a @internalsref{Staff} context is
809 created. The appearance of the staff symbol cannot be changed by
810 using @code{\override} or @code{\set}. At the moment that
811 @code{\property Staff} is interpreted, a @internalsref{Staff} context
812 is made, and the @internalsref{StaffSymbol} is created before any
813 @code{\override} is effective. Properties can be changed in a
814 @code{\translator} definition, or by using @code{\outputproperty}.
818 If a staff is ended halfway a piece, the staff symbol may not end
819 exactly on the barline.
823 @subsection Key signature
824 @cindex Key signature
828 The key signature indicates the scale in which a piece is played. It
829 is denoted by a set of alterations (flats or sharps) at the start of
832 WARNING! The key signature only changes the output, not the music
833 itself. An F-sharp in the key of D major is still an F-sharp, not
834 an F -- you must type @code{fis}, not @code{f}. If you don't modify
835 a pitch with @code{-is} or @code{-es}, LilyPond will assume that
836 you want a natural note. See this example:
847 \score{ \notes { \relative c'{
857 Setting or changing the key signature is done with the @code{\key}
860 @code{\key} @var{pitch} @var{type}
863 @cindex @code{\minor}
864 @cindex @code{\major}
865 @cindex @code{\minor}
866 @cindex @code{\ionian}
867 @cindex @code{\locrian}
868 @cindex @code{\aeolian}
869 @cindex @code{\mixolydian}
870 @cindex @code{\lydian}
871 @cindex @code{\phrygian}
872 @cindex @code{\dorian}
874 Here, @var{type} should be @code{\major} or @code{\minor} to get
875 @var{pitch}-major or @var{pitch}-minor, respectively.
876 The standard mode names @code{\ionian},
877 @code{\locrian}, @code{\aeolian}, @code{\mixolydian}, @code{\lydian},
878 @code{\phrygian}, and @code{\dorian} are also defined.
880 This command sets the context property
881 @internalsref{Staff}.@code{keySignature}. Non-standard key signatures
882 can be specified by setting this property directly.
886 The ordering of a key cancellation is wrong when it is combined with
887 repeat bar lines. The cancellation is also printed after a line break.
891 @internalsref{KeyChangeEvent}, and @internalsref{KeySignature}.
893 @cindex @code{keySignature}
900 The clef indicates which lines of the staff correspond to which
905 The clef can be set or changed with the @code{\clef} command:
906 @lilypond[fragment,verbatim]
907 \key f\major c''2 \clef alto g'2
910 Supported clef-names include:
911 @c Moved standard clefs to the top /MB
915 @item treble, violin, G, G2
928 G clef on 1st line, so-called French violin clef
933 @cindex mezzosoprano clef
936 @cindex baritone clef
939 @cindex varbaritone clef
948 By adding @code{_8} or @code{^8} to the clef name, the clef is
949 transposed one octave down or up, respectively. Argument @var{clefname}
950 must be enclosed in quotes when it contains underscores or digits. For
954 @cindex choral tenor clef
955 @lilypond[verbatim,fragment,relative]
959 This command is equivalent to setting @code{clefGlyph},
960 @code{clefPosition} (which controls the Y position of the clef),
961 @code{centralCPosition} and @code{clefOctavation}. A clef is printed
962 when any of these properties are changed.
966 The object for this symbol is @internalsref{Clef}.
970 @node Ottava brackets
971 @subsection Ottava brackets
973 ``Ottava'' brackets introduce an extra transposition of an octave for
974 the staff. They are created by invoking the function
975 @code{set-octavation}:
981 @lilypond[verbatim,fragment]
990 Internally the @code{set-octavation} function sets the properties
991 @code{ottavation} (eg. to @code{"8va"}) and @code{centralCPosition}.
995 @internalsref{OttavaSpanner}.
999 @code{set-octavation} will get confused when clef changes happen
1000 during an octavation bracket.
1002 @node Time signature
1003 @subsection Time signature
1004 @cindex Time signature
1006 @cindex @code{\time}
1008 Time signature indicates the metrum of a piece: a regular pattern of
1009 strong and weak beats. It is denoted by a fraction at the start of the
1014 The time signature is set or changed by the @code{\time}
1016 @lilypond[fragment,verbatim]
1017 \time 2/4 c'2 \time 3/4 c'2.
1020 The symbol that is printed can be customized with the @code{style}
1021 property. Setting it to @code{#'()} uses fraction style for 4/4 and
1022 2/2 time. There are many more options for its layout. See
1023 @inputfileref{input/test,time.ly} for more examples.
1026 This command sets the property @code{timeSignatureFraction},
1027 @code{beatLength} and @code{measureLength} in the @code{Timing}
1028 context, which is normally aliased to @internalsref{Score}. The
1029 property @code{measureLength} determines where bar lines should be
1030 inserted, and how automatic beams should be generated. Changing the
1031 value of @code{timeSignatureFraction} also causes the symbol to be
1034 More options are available through the Scheme function
1035 @code{set-time-signature}. In combination with the
1036 @internalsref{Measure_grouping_engraver}, it will create
1037 @internalsref{MeasureGrouping} signs. Such signs ease reading
1038 rhythmically complex modern music. In the following example, the 9/8
1039 measure is subdivided in 2, 2, 2 and 3. This is passed to
1040 @code{set-time-signature} as the third argument @code{(2 2 2 3)}:
1043 \score { \notes \relative c'' {
1044 #(set-time-signature 9 8 '(2 2 2 3))
1045 g8[ g] d[ d] g[ g] a8[( bes g]) |
1046 #(set-time-signature 5 8 '(3 2))
1051 \translator { \StaffContext
1052 \consists "Measure_grouping_engraver"
1058 @internalsref{TimeSignature}, and @internalsref{Timing_engraver}.
1063 Automatic beaming does not use measure grouping specified with
1064 @code{set-time-signature}.
1066 @node Partial measures
1067 @subsection Partial measures
1070 @cindex partial measure
1071 @cindex measure, partial
1072 @cindex shorten measures
1073 @cindex @code{\partial}
1075 Partial measures, for example in upsteps, are entered using the
1076 @code{\partial} command:
1077 @lilypond[fragment,verbatim]
1078 \partial 16*5 c'16 c4 | a'2. ~ a'8. a'16 | g'1
1081 The syntax for this command is
1083 \partial @var{duration}
1085 This is internally translated into
1087 \property Timing.measurePosition = -@var{length of duration}
1090 The property @code{measurePosition} contains a rational number
1091 indicating how much of the measure has passed at this point.
1093 @node Unmetered music
1094 @subsection Unmetered music
1096 Bar lines and bar numbers are calculated automatically. For unmetered
1097 music (e.g. cadenzas), this is not desirable. By setting
1098 @code{Score.timing} to false, this automatic timing can be switched
1104 @cindex @code{\cadenzaOn}
1106 @cindex @code{\cadenzaOff}
1110 @subsection Bar lines
1114 @cindex measure lines
1118 Bar lines delimit measures, but are also used to indicate repeats.
1119 Normally, they are inserted automatically. Line breaks may only
1125 of barlines can be forced with the @code{\bar} command:
1126 @lilypond[relative=1,fragment,verbatim]
1130 The following bar types are available:
1131 @lilypond[fragment, relative, singleline, verbatim]
1143 In scores with many staves, a @code{\bar} command in one staff is
1144 automatically applied to all staves. The resulting bar lines are
1145 connected between different staves of a @internalsref{StaffGroup}:
1147 @lilypond[fragment, verbatim]
1148 << \context StaffGroup <<
1152 \new Staff { \clef bass c4 g e g } >>
1153 \new Staff { \clef bass c2 c2 } >>
1157 The command @code{\bar @var{bartype}} is a short cut for doing
1158 @code{\property Score.whichBar = @var{bartype}} Whenever
1159 @code{whichBar} is set to a string, a bar line of that type is
1160 created. At the start of a measure it is set to
1161 @code{defaultBarType}. The contents of @code{repeatCommands} are used
1162 to override default measure bars.
1164 Property @code{whichBar} can also be set directly, using @code{\property}
1165 or @code{\bar}. These settings take precedence over the automatic
1166 @code{whichBar} settings.
1169 @cindex repeatCommands
1170 @cindex defaultBarType
1172 You are encouraged to use @code{\repeat} for repetitions. See
1182 The bar line objects that are created at @internalsref{Staff} level
1183 are called @internalsref{BarLine}, the bar lines that span staves are
1184 @internalsref{SpanBar}s.
1186 @cindex bar lines at start of system
1187 @cindex start of system
1189 The barlines at the start of each system are
1190 @internalsref{SystemStartBar}, @internalsref{SystemStartBrace}, and
1191 @internalsref{SystemStartBracket}. They are spanner objects and
1192 typically must be tuned from a @code{\translator} block.
1199 The easiest way to enter fragments with more than one voice on a staff
1200 is to split chords using the separator @code{\\}. You can use it for
1201 small, short-lived voices or for single chords:
1203 @lilypond[verbatim,fragment]
1204 \context Staff \relative c'' {
1205 c4 << { f d e } \\ { b c2 } >> c4 << g' \\ b, \\ f' \\ d >>
1209 The separator causes @internalsref{Voice} contexts to be
1211 bear the names @code{"1"}, @code{"2"}, etc. In each of these
1212 contexts, vertical direction of slurs, stems, etc. is set
1215 This can also be done by instantiating @internalsref{Voice} contexts
1216 by hand, and using @code{\voiceOne}, up to @code{\voiceFour} to assign
1217 a stem directions and horizontal shift for each part:
1220 @lilypond[singleline, verbatim]
1222 \context Staff << \new Voice { \voiceOne cis2 b }
1223 \new Voice { \voiceThree b4 ais ~ ais4 gis4 }
1224 \new Voice { \voiceTwo fis4~ fis4 f ~ f } >>
1227 Normally, note heads with a different number of dots are not merged, but
1228 when the object property @code{merge-differently-dotted} is set in
1229 the @internalsref{NoteCollision} object, they are merged:
1230 @lilypond[verbatim,fragment,singleline]
1231 \relative c'' \context Voice << {
1233 \property Staff.NoteCollision \override
1234 #'merge-differently-dotted = ##t
1236 } \\ { g8.[ f16] g8.[ f16] }
1240 Similarly, you can merge half note heads with eighth notes, by setting
1241 @code{merge-differently-headed}:
1242 @lilypond[fragment, relative=2,verbatim]
1245 \property Staff.NoteCollision
1246 \override #'merge-differently-headed = ##t
1247 c8 c4. } \\ { c2 c2 } >>
1250 LilyPond also vertically shifts rests that are opposite of a stem:
1253 @lilypond[singleline,fragment,verbatim]
1254 \context Voice << c''4 \\ r4 >>
1262 @cindex @code{\oneVoice}
1264 @cindex @code{\voiceOne}
1266 @cindex @code{\voiceTwo}
1268 @cindex @code{\voiceThree}
1270 @cindex @code{\voiceFour}
1273 The following commands specify in what chords of the current voice
1274 should be shifted: the outer voice has @code{\shiftOff}, and the inner
1275 voices have @code{\shiftOn}, @code{\shiftOnn}, etc.
1278 @cindex @code{\shiftOn}
1280 @cindex @code{\shiftOnn}
1282 @cindex @code{\shiftOnnn}
1284 @cindex @code{\shiftOff}
1291 The objects responsible for resolving collisions are
1292 @internalsref{NoteCollision} and @internalsref{RestCollision}. See
1293 also example files @inputfileref{input/regression,collision-dots.ly},
1294 @inputfileref{input/regression,collision-head-chords.ly},
1295 @inputfileref{input/regression,collision-heads.ly},
1296 @inputfileref{input/regression,collision-mesh.ly}, and
1297 @inputfileref{input/regression,collisions.ly}.
1302 Resolving collisions is a intricate subject, and only a few situations
1303 are handled. When LilyPond cannot cope, the @code{force-hshift}
1304 property of the @internalsref{NoteColumn} object and pitched rests can
1305 be used to override typesetting decisions.
1307 When using @code{merge-differently-headed} with an upstem 8th or a shorter
1308 note, and a downstem half note, the 8th note gets the wrong offset.
1313 Beams are used to group short notes into chunks that are aligned with
1314 the metrum. They are inserted automatically in most cases:
1316 @lilypond[fragment,verbatim, relative=2]
1317 \time 2/4 c8 c c c \time 6/8 c c c c8. c16 c8
1320 When these automatic decisions are not good enough, beaming can be
1321 entered explicitly. It is also possible to define beaming patterns
1322 that differ from the defaults.
1326 @internalsref{Beam}.
1329 @cindex Automatic beams
1330 @subsection Manual beams
1331 @cindex beams, manual
1335 In some cases it may be necessary to override the automatic beaming
1336 algorithm. For example, the auto beamer will not put beams over rests
1337 or bar lines. Such beams are specified by manually: the begin and end
1338 point are marked with @code{[} and @code{]}:
1340 @lilypond[fragment,relative,verbatim]
1342 r4 r8[ g' a r8] r8 g[ | a] r8
1346 @cindex @code{stemLeftBeamCount}
1348 Normally, beaming patterns within a beam are determined automatically.
1349 When this mechanism fouls up, the properties
1350 @code{Voice.stemLeftBeamCount} and @code{Voice.stemRightBeamCount} can
1351 be used to control the beam subdivision on a stem. If either property
1352 is set, its value will be used only once, and then it is erased.
1354 @lilypond[fragment,relative,verbatim]
1357 f8[ r16 \property Voice.stemLeftBeamCount = #1 f g a]
1360 @cindex @code{stemRightBeamCount}
1363 The property @code{subdivideBeams} can be set in order to subdivide
1364 all 16th or shorter beams at beat positions, as defined by the
1365 @code{beatLength} property . This accomplishes the same effect as
1366 twiddling with @code{stemLeftBeamCount} and @code{stemRightBeamCount},
1367 but it take less typing:
1370 @lilypond[relative=1,verbatim,noindent]
1372 \property Voice.subdivideBeams = ##t
1374 \property Score.beatLength = #(ly:make-moment 1 8)
1377 @cindex subdivideBeams
1379 Kneed beams are inserted automatically, when a large gap is detected
1380 between the note heads. This behavior can be tuned through the object
1381 property @code{auto-knee-gap}.
1383 Normally, line breaks are forbidden when beams cross bar lines. This
1384 behavior can be changed by setting @code{allowBeamBreak}.
1386 @cindex @code{allowBeamBreak}
1387 @cindex beams and line breaks
1389 @cindex beams, kneed
1391 @cindex auto-knee-gap
1397 @cindex Frenched staves
1399 Automatically kneed beams cannot be used together with hidden staves.
1404 * Setting automatic beam behavior ::
1408 @no de Beam typography
1409 @sub section Beam typography
1411 One of the strong points of LilyPond is how beams are formatted. Beams
1412 are quantized, meaning that the left and right endpoints beams start
1413 exactly on staff lines. Without quantization, small wedges of white
1414 space appear between the beam and staff line, and this looks untidy.
1416 Beams are also slope-damped: melodies that go up or down should also
1417 have beams that go up or down, but the slope of the beams should be
1418 less than the slope of the notes themselves.
1420 Some beams should be horizontal. These are so-called concave beams.
1422 [TODO: some pictures.]
1426 @node Setting automatic beam behavior
1427 @subsection Setting automatic beam behavior
1429 @cindex @code{autoBeamSettings}
1430 @cindex @code{(end * * * *)}
1431 @cindex @code{(begin * * * *)}
1432 @cindex automatic beams, tuning
1433 @cindex tuning automatic beaming
1435 @c [TODO: use \applycontext]
1437 In normal time signatures, automatic beams can start on any note but can
1438 only end in a few positions within the measure: beams can end on a beat,
1439 or at durations specified by the properties in
1440 @code{Voice.autoBeamSettings}. The defaults for @code{autoBeamSettings}
1441 are defined in @file{scm/auto-beam.scm}.
1443 The value of @code{autoBeamSettings} is changed using
1444 @code{\override} and restored with @code{\revert}:
1446 \property Voice.autoBeamSettings \override #'(@var{BE} @var{P} @var{Q} @var{N} @var{M}) = @var{dur}
1447 \property Voice.autoBeamSettings \revert #'(@var{BE} @var{P} @var{Q} @var{N} @var{M})
1449 Here, @var{BE} is the symbol @code{begin} or @code{end}. It determines
1450 whether the rule applies to begin or end-points. The quantity
1451 @var{P}/@var{Q} refers to the length of the beamed notes (and `@code{*
1452 *}' designates notes of any length), @var{N}/@var{M} refers to a time
1453 signature (wildcards, `@code{* *}' may be entered to designate all time
1456 For example, if automatic beams should end on every quarter note, use
1459 \property Voice.autoBeamSettings \override
1460 #'(end * * * *) = #(ly:make-moment 1 4)
1462 Since the duration of a quarter note is 1/4 of a whole note, it is
1463 entered as @code{(ly:make-moment 1 4)}.
1465 The same syntax can be used to specify beam starting points. In this
1466 example, automatic beams can only end on a dotted quarter note:
1468 \property Voice.autoBeamSettings \override
1469 #'(end * * * *) = #(ly:make-moment 3 8)
1471 In 4/4 time signature, this means that automatic beams could end only on
1472 3/8 and on the fourth beat of the measure (after 3/4, that is 2 times
1473 3/8 has passed within the measure).
1475 Rules can also be restricted to specific time signatures. A rule that
1476 should only be applied in @var{N}/@var{M} time signature is formed by
1477 replacing the second asterisks by @var{N} and @var{M}. For example, a
1478 rule for 6/8 time exclusively looks like
1480 \property Voice.autoBeamSettings \override
1481 #'(begin * * 6 8) = ...
1484 If a rule should be to applied only to certain types of beams, use the
1485 first pair of asterisks. Beams are classified according to the
1486 shortest note they contain. For a beam ending rule that only applies
1487 to beams with 32nd notes (and no shorter notes), use @code{(end 1 32 *
1490 If a score ends while an automatic beam has not been ended and is still
1491 accepting notes, this last beam will not be typeset at all.
1493 @cindex automatic beam generation
1495 @cindex @code{Voice.autoBeaming}
1498 For melodies that have lyrics, you may want to switch off
1499 automatic beaming. This is done by setting @code{Voice.autoBeaming} to
1504 @cindex @code{\autoBeamOff}
1505 @code{\autoBeamOff},
1506 @cindex @code{\autoBeamOn}
1512 The rules for ending a beam depend on the shortest note in a beam.
1513 So, while it is possible to have different ending rules for eight
1514 beams and sixteenth beams, a beam that contains both eight and
1515 sixteenth notes will use the rules for the sixteenth beam.
1517 In the example below, the autobeamer makes eight beams and sixteenth
1518 end at 3 eights; the third beam can only be corrected by specifying
1521 @lilypond[singleline,fragment,relative,noverbatim,quote]
1522 \property Voice.autoBeamSettings
1523 \override #'(end * * * *) = #(ly:make-moment 3 8)
1524 % rather show case where it goes wrong
1525 %\time 12/8 c'8 c c c16 c c c c c c[ c c c] c8[ c] c4
1526 \time 12/8 c'8 c c c16 c c c c c c c c c c8 c c4
1528 It is not possible to specify beaming parameters that act differently in
1529 different parts of a measure. This means that it is not possible to use
1530 automatic beaming in irregular meters such as @code{5/8}.
1533 @section Accidentals
1536 This section describes how to change the way that accidentals are
1537 inserted automatically before the running notes.
1541 * Using the predefined accidental variables::
1542 * Customized accidental rules::
1545 @node Using the predefined accidental variables
1546 @subsection Using the predefined accidental variables
1548 The constructs for describing the accidental typesetting rules are
1549 quite hairy, so non-experts should stick to the variables
1550 defined in @file{ly/property-init.ly}.
1551 @cindex @file{property-init.ly}
1553 The variables set properties in the ``@code{Current}'' context (see
1554 @ref{Context properties}). This means that the variables should
1555 normally be added right after the creation of the context in which the
1556 accidental typesetting described by the variable is to take
1557 effect. For example, if you want to use piano-accidentals in a piano
1558 staff then issue @code{\pianoAccidentals} first thing after the
1559 creation of the piano staff:
1562 \notes \relative c'' <<
1563 \new Staff @{ cis4 d e2 @}
1564 \context GrandStaff <<
1566 \new Staff @{ cis4 d e2 @}
1567 \new Staff @{ es2 c @}
1569 \new Staff @{ es2 c @}
1573 @lilypond[singleline]
1575 \notes \relative c'' <<
1576 \new Staff { cis4 d e2 }
1577 \context GrandStaff <<
1579 \new Staff { cis4 d e2 }
1580 \new Staff { es2 c }
1582 \new Staff { es2 c }
1587 minimumVerticalExtent = #'(-4.0 . 4.0)
1595 @item \defaultAccidentals
1596 @cindex @code{\defaultAccidentals}
1597 This is the default typesetting behaviour. It should correspond
1598 to 18th century common practice: Accidentals are
1599 remembered to the end of the measure in which they occur and
1600 only on their own octave.
1602 @item \voiceAccidentals
1603 @cindex @code{\voiceAccidentals}
1605 The normal behaviour is to
1606 remember the accidentals on Staff-level. This variable, however,
1607 typesets accidentals individually for each voice. Apart from that the
1608 rule is similar to @code{\defaultAccidentals}.
1610 This leads to some weird and often unwanted results
1611 because accidentals from one voice do not get cancelled in other
1613 @lilypond[singleline,relative,fragment,verbatim,quote]
1621 Hence you should only use @code{\voiceAccidentals} if the voices
1622 are to be read solely by individual musicians. If the staff is to be
1623 used by one musician (e.g. a conductor) then you use
1624 @code{\modernVoiceAccidentals} or @code{\modernVoiceCautionaries}
1627 @item \modernAccidentals
1628 @cindex @code{\modernAccidentals}
1629 This rule corresponds to the common practice in the 20th
1631 The rule is more complex than @code{\defaultAccidentals}.
1632 You get all the same accidentals, but temporary
1633 accidentals also get cancelled in other octaves. Furthermore,
1634 in the same octave, they also get cancelled in the following measure:
1635 @lilypond[singleline,fragment,verbatim]
1637 cis' c'' cis'2 | c'' c'
1640 @item \modernCautionaries
1641 @cindex @code{\modernCautionaries}
1642 This rule is similar to @code{\modernAccidentals}, but the
1643 ``extra'' accidentals (the ones not typeset by
1644 @code{\defaultAccidentals}) are typeset as cautionary accidentals.
1645 They are printed in reduced size or with parentheses:
1646 @lilypond[singleline,fragment,verbatim]
1648 cis' c'' cis'2 | c'' c'
1651 @cindex @code{\modernVoiceAccidentals}
1652 @item \modernVoiceAccidentals
1653 is used for multivoice accidentals to be read both by musicians
1654 playing one voice and musicians playing all voices. Accidentals are
1655 typeset for each voice, but they @emph{are} cancelled across voices in
1656 the same @internalsref{Staff}.
1658 @cindex @code{\modernVoiceCautionaries}
1659 @item \modernVoiceCautionaries
1660 is the same as @code{\modernVoiceAccidentals}, but with the extra
1661 accidentals (the ones not typeset by @code{\voiceAccidentals}) typeset
1662 as cautionaries. Even though all accidentals typeset by
1663 @code{\defaultAccidentals} @emph{are} typeset by this variable then
1664 some of them are typeset as cautionaries.
1666 @item \pianoAccidentals
1667 @cindex @code{\pianoAccidentals}
1668 20th century practice for piano notation. Very similar to
1669 @code{\modernAccidentals} but accidentals also get cancelled
1670 across the staves in the same @internalsref{GrandStaff} or
1671 @internalsref{PianoStaff}.
1673 @item \pianoCautionaries
1674 @cindex @code{\pianoCautionaries}
1675 As @code{\pianoAccidentals} but with the extra accidentals
1676 typeset as cautionaries.
1679 @cindex @code{\noResetKey}
1680 Same as @code{\defaultAccidentals} but with accidentals lasting
1681 ``forever'' and not only until the next measure:
1682 @lilypond[singleline,fragment,verbatim,relative]
1687 @item \forgetAccidentals
1688 @cindex @code{\forgetAccidentals}
1689 This is sort of the opposite of @code{\noResetKey}: Accidentals
1690 are not remembered at all---and hence all accidentals are
1691 typeset relative to the key signature, regardless of what was
1692 before in the music:
1693 @lilypond[singleline,fragment,verbatim,relative]
1695 \key d\major c4 c cis cis d d dis dis
1699 @node Customized accidental rules
1700 @subsection Customized accidental rules
1702 This section must be considered gurus-only, and hence it must be
1703 sufficient with a short description of the system and a reference to
1704 the internal documentation.
1706 The algorithm tries several different rules, and uses the rule
1707 that gives the highest number of accidentals. Each rule consists of
1710 In which context is the rule applied. For example, if
1711 @var{context} is @internalsref{Score} then all staves share
1712 accidentals, and if @var{context} is @internalsref{Staff} then all
1713 voices in the same staff share accidentals, but staves do not.
1715 Whether the accidental changes all octaves or only the current
1718 Over how many barlines the accidental lasts.
1719 If @var{lazyness} is @code{-1} then the accidental is forget
1720 immediately, and if @var{lazyness} is @code{#t} then the accidental
1723 @c [TODO: should use +infinity for this case?]
1729 @cindex @code{\defaultAccidentals}
1730 @code{\defaultAccidentals},
1731 @cindex @code{\voiceAccidentals}
1732 @code{\voiceAccidentals},
1733 @cindex @code{\modernAccidentals}
1734 @code{\modernAccidentals},
1735 @cindex @code{\modernCautionaries}
1736 @code{\modernCautionaries},
1737 @cindex @code{\modernVoiceAccidentals}
1738 @code{\modernVoiceAccidentals},
1739 @cindex @code{\modernVoiceCautionaries}
1740 @code{\modernVoiceCautionaries},
1741 @cindex @code{\pianoAccidentals}
1742 @code{\pianoAccidentals},
1743 @cindex @code{\pianoCautionaries}
1744 @code{\pianoCautionaries},
1745 @cindex @code{\noResetKey}
1747 @cindex @code{\forgetAccidentals}
1748 @code{\forgetAccidentals}.
1752 @internalsref{Accidental_engraver}, @internalsref{Accidental}, and
1753 @internalsref{AccidentalPlacement}.
1758 Currently the simultaneous notes are considered to be entered in
1759 sequential mode. This means that in a chord the accidentals are
1760 typeset as if the notes in the chord happened once at a time - in the
1761 order in which they appear in the input file.
1763 This is only a problem when there are simultaneous notes whose
1764 accidentals depend on each other. The problem only occurs when using
1765 non-default accidentals. In the default scheme, accidentals only
1766 depend on other accidentals with the same pitch on the same staff, so
1767 no conflicts possible.
1769 This example shows two examples of the same music giving different
1770 accidentals depending on the order in which the notes occur in the
1773 @lilypond[singleline,fragment,verbatim]
1774 \property Staff.autoAccidentals = #'( Staff (any-octave . 0) )
1775 cis'4 <c'' c'> r2 | cis'4 <c' c''> r2
1776 | <cis' c''> r | <c'' cis'> r |
1779 This problem can be solved by manually inserting @code{!} and @code{?}
1780 for the problematic notes.
1782 @node Expressive marks
1783 @section Expressive marks
1791 * Analysis brackets::
1798 A slur indicates that notes are to be played bound or @emph{legato}.
1802 They are entered using parentheses:
1803 @lilypond[fragment,verbatim,center]
1804 f'( g')( a') a'8[ b'(] a'4 g'2 f'4)
1809 @c TODO: should explain that ^( and _( set directions
1810 @c should set attachments with ^ and _ ?
1812 Slurs avoid crossing stems, and are generally attached to note heads.
1813 However, in some situations with beams, slurs may be attached to stem
1814 ends. If you want to override this layout you can do this through the
1815 object property @code{attachment} of @internalsref{Slur} in
1816 @internalsref{Voice} context. Its value is a pair of symbols, specifying
1817 the attachment type of the left and right end points:
1819 @lilypond[fragment,relative,verbatim]
1821 \property Voice.Stem \set #'length = #5.5
1823 \property Voice.Slur \set #'attachment = #'(stem . stem)
1827 If a slur would strike through a stem or beam, the slur will be moved
1828 away upward or downward. If this happens, attaching the slur to the
1829 stems might look better:
1831 @lilypond[fragment,relative,verbatim]
1834 \property Voice.Slur \set #'attachment = #'(stem . stem)
1841 @cindex @code{\slurUp}
1843 @cindex @code{\slurDown}
1845 @cindex @code{\slurBoth}
1847 @cindex @code{\slurDotted}
1849 @cindex @code{\slurSolid}
1854 @seeinternals{Slur}, and @internalsref{SlurEvent}.
1859 Producing nice slurs is a difficult problem, and LilyPond currently
1860 uses a simple, empiric method to produce slurs. In some cases, its
1864 @cindex Adjusting slurs
1866 @node Phrasing slurs
1867 @subsection Phrasing slurs
1869 @cindex phrasing slurs
1870 @cindex phrasing marks
1872 A phrasing slur (or phrasing mark) connects chords and is used to
1873 indicate a musical sentence. It is started using @code{\(} and @code{\)}
1876 @lilypond[fragment,verbatim,center,relative]
1877 \time 6/4 c'\( d( e) f( e) d\)
1880 Typographically, the phrasing slur behaves almost exactly like a
1881 normal slur. However, they are treated as different objects. A
1882 @code{\slurUp} will have no effect on a phrasing slur; instead, you
1883 should use @code{\phrasingSlurUp}, @code{\phrasingSlurDown}, and
1884 @code{\phrasingSlurBoth}.
1886 The commands @code{\slurUp}, @code{\slurDown}, and @code{\slurBoth}
1887 will only affect normal slurs and not phrasing slurs.
1891 @cindex @code{\phrasingSlurUp}
1892 @code{\phrasingSlurUp},
1893 @cindex @code{\phrasingSlurDown}
1894 @code{\phrasingSlurDown},
1895 @cindex @code{\phrasingSlurBoth}
1896 @code{\phrasingSlurBoth},
1900 See also @internalsref{PhrasingSlur}, and
1901 @internalsref{PhrasingSlurEvent}.
1905 Phrasing slurs have the same limitations in their formatting as normal
1906 slurs. Putting phrasing slurs over rests leads to spurious warnings.
1909 @subsection Breath marks
1911 Breath marks are entered using @code{\breathe}:
1914 @lilypond[fragment,relative,verbatim]
1918 The glyph of the breath mark can be tweaked by overriding the
1919 @code{text} property of the @code{BreathingSign} layout object with
1920 any markup text. For example,
1921 @lilypond[fragment,verbatim,relative]
1923 \property Voice.BreathingSign \override #'text
1924 = #(make-musicglyph-markup "scripts-rvarcomma")
1931 @internalsref{BreathingSign}, @internalsref{BreathingSignEvent}, and
1932 @inputfileref{input/regression,breathing-sign.ly}.
1935 @node Metronome marks
1936 @subsection Metronome marks
1939 @cindex beats per minute
1940 @cindex metronome marking
1942 Metronome settings can be entered as follows:
1944 \tempo @var{duration} = @var{perminute}
1947 In the MIDI output, they are interpreted as a tempo change, and in the
1948 paper output, a metronome marking is printed:
1949 @cindex @code{\tempo}
1950 @lilypond[fragment,verbatim]
1956 @internalsref{MetronomeChangeEvent}.
1961 @subsection Text spanners
1962 @cindex Text spanners
1964 Some performance indications, e.g. @i{rallentando} or @i{accelerando},
1965 are written as texts, and extended over many measures with dotted
1966 lines. You can create such texts using text spanners: attach
1967 @code{\startTextSpan} and @code{\stopTextSpan} to the
1968 start and ending note of the spanner.
1970 The string to be printed, as well as the style, is set through object
1973 @lilypond[fragment,relative,verbatim]
1975 \property Voice.TextSpanner \set #'direction = #-1
1976 \property Voice.TextSpanner \set #'edge-text = #'("rall " . "")
1977 c2\startTextSpan b c\stopTextSpan a }
1983 @internalsref{TextSpanEvent},
1984 @internalsref{TextSpanner}, and
1985 @inputfileref{input/regression,text-spanner.ly}.
1988 @node Analysis brackets
1989 @subsection Analysis brackets
1991 @cindex phrasing brackets
1992 @cindex musicological analysis
1993 @cindex note grouping bracket
1995 Brackets are used in musical analysis to indicate structure in musical
1996 pieces. LilyPond supports a simple form of nested horizontal brackets.
1997 To use this, add the @internalsref{Horizontal_bracket_engraver} to
1998 @internalsref{Staff} context. A bracket is started with
1999 @code{\startGroup} and closed with @code{\stopGroup}:
2001 @lilypond[singleline,verbatim]
2002 \score { \notes \relative c'' {
2003 c4\startGroup\startGroup
2006 c4\stopGroup\stopGroup
2008 \paper { \translator {
2009 \StaffContext \consists "Horizontal_bracket_engraver"
2015 @internalsref{HorizontalBracket}, @internalsref{NoteGroupingEvent}, and
2016 @inputfileref{input/regression,note-group-bracket.ly}.
2020 @section Articulations
2021 @cindex Articulations
2023 @cindex articulations
2027 A variety of symbols can appear above and below notes to indicate
2028 different characteristics of the performance. They are added to a note
2029 by adding a dash and the character signifying the
2030 articulation. They are demonstrated here:
2032 @lilypondfile[notexidoc]{script-abbreviations.ly}
2034 The meanings of these shorthands can be changed: see
2035 @file{ly/script-init.ly} for examples.
2038 The script is automatically placed, but if you need to force
2039 directions, you can use @code{_} to force them down, or @code{^} to
2041 @lilypond[fragment, verbatim]
2045 Other symbols can be added using the syntax
2046 @var{note}@code{\}@var{name}, e.g. @code{c4\fermata}. Again, they
2047 can be forced up or down using @code{^} and @code{_},
2050 @lilypond[verbatim,fragment,relative 2]
2051 c\fermata c^\fermata c_\fermata
2058 @cindex staccatissimo
2067 @cindex organ pedal marks
2076 @cindex prallmordent
2080 @cindex thumb marking
2085 @lilypondfile[notexidoc]{script-chart.ly}
2090 @cindex @code{\scriptUp}
2092 @cindex @code{\scriptDown}
2094 @cindex @code{\scriptBoth}
2099 @internalsref{ScriptEvent}, and @internalsref{Script}.
2103 All of these note ornaments appear in the printed output but have no
2104 effect on the MIDI rendering of the music.
2107 @node Fingering instructions
2108 @section Fingering instructions
2112 Fingering instructions can be entered using
2114 @var{note}-@var{digit}
2116 For finger changes, use markup texts:
2118 @lilypond[verbatim, singleline, fragment]
2119 c'4-1 c'4-2 c'4-3 c'4-4
2120 c'^\markup { \fontsize #-3 \number "2-3" }
2123 @cindex finger change
2128 You can use the thumb-script to indicate that a note should be
2129 played with your thumb (used in cello music):
2131 @lilypond[verbatim, singleline, fragment]
2132 <a' a''-3>8(_\thumb[ <b' b''-3>)_\thumb
2133 <c'' c'''-3>(_\thumb <d'' d'''-3>)_\thumb]
2136 Fingerings for chords can also be added to individual notes
2137 of the chord by adding them after the pitches:
2138 @lilypond[verbatim,singleline,fragment,relative=1]
2139 < c-1 e-2 g-3 b-5 > 4
2142 Setting @code{fingeringOrientations} will put fingerings next
2145 @lilypond[verbatim,singleline,fragment,relative=1]
2146 \property Voice.fingeringOrientations = #'(left down)
2147 <c-1 es-2 g-4 bes-5 > 4
2148 \property Voice.fingeringOrientations = #'(up right down)
2149 <c-1 es-2 g-4 bes-5 > 4
2154 @internalsref{FingerEvent}, and @internalsref{Fingering}.
2165 @subsection Text scripts
2166 @cindex Text scripts
2168 It is possible to place arbitrary strings of text or markup text (see
2169 @ref{Text markup}) above or below notes by using a string:
2170 @code{c^"text"}. By default, these indications do not influence the
2171 note spacing, but by using the command @code{\fatText}, the widths
2172 will be taken into account:
2174 @lilypond[fragment,singleline,verbatim] \relative c' {
2175 c4^"longtext" \fatText c4_"longlongtext" c4 }
2178 It is possible to use @TeX{} commands in the strings, but this should
2179 be avoided because the exact dimensions of the string can then no
2185 @internalsref{TextScriptEvent}, @internalsref{TextScript}, and
2191 @subsection Grace notes
2194 @c should have blurb about accaciatura / appogiatura
2196 @cindex @code{\grace}
2200 Grace notes are ornaments that are written out. The most common ones
2201 are acciaccatura, which should be played as very short. It is denoted
2202 by a slurred small note with a slashed stem. The appoggiatura is a
2203 grace note that takes a fixed fraction of the main note, is and
2204 denoted as a slurred note in small print without a slash.
2205 They are entered with the commands @code{\acciaccatura} and
2206 @code{\appoggiatura}, as demonstrated in the following example:
2209 @cindex appoggiatura
2210 @cindex acciaccatura
2212 @lilypond[relative=2,verbatim,fragment]
2213 b4 \acciaccatura d8 c4 \appoggiatura e8 d4
2214 \acciaccatura { g16 f } e4
2217 Both are special forms of the @code{\grace} command. By prefixing this
2218 keyword to a music expression, a new one is formed, which will be
2219 printed in a smaller font and takes up no logical time in a measure.
2220 @lilypond[relative=2,verbatim,fragment]
2221 c4 \grace c16 c4 \grace {
2224 Unlike @code{\acciaccatura} and @code{\appoggiatura}, the
2225 @code{\grace} command does not start a slur.
2227 Internally, timing for grace notes is done using a second, `grace'
2228 time. Every point in time consists of two rational numbers: one
2229 denotes the logical time, one denotes the grace timing. The above
2230 example is shown here with timing tuples:
2232 @lilypond[singleline]
2235 c4 \grace c16 c4 \grace {
2238 \new Lyrics \lyrics {
2241 ( \fraction 1 4 , \fraction -1 16 ) } 16 }
2242 \markup { (\fraction 1 4 , 0 ) } 4
2244 \markup { (\fraction 2 4 , \fraction "-1" 8 ) } 16
2245 \markup { (\fraction 2 4 , \fraction "-1" 16 ) } 16
2247 \markup { ( \fraction 2 4 , 0 ) }
2252 The placement of grace notes is synchronized between different staves.
2253 In the following example, there are two sixteenth graces notes for
2254 every eighth grace note:
2256 @lilypond[relative=2,verbatim,fragment]
2257 << \new Staff { e4 \grace { c16[ d e f] } e4 }
2258 \new Staff { c'4 \grace { g8[ b] } c4 } >>
2263 If you want to end a note with a grace note, then the standard trick
2264 is to put the grace notes before a phantom ``space note'', e.g.
2265 @lilypond[fragment,verbatim, relative=2]
2268 { s2 \grace { c16[ d] } } >>
2274 By adjusting the duration of the skip note (here it is a half-note),
2275 the space between the main-note and the grace is adjusted.
2278 A @code{\grace} section will introduce special typesetting settings,
2279 for example, to produce smaller type, and set directions. Hence, when
2280 introducing layout tweaks, they should be inside the grace section,
2282 @lilypond[fragment,verbatim,relative 2]
2285 \property Voice.Stem \override #'direction = #-1
2287 \property Voice.Stem \revert #'direction
2294 The overrides should also be reverted inside the grace section.
2296 If the layout of grace sections must be changed throughout the music,
2297 then this can be accomplished through the function
2298 @code{add-grace-property}. The following example
2299 undefines the Stem direction grace section, so stems do not always
2304 #(add-grace-property "Voice" Stem direction '())
2310 Another option is to change the variables @code{startGraceMusic},
2311 @code{stopGraceMusic}, @code{startAccacciaturaMusic},
2312 @code{stopAccacciaturaMusic}, @code{startAppoggiaturaMusic},
2313 @code{stopAppoggiaturaMstuic}. More information is in the file
2314 @file{ly/grace-init.ly}
2319 @internalsref{GraceMusic}.
2323 Grace notes cannot be used in the smallest size (@file{paper11.ly}).
2325 A score that starts with an @code{\grace} section needs an explicit
2326 @code{\context Voice} declaration, otherwise the main note and grace
2327 note end up on different staves.
2329 Grace note synchronization can also lead to surprises. Staff notation,
2330 such as key signatures, barlines, etc. are also synchronized. Take
2331 care when you mix staves with grace notes and staves without, for example,
2333 @lilypond[relative=2,verbatim,fragment]
2334 << \new Staff { e4 \bar "|:" \grace c16 d4 }
2335 \new Staff { c4 \bar "|:" d4 } >>
2338 Grace sections should only be used within sequential music
2339 expressions. Nesting or juxtaposing grace sections is not supported,
2340 and might produce crashes or other errors.
2342 Overriding settings cannot be done in separate styles for appoggiatura
2347 @subsection Glissando
2350 @cindex @code{\glissando}
2352 A glissando is a smooth change in pitch. It is denoted by a line or a
2353 wavy line between two notes.
2357 A glissando line can be requested by attaching a @code{\glissando} to
2360 @lilypond[fragment,relative,verbatim]
2366 @internalsref{Glissando}, and @internalsref{GlissandoEvent}.
2371 Additional texts (such as @emph{gliss.}) is not supported.
2375 @subsection Dynamics
2388 @cindex @code{\ffff}
2398 Absolute dynamic marks are specified using an variable after a
2399 note: @code{c4\ff}. The available dynamic marks are @code{\ppp},
2400 @code{\pp}, @code{\p}, @code{\mp}, @code{\mf}, @code{\f}, @code{\ff},
2401 @code{\fff}, @code{\fff}, @code{\fp}, @code{\sf}, @code{\sff},
2402 @code{\sp}, @code{\spp}, @code{\sfz}, and @code{\rfz}:
2404 @lilypond[verbatim,singleline,fragment,relative]
2405 c'\ppp c\pp c \p c\mp c\mf c\f c\ff c\fff
2411 @cindex @code{\decr}
2412 @cindex @code{\rced}
2419 A crescendo mark is started with @code{\<} and terminated with
2420 @code{\!}. A decrescendo is started with @code{\>} and also terminated
2421 with @code{\!}. Because these marks are bound to notes, if you must
2422 use spacer notes if multiple marks during one note are needed:
2424 @lilypond[fragment,verbatim,center,quote]
2425 c''\< c''\! d''\decr e''\rced
2426 << f''1 { s4 s4\< s4\! \> s4\! } >>
2428 This may give rise to very short hairpins. Use @code{minimum-length}
2429 in @internalsref{Voice}.@internalsref{Hairpin} to lengthen them, for
2433 \property Staff.Hairpin \override #'minimum-length = #5
2436 You can also use a text saying @emph{cresc.} instead of hairpins. Here
2437 is an example how to do it:
2439 @lilypond[fragment,relative=2,verbatim]
2440 c4 \cresc c4 c c c \endcresc c4
2446 You can also supply your own texts:
2447 @lilypond[fragment,relative,verbatim]
2449 \property Voice.crescendoText = \markup { \italic "cresc. poco" }
2450 \property Voice.crescendoSpanner = #'dashed-line
2460 @cindex @code{\dynamicUp}
2462 @cindex @code{\dynamicDown}
2463 @code{\dynamicDown},
2464 @cindex @code{\dynamicBoth}
2465 @code{\dynamicBoth}.
2467 @cindex direction, of dynamics
2471 @internalsref{CrescendoEvent}, @internalsref{DecrescendoEvent}, and
2472 @internalsref{AbsoluteDynamicEvent}.
2474 Dynamics are objects of @internalsref{DynamicText} and
2475 @internalsref{Hairpin}. Vertical positioning of these symbols is
2476 handled by the @internalsref{DynamicLineSpanner} object.
2478 If you want to adjust padding or vertical direction of the dynamics, you
2479 must set properties for the @internalsref{DynamicLineSpanner} object.
2487 @cindex @code{\repeat}
2490 Repetition is a central concept in music, and multiple notations exist
2491 for repetitions. In LilyPond, most of these notations can be captured
2492 in a uniform syntax. One of the advantages is, all these repetitions
2493 can be rendered in MIDI accurately.
2495 The following types of repetition are supported:
2499 Repeated music is fully written (played) out. Useful for MIDI
2500 output, and entering repetitive music.
2503 This is the normal notation: Repeats are not written out, but
2504 alternative endings (voltas) are printed, left to right.
2508 Alternative endings are written stacked. This has limited use but may be
2509 used to typeset two lines of lyrics in songs with repeats, see
2510 @inputfileref{input,star-spangled-banner.ly}.
2517 Make beat or measure repeats. These look like percent signs.
2523 * Repeats and MIDI::
2524 * Manual repeat commands::
2526 * Tremolo subdivisions::
2531 @subsection Repeat syntax
2535 LilyPond has one syntactic construct for specifying different types of
2536 repeats. The syntax is
2539 \repeat @var{variant} @var{repeatcount} @var{repeatbody}
2542 If you have alternative endings, you may add
2543 @cindex @code{\alternative}
2545 \alternative @code{@{} @var{alternative1}
2547 @var{alternative3} @dots{} @code{@}}
2549 where each @var{alternative} is a music expression. If you do not
2550 give enough alternatives for all of the repeats, then the first
2551 alternative is assumed to be played more than once.
2553 Normal notation repeats are used like this:
2554 @lilypond[fragment,verbatim]
2556 \repeat volta 2 { c'4 d' e' f' }
2557 \repeat volta 2 { f' e' d' c' }
2560 With alternative endings:
2561 @lilypond[fragment,verbatim]
2563 \repeat volta 2 {c'4 d' e' f'}
2564 \alternative { {d'2 d'} {f' f} }
2568 @lilypond[fragment,verbatim]
2572 \repeat volta 4 { e | c2 d2 | e2 f2 | }
2573 \alternative { { g4 g g } { a | a a a a | b2. } }
2580 If you do a nested repeat like
2589 then it is ambiguous to which @code{\repeat} the @code{\alternative}
2590 belongs. This ambiguity is resolved by always having the
2591 @code{\alternative} belong to the inner @code{\repeat}. For clarity,
2592 it is advisable to use braces in such situations.
2595 @node Repeats and MIDI
2596 @subsection Repeats and MIDI
2598 @cindex expanding repeats
2600 For instructions on how to unfold repeats for MIDI output, see the
2601 example file @inputfileref{input/test,unfold-all-repeats.ly}.
2606 Timing information is not remembered at the start of an alternative,
2607 so after a repeat timing information must be reset by hand, for
2608 example by setting @code{Score.measurePosition} or entering
2609 @code{\partial}. Similarly, slurs or ties are also not repeated.
2612 @node Manual repeat commands
2613 @subsection Manual repeat commands
2615 @cindex @code{repeatCommands}
2617 The property @code{repeatCommands} can be used to control the layout of
2618 repeats. Its value is a Scheme list of repeat commands, where each repeat
2622 @item the symbol @code{start-repeat},
2623 which prints a @code{|:} bar line,
2624 @item the symbol @code{end-repeat},
2625 which prints a @code{:|} bar line,
2626 @item the list @code{(volta @var{text})},
2627 which prints a volta bracket saying @var{text}: The text can be specified as
2628 a text string or as a markup text, see @ref{Text markup}. Do not
2629 forget to change the font, as the default number font does not contain
2630 alphabetic characters. Or,
2631 @item the list @code{(volta #f)}, which
2632 stops a running volta bracket:
2635 @lilypond[verbatim, fragment]
2637 \property Score.repeatCommands = #'((volta "93") end-repeat)
2639 \property Score.repeatCommands = #'((volta #f))
2646 @internalsref{VoltaBracket}, @internalsref{RepeatedMusic},
2647 @internalsref{VoltaRepeatedMusic},
2648 @internalsref{UnfoldedRepeatedMusic}, and
2649 @internalsref{FoldedRepeatedMusic}.
2651 @node Tremolo repeats
2652 @subsection Tremolo repeats
2653 @cindex tremolo beams
2655 To place tremolo marks between notes, use @code{\repeat} with tremolo
2657 @lilypond[verbatim,center,singleline]
2659 \context Voice \notes\relative c' {
2660 \repeat "tremolo" 8 { c16 d16 }
2661 \repeat "tremolo" 4 { c16 d16 }
2662 \repeat "tremolo" 2 { c16 d16 }
2663 \repeat "tremolo" 4 c16
2670 Tremolo beams are @internalsref{Beam} objects. Single stem tremolos
2671 are @internalsref{StemTremolo}s. The music expression is
2672 @internalsref{TremoloEvent}.
2677 The single stem tremolo must be entered without @code{@{} and
2680 @node Tremolo subdivisions
2681 @subsection Tremolo subdivisions
2682 @cindex tremolo marks
2683 @cindex @code{tremoloFlags}
2685 Tremolo marks can be printed on a single note by adding
2686 `@code{:}[@var{length}]' after the note. The length must be at least 8.
2687 A @var{length} value of 8 gives one line across the note stem. If the
2688 length is omitted, then then the last value (stored in
2689 @code{Voice.tremoloFlags}) is used:
2691 @lilypond[verbatim,fragment,center]
2692 c'2:8 c':32 | c': c': |
2695 @c [TODO : stok is te kort bij 32en]
2699 Tremolos in this style do not carry over into the MIDI output.
2702 @node Measure repeats
2703 @subsection Measure repeats
2705 @cindex percent repeats
2706 @cindex measure repeats
2708 In the @code{percent} style, a note pattern can be repeated. It is
2709 printed once, and then the pattern is replaced with a special sign.
2710 Patterns of a one and two measures are replaced by percent-like signs,
2711 patterns that divide the measure length are replaced by slashes:
2713 @lilypond[verbatim,singleline]
2714 \context Voice { \repeat "percent" 4 { c'4 }
2715 \repeat "percent" 2 { c'2 es'2 f'4 fis'4 g'4 c''4 }
2721 @internalsref{RepeatSlash}, @internalsref{PercentRepeat},
2722 @internalsref{PercentRepeatedMusic}, and
2723 @internalsref{DoublePercentRepeat}.
2727 @node Rhythmic music
2728 @section Rhythmic music
2730 Sometimes you might want to show only the rhythm of a melody. This
2731 can be done with the rhythmic staff. All pitches of notes on such a
2732 staff are squashed, and the staff itself has a single line:
2734 @lilypond[fragment,relative,verbatim]
2735 \context RhythmicStaff {
2737 c4 e8 f g2 | r4 g r2 | g1:32 | r1 |
2742 * Percussion staves::
2743 * Percussion MIDI output::
2746 @node Percussion staves
2747 @subsection Percussion staves
2751 A percussion part for more than one instrument typically uses a
2752 multiline staff where each position in the staff refers to one piece
2757 Percussion staves are typeset with help of a set of Scheme
2758 functions. The system is based on the general MIDI drum-pitches.
2759 Include @file{drumpitch-init.ly} to use drum pitches. This file
2760 defines the pitches from the Scheme variable @code{drum-pitch-names},
2761 the definition of which can be read in @file{scm/drums.scm}. Each
2762 piece of percussion has a full name and an abbreviated name, and either
2763 the full name or the abbreviation may be used in input files.
2765 To typeset the music on a staff apply the function @code{drums->paper}
2766 to the percussion music. This function takes a list of percussion
2767 instrument names, notehead scripts and staff positions (that is:
2768 pitches relative to the C-clef) and transforms the input
2769 music by moving the pitch, changing the notehead and (optionally)
2772 @lilypond[singleline,verbatim,quote]
2773 \include "drumpitch-init.ly"
2774 up = \notes { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
2775 down = \notes { bassdrum4 snare8 bd r bd sn4 }
2777 \apply #(drums->paper 'drums) \context Staff <<
2779 \new Voice { \voiceOne \up }
2780 \new Voice { \voiceTwo \down }
2785 In the above example the music was transformed using the list @code{'drums}.
2786 The following lists are defined in @file{scm/drums.scm}:
2789 to typeset a typical drum kit on a five-line staff:
2792 \include "drumpitch-init.ly"
2793 nam = \lyrics { cymc cyms cymr hh hhc hho hhho hhp cb hc
2794 bd sn ss tomh tommh tomml toml tomfh tomfl }
2795 mus = \notes { cymc cyms cymr hh hhc hho hhho hhp cb hc
2796 bd sn ss tomh tommh tomml toml tomfh tomfl s16 }
2799 \apply #(drums->paper 'drums) \context Staff <<
2803 \context Lyrics \nam
2806 linewidth = 100.0\mm
2809 \remove Bar_engraver
2810 \remove Time_signature_engraver
2811 minimumVerticalExtent = #'(-4.0 . 5.0)
2815 \remove Stem_engraver
2821 The drum scheme supports six different toms. When there fewer toms, simply
2822 select the toms that produce the desired result, i.e. to get toms on
2823 the three middle lines you use @code{tommh}, @code{tomml} and
2826 Because general MIDI does not contain rimshots the sidestick is used
2827 for this purpose instead.
2829 to typeset timbales on a two line staff:
2831 @lilypond[singleline]
2832 \include "drumpitch-init.ly"
2833 nam = \lyrics { timh ssh timl ssl cb }
2834 mus = \notes { timh ssh timl ssl cb s16 }
2837 \apply #(drums->paper 'timbales) \context Staff <<
2841 \context Lyrics \nam
2846 \remove Bar_engraver
2847 \remove Time_signature_engraver
2848 StaffSymbol \override #'line-count = #2
2849 StaffSymbol \override #'staff-space = #2
2850 minimumVerticalExtent = #'(-3.0 . 4.0)
2854 \remove Stem_engraver
2861 to typeset congas on a two line staff:
2863 @lilypond[singleline]
2864 \include "drumpitch-init.ly"
2865 nam = \lyrics { cgh cgho cghm ssh cgl cglo cglm ssl }
2866 mus = \notes { cgh cgho cghm ssh cgl cglo cglm ssl s16 }
2869 \apply #(drums->paper 'congas) \context Staff <<
2873 \context Lyrics \nam
2878 \remove Bar_engraver
2879 \remove Time_signature_engraver
2880 StaffSymbol \override #'line-count = #2
2881 StaffSymbol \override #'staff-space = #2
2882 minimumVerticalExtent = #'(-3.0 . 4.0)
2886 \remove Stem_engraver
2892 to typeset bongos on a two line staff:
2894 @lilypond[singleline]
2895 \include "drumpitch-init.ly"
2896 nam = \lyrics { boh boho bohm ssh bol bolo bolm ssl }
2897 mus = \notes { boh boho bohm ssh bol bolo bolm ssl s16 }
2900 \apply #(drums->paper 'bongos) \context Staff <<
2904 \context Lyrics \nam
2909 \remove Bar_engraver
2910 \remove Time_signature_engraver
2911 StaffSymbol \override #'line-count = #2
2912 StaffSymbol \override #'staff-space = #2
2913 minimumVerticalExtent = #'(-3.0 . 4.0)
2917 \remove Stem_engraver
2923 to typeset all kinds of simple percussion on one line staves:
2924 @lilypond[singleline]
2925 \include "drumpitch-init.ly"
2926 nam = \lyrics { tri trio trim gui guis guil cb cl tamb cab mar hc }
2927 mus = \notes { tri trio trim gui guis guil cb cl tamb cab mar hc s16 }
2930 \apply #(drums->paper 'percussion) \context Staff <<
2934 \context Lyrics \nam
2939 \remove Bar_engraver
2940 \remove Time_signature_engraver
2941 StaffSymbol \override #'line-count = #1
2942 minimumVerticalExtent = #'(-2.0 . 3.0)
2946 \remove Stem_engraver
2953 If you do not like any of the predefined lists you can define your own
2954 list at the top of your file:
2956 @lilypond[singleline, verbatim]
2957 #(set-drum-kit 'mydrums `(
2958 (bassdrum default #f ,(ly:make-pitch -1 2 0))
2959 (snare default #f ,(ly:make-pitch 0 1 0))
2960 (hihat cross #f ,(ly:make-pitch 0 5 0))
2961 (pedalhihat xcircle "stopped" ,(ly:make-pitch 0 5 0))
2962 (lowtom diamond #f ,(ly:make-pitch -1 6 0))
2964 \include "drumpitch-init.ly"
2965 up = \notes { hh8 hh hh hh hhp4 hhp }
2966 down = \notes { bd4 sn bd toml8 toml }
2968 \apply #(drums->paper 'mydrums) \context Staff <<
2970 \new Voice { \voiceOne \up }
2971 \new Voice { \voiceTwo \down }
2976 To use a modified existing list, one can prepend modifications to the
2980 #(set-drum-kit 'mydrums (append `(
2981 (bassdrum default #f ,(ly:make-pitch -1 2 0))
2982 (lowtom diamond #f ,(ly:make-pitch -1 6 0))
2983 ) (get-drum-kit 'drums)))
2986 You can easily combine percussion notation with pitched notation.
2987 Indeed, the file @file{drumpitch-init.ly} replaces the normal pitch
2988 names, so you will have to reinclude @file{nederlands.ly} after the
2989 drum-pattern-definitions to enter normal notes:
2991 @lilypond[singleline,verbatim]
2992 \include "drumpitch-init.ly"
2993 up = \notes { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
2994 down = \notes { bassdrum4 snare8 bd r bd sn4 }
2995 \include "nederlands.ly"
2996 bass = \notes \transpose c c,, { a4. e8 r e g e }
2999 \apply #(drums->paper 'drums) \new Staff <<
3001 \new Voice { \voiceOne \up }
3002 \new Voice { \voiceTwo \down }
3004 \new Staff { \clef "F_8" \bass }
3009 @node Percussion MIDI output
3010 @subsection Percussion MIDI output
3012 In order to produce correct MIDI output you need to produce two score
3013 blocks---one for the paper and one for the MIDI output. To use the
3014 percussion channel you set the property @code{instrument} to
3015 @code{'drums}. Because the drum-pitches themselves are similar to the
3016 general MIDI pitches all you have to do is to insert the voices with
3017 none of the scheme functions to get the correct MIDI output:
3021 \apply #(drums->paper 'mydrums) \context Staff <<
3030 \property Staff.instrument = #'drums
3039 This scheme is a temporary implementation.
3043 @section Piano music
3045 Piano staves are two normal staves coupled with a brace. The staves
3046 are largely independent, but sometimes voices can cross between the
3047 two staves. The same notation is also used for harps and other key
3048 instruments. The @internalsref{PianoStaff} is especially built to
3049 handle this cross-staffing behavior. In this section we discuss the
3050 @internalsref{PianoStaff} and some other pianistic peculiarities.
3054 * Automatic staff changes::
3055 * Manual staff switches::
3058 * Staff switch lines::
3063 There is no support for putting chords across staves. You can get
3064 this result by increasing the length of the stem in the lower stave so
3065 it reaches the stem in the upper stave, or vice versa. An example is
3066 included with the distribution as @inputfileref{input/test,stem-cross-staff.ly}.
3068 Dynamics are not centered, but kludges do exist. See
3069 @inputfileref{input/template,piano-dynamics.ly}.
3071 @cindex cross staff stem
3072 @cindex stem, cross staff
3075 @c fixme: should have hyperlinks as well.
3081 @node Automatic staff changes
3082 @subsection Automatic staff changes
3083 @cindex Automatic staff changes
3085 Voices can switch automatically between the top and the bottom
3086 staff. The syntax for this is
3088 \autochange Staff \context Voice @{ @dots{}@var{music}@dots{} @}
3090 The two staffs of the piano staff must be named @code{up} and
3093 The autochanger switches on basis of pitch (central C is the turning
3094 point), and it looks ahead skipping over rests to switch in
3095 advance. Here is a practical example:
3097 @lilypond[verbatim,singleline,quote]
3098 \score { \notes \context PianoStaff <<
3099 \context Staff = "up" {
3100 \autochange Staff \context Voice = VA << \relative c' {
3101 g4 a b c d r4 a g } >> }
3102 \context Staff = "down" {
3109 In this example, spacer rests are used to prevent the bottom staff from
3110 terminating too soon.
3115 @internalsref{AutoChangeMusic}.
3119 The staff switches often do not end up in optimal places. For high
3120 quality output staff switches should be specified manually.
3124 @node Manual staff switches
3125 @subsection Manual staff switches
3127 @cindex manual staff switches
3128 @cindex staff switch, manual
3130 Voices can be switched between staves manually, using the following command:
3132 \translator Staff = @var{staffname} @var{music}
3136 The string @var{staffname} is the name of the staff. It switches the
3137 current voice from its current staff to the Staff called
3138 @var{staffname}. Typically @var{staffname} is @code{"up"} or
3146 Pianos have pedals that alter the way sound are produced. Generally, a
3147 piano has three pedals, sustain, una corda, and sostenuto.
3151 Piano pedal instruction can be expressed by attaching
3152 @code{\sustainDown}, @code{\sustainUp}, @code{\unaCorda},
3153 @code{\treCorde}, @code{\sostenutoDown} and @code{\sostenutoUp} to a
3156 @lilypond[fragment,verbatim]
3157 c'4\sustainDown c'4\sustainUp
3160 What is printed can be modified by setting @code{pedal@var{X}Strings},
3161 where @var{X} is one of the pedal types: @code{Sustain},
3162 @code{Sostenuto} or @code{UnaCorda}. Refer to the generated
3163 documentation of @internalsref{SustainPedal} for more information.
3165 Pedals can also be indicated by a sequence of brackets, by setting the
3166 @code{pedalSustainStyle} property to @code{bracket} objects:
3168 @lilypond[fragment,verbatim]
3169 \property Staff.pedalSustainStyle = #'bracket
3170 c''4\sustainDown d''4 e''4
3171 a'4\sustainUp\sustainDown
3172 f'4 g'4 a'4\sustainUp
3175 A third style of pedal notation is a mixture of text and brackets,
3176 obtained by setting @code{pedal-type} to @code{mixed}:
3178 @lilypond[fragment,verbatim]
3179 \property Staff.pedalSustainStyle = #'mixed
3180 c''4\sustainDown d''4 e''4
3181 c'4\sustainUp\sustainDown
3182 f'4 g'4 a'4\sustainUp
3185 The default `*Ped' style for sustain and damper pedals corresponds to
3186 @code{\pedal-type = #'text}. However, @code{mixed} is the default style
3187 for a sostenuto pedal:
3189 @lilypond[fragment,verbatim]
3190 c''4\sostenutoDown d''4 e''4 c'4 f'4 g'4 a'4\sostenutoUp
3193 For fine-tuning of the appearance of a pedal bracket, the properties
3194 @code{edge-width}, @code{edge-height}, and @code{shorten-pair} of
3195 @code{PianoPedalBracket} objects (, see the detailed documentation of
3196 @internalsref{PianoPedalBracket},) can be modified. For example, the bracket
3197 may be extended to the end of the note head:
3199 @lilypond[fragment,verbatim]
3200 \property Staff.PianoPedalBracket \override
3201 #'shorten-pair = #'(0 . -1.0)
3202 c''4\sostenutoDown d''4 e''4 c'4
3203 f'4 g'4 a'4\sostenutoUp
3207 @subsection Arpeggio
3210 @cindex broken arpeggio
3211 @cindex @code{\arpeggio}
3213 You can specify an arpeggio sign on a chord by attaching an
3214 @code{\arpeggio} to a chord:
3217 @lilypond[fragment,relative,verbatim]
3221 When an arpeggio crosses staves, you attach an arpeggio to the chords
3222 in both staves, and set
3223 @internalsref{PianoStaff}.@code{connectArpeggios}:
3225 @lilypond[fragment,relative,verbatim]
3226 \context PianoStaff <<
3227 \property PianoStaff.connectArpeggios = ##t
3228 \new Staff { <c' e g c>\arpeggio }
3229 \new Staff { \clef bass <c,, e g>\arpeggio }
3233 The direction of the arpeggio is sometimes denoted by adding an
3234 arrowhead to the wiggly line. This can be typeset by setting
3235 @code{arpeggio-direction}:
3237 @lilypond[fragment,relative,verbatim]
3239 \property Voice.Arpeggio \set #'arpeggio-direction = #1
3241 \property Voice.Arpeggio \set #'arpeggio-direction = #-1
3246 A square bracket on the left indicates that the player should not
3247 arpeggiate the chord. To draw these brackets, set the
3248 @code{molecule-callback} property of @code{Arpeggio} or
3249 @code{PianoStaff.Arpeggio} objects to @code{\arpeggioBracket}, and use
3250 @code{\arpeggio} statements within the chords as before:
3252 @lilypond[fragment,relative,verbatim]
3253 \property PianoStaff.Arpeggio \override
3254 #'molecule-callback = \arpeggioBracket
3260 @cindex @code{\arpeggioBracket}
3261 @code{\arpeggioBracket},
3262 @cindex @code{\arpeggio}
3267 @internalsref{ArpeggioEvent} expression lead to
3268 @internalsref{Arpeggio} objects. Cross staff arpeggios are
3269 @internalsref{PianoStaff}.@internalsref{Arpeggio}.
3273 It is not possible to mix connected arpeggios and unconnected
3274 arpeggios in one @internalsref{PianoStaff} at the same time.
3276 @node Staff switch lines
3277 @subsection Staff switch lines
3280 @cindex follow voice
3281 @cindex staff switching
3284 @cindex @code{followVoice}
3286 Whenever a voice switches to another staff a line connecting the notes
3287 can be printed automatically. This is enabled if the property
3288 @code{PianoStaff.followVoice} is set to true:
3290 @lilypond[fragment,relative,verbatim]
3291 \context PianoStaff <<
3292 \property PianoStaff.followVoice = ##t
3293 \context Staff \context Voice {
3295 \translator Staff=two
3298 \context Staff=two { \clef bass \skip 1*2 }
3302 The associated object is @internalsref{VoiceFollower}.
3306 @cindex @code{\showStaffSwitch}
3307 @code{\showStaffSwitch},
3308 @cindex @code{\hideStaffSwitch}
3309 @code{\hideStaffSwitch}.
3313 @section Vocal music
3315 This section discusses how to enter and print lyrics.
3319 * The Lyrics context::
3324 @node Entering lyrics
3325 @subsection Entering lyrics
3329 @cindex @code{\lyrics}
3332 Lyrics are entered in a special input mode. This mode is is introduced
3333 by the keyword @code{\lyrics}. In this mode you can enter lyrics, with
3334 punctuation and accents without any hassle. Syllables are entered like
3335 notes, but with pitches replaced by text. For example,
3337 \lyrics @{ Twin-4 kle4 twin- kle litt- le star2 @}
3340 A word in Lyrics mode begins with: an alphabetic character, @code{_},
3341 @code{?}, @code{!}, @code{:}, @code{'}, the control characters @code{^A}
3342 through @code{^F}, @code{^Q} through @code{^W}, @code{^Y}, @code{^^},
3343 any 8-bit character with ASCII code over 127, or a two-character
3344 combination of a backslash followed by one of @code{`}, @code{'},
3345 @code{"}, or @code{^}.
3347 Subsequent characters of a word can be any character that is not a digit
3348 and not white space. One important consequence of this is that a word
3349 can end with @code{@}}. The following example is usually a bug. The
3350 syllable includes a @code{@}}, and hence the opening brace is not balanced:
3352 \lyrics @{ twinkle@}
3355 @cindex @code{\property}, in @code{\lyrics}
3356 Similarly, a period following a alphabetic sequence, is included in the
3357 resulting string. As a consequence, spaces must be inserted around
3358 @code{\property} commands:
3360 \property Lyrics . LyricText \set #'font-shape = #'italic
3364 @cindex spaces, in lyrics
3365 @cindex quotes, in lyrics
3367 Any @code{_} character which appears in an unquoted word is converted
3368 to a space. This provides a mechanism for introducing spaces into words
3369 without using quotes. Quoted words can also be used in Lyrics mode to
3370 specify words that cannot be written with the above rules:
3373 \lyrics @{ He said: "\"Let" my peo ple "go\"" @}
3377 Hyphens can be entered as ordinary hyphens at the end of a syllable, i.e.
3382 These will be attached to the end of the first syllable.
3384 Centered hyphens are entered using the special `@code{-}@code{-}' lyric
3385 as a separate word between syllables. The hyphen will have variable
3386 length depending on the space between the syllables and it will be
3387 centered between the syllables.
3392 When a lyric is sung over many notes (this is called a melisma), this is
3393 indicated with a horizontal line centered between a syllable and the
3394 next one. Such a line is called an extender line, and it is entered as
3399 @internalsref{LyricEvent}, @internalsref{HyphenEvent}, and
3400 @internalsref{ExtenderEvent}.
3404 The definition of lyrics mode is too complex.
3406 @node The Lyrics context
3407 @subsection The Lyrics context
3409 Lyrics are printed by interpreting them in @internalsref{Lyrics} context:
3411 \context Lyrics \lyrics @dots{}
3414 @cindex automatic syllable durations
3415 @cindex @code{\addlyrics}
3416 @cindex lyrics and melodies
3418 This will place the lyrics according to the durations that were
3419 entered. The lyrics can also be aligned under a given melody
3420 automatically. In this case, it is no longer necessary to enter the
3421 correct duration for each syllable. This is achieved by combining the
3422 melody and the lyrics with the @code{\addlyrics} expression:
3426 \context Lyrics @dots{}
3429 @cindex staff order, with @code{\addlyrics}
3431 Normally, this will put the lyrics below the staff. For different or
3432 more complex orderings, the best way is to setup the hierarchy of
3433 staves and lyrics first, e.g.
3435 \context ChoirStaff \notes <<
3436 \new Lyrics @{ s1 @}
3438 \new Lyrics @{ s1 @}
3442 and then combine the appropriate melodies and lyric lines:
3445 \new Staff @emph{the music}
3446 \new Lyrics @emph{the lyrics}
3449 putting both together, you would get
3451 \context ChoirStaff \notes <<
3459 @cindex choral score
3461 A complete example of a SATB score setup is in the file
3462 @inputfileref{input/template,satb.ly}.
3466 @internalsref{LyricCombineMusic}, @internalsref{Lyrics}, and
3467 @inputfileref{input/template,satb.ly}.
3471 @code{\addlyrics} is not automatic enough: melismata are not detected
3472 automatically, and melismata are not stopped when they hit a rest. A
3473 melisma on the last note in a melody is not printed.
3477 @subsection More stanzas
3480 @cindex phrasing, in lyrics
3482 When multiple stanzas are printed underneath each other, the vertical
3483 groups of syllables should be aligned around punctuation. This can be
3484 done automatically when corresponding lyric lines and melodies are
3487 To this end, give the @internalsref{Voice} context an identity:
3489 \context Voice = duet @{
3494 Then set the @internalsref{LyricsVoice} contexts to names starting with
3495 that identity followed by a dash. In the preceding example, the
3496 @internalsref{Voice} identity is @code{duet}, so the identities of the
3497 @internalsref{LyricsVoice}s are marked @code{duet-1} and @code{duet-2}:
3499 \context LyricsVoice = "duet-1" @{
3500 Hi, my name is bert. @}
3501 \context LyricsVoice = "duet-2" @{
3502 Ooooo, ch\'e -- ri, je t'aime. @}
3504 The convention for naming @internalsref{LyricsVoice} and
3505 @internalsref{Voice} must also be used to get melismata correct in
3506 conjunction with rests.
3508 The complete example is shown here:
3509 @lilypond[singleline,verbatim]
3512 \notes \relative c'' \context Voice = duet { \time 3/4
3514 \lyrics \context Lyrics <<
3515 \context LyricsVoice = "duet-1" {
3516 \property LyricsVoice . stanza = "Bert"
3517 Hi, my name is bert. }
3518 \context LyricsVoice = "duet-2" {
3519 \property LyricsVoice . stanza = "Ernie"
3520 Ooooo, ch\'e -- ri, je t'aime. }
3525 Stanza numbers, or the names of the singers can be added by setting
3526 @code{LyricsVoice.Stanza} (for the first system) and
3527 @code{LyricsVoice.stz} for the following systems. Notice how dots are
3528 surrounded with spaces in @code{\lyrics} mode:
3531 \property LyricsVoice . stanza = "Bert"
3533 \property LyricsVoice . stanza = "Ernie"
3536 To make empty spaces in lyrics, use @code{\skip}.
3544 Input for lyrics introduces a syntactical ambiguity:
3551 is interpreted as assigning a string identifier @code{\foo} such that
3552 it contains @code{"bar"}. However, it could also be interpreted as
3553 making or a music identifier @code{\foo} containing the syllable
3554 `bar'. The force the latter interpretation, use
3564 The term @emph{ambitus} denotes a range of pitches for a given voice in
3565 a part of music. It also may denote the pitch range that a musical
3566 instrument is capable of playing. Most musical instruments have their
3567 ambitus standardized (or at least there is agreement upon the minimal
3568 ambitus of a particular type of instrument), such that a composer or
3569 arranger of a piece of music can easily meet the ambitus constraints of
3570 the targeted instrument. However, the ambitus of the human voice
3571 depends on individual physiological state, including education and
3572 training of the voice. Therefore, a singer potentially has to check for
3573 each piece of music if the ambitus of that piece meets his individual
3574 capabilities. This is why the ambitus of a piece may be of particular
3575 value to vocal performers.
3577 The ambitus is typically notated on a per-voice basis at the very
3578 beginning of a piece, e.g. nearby the initial clef or time signature of
3579 each staff. The range is graphically specified by two noteheads, that
3580 represent the minimum and maximum pitch. Some publishers use a textual
3581 notation: they put the range in words in front of the corresponding
3582 staff. LilyPond only supports the graphical ambitus notation.
3584 To apply, add the @internalsref{Ambitus_engraver} to the
3585 @internalsref{Voice} context, i.e.
3591 \consists Ambitus_engraver
3598 @lilypond[singleline]
3599 upper = \notes \relative c {
3602 as'' c e2 bes f cis d4 e f2 g
3604 lower = \notes \relative c {
3607 e'4 b g a c es fis a cis b a g f e d2
3610 \context ChoirStaff {
3612 \new Staff { \upper }
3613 \new Staff { \lower }
3619 \consists Ambitus_engraver
3625 If you have multiple voices in a single staff, and you want a single
3626 ambitus per staff rather than per each voice, then add the
3627 @internalsref{Ambitus_engraver} to the @internalsref{Staff} context
3628 rather than to the @internalsref{Voice} context.
3630 If you have a score with multiple staves and you want the ambitus to
3631 appear only in some of the staves, then you have to declare a new
3632 context type derived from the @internalsref{Voice} context or
3633 @internalsref{Staff} context. The derived context must consist of the
3634 @internalsref{Ambitus_engraver} and it must be accepted by a proper
3635 parent context, in the below example the @internalsref{Staff} context
3636 or @internalsref{Score} context, respectively. The original context
3637 and the derived context can then be used in parallel in the same
3640 @lilypond[singleline]
3641 voiceA = \notes \transpose c c'' {
3644 voiceB = \notes \transpose c c' {
3645 e4 f g2 g8 a g f e4 c
3648 \context ChoirStaff <<
3650 \new VoiceWithAmbitus { \stemUp \voiceA }
3651 \new VoiceWithAmbitus { \stemDown \voiceB }
3653 \new StaffWithAmbitus <<
3654 \new Voice { \stemUp \voiceA }
3655 \new Voice { \stemDown \voiceB }
3658 \new Voice { \stemUp \voiceA }
3659 \new Voice { \stemDown \voiceB }
3666 \name "VoiceWithAmbitus"
3668 \consists Ambitus_engraver
3672 \name "StaffWithAmbitus"
3674 \consists Ambitus_engraver
3678 \accepts "VoiceWithAmbitus"
3682 \accepts "StaffWithAmbitus"
3691 @internalsref{Ambitus}, and @inputfileref{input/regression,ambitus.ly}.
3695 There is no collision handling in the case of multiple per-voice
3696 ambitus. To avoid collision, multiple ambitus in a single staff
3697 should be printed horizontally one after the other rather than on top
3698 of each other in the same horizontal position.
3703 Tablature notation is used for notating music for plucked string
3704 instruments. It notates pitches not by using note heads, but by
3705 indicating on which string and fret a note must be played. LilyPond
3706 offers limited support for tablature.
3709 * Tablatures basic::
3710 * Non-guitar tablatures::
3713 @node Tablatures basic
3714 @subsection Tablatures basic
3715 @cindex Tablatures basic
3717 The string number associated to a note is given as a backslash
3718 followed by a number, e.g. @code{c4\3} for a C quarter on the third
3719 string. By default, string 1 is the highest one, and the tuning
3720 defaults to the standard guitar tuning (with 6 strings). The notes
3721 are printed as tablature, by using @internalsref{TabStaff} and
3722 @internalsref{TabVoice} contexts:
3724 @lilypond[fragment,verbatim]
3725 \notes \context TabStaff {
3731 When no string is specified, the first string that does not give a
3732 fret number less than @code{minimumFret} is selected. The default
3733 value for @code{minimumFret} is 0:
3737 e8 fis gis a b cis' dis' e'
3738 \property TabStaff.minimumFret = #8
3739 e8 fis gis a b cis' dis' e'
3744 e8 fis gis a b cis' dis' e'
3745 \property TabStaff.minimumFret = #8
3746 e8 fis gis a b cis' dis' e'
3749 \context StaffGroup <<
3750 \context Staff { \clef "G_8" \frag }
3751 \context TabStaff { \frag }
3758 @internalsref{TabStaff}, @internalsref{TabVoice}, and
3759 @internalsref{StringNumberEvent}.
3763 Chords are not handled in a special way, and hence the automatic
3764 string selector may easily select the same string to two notes in a
3768 @node Non-guitar tablatures
3769 @subsection Non-guitar tablatures
3770 @cindex Non-guitar tablatures
3772 You can change the number of strings, by setting the number of lines
3773 in the @internalsref{TabStaff} (the @code{line-count} property of
3774 @internalsref{TabStaff} can only be changed using
3775 @code{\outputproperty}, for more information, see @ref{Tuning
3778 You can change the tuning of the strings. A string tuning is given as
3779 a Scheme list with one integer number for each string, the number
3780 being the pitch (measured in semitones relative to central C) of an
3781 open string. The numbers specified for @code{stringTuning} are the
3782 numbers of semitones to subtract or add, starting the specified pitch
3783 by default middle C, in string order. Thus, the notes are e, a, d, and
3786 @lilypond[fragment,verbatim]
3787 \context TabStaff <<
3789 \outputproperty #(make-type-checker 'staff-symbol-interface)
3791 \property TabStaff.stringTunings = #'(-5 -10 -15 -20)
3794 a,4 c' a e' e c' a e'
3799 It is possible to change the Scheme function to format the tablature
3800 note text. The default is @code{fret-number-tablature-format}, which
3801 uses the fret number. For instruments that do not use this notation,
3802 you can create a special tablature formatting function. This function
3803 takes three argument: string number, string tuning and note pitch.
3807 Most of the guitar special effects such as bend have not been
3813 @section Chord names
3816 LilyPond has support for both printing chord names. Chords may be
3817 entered in musical chord notation, i.e. @code{< .. >}, but they can
3818 also be entered by name. Internally, the chords are represented as a
3819 set of pitches, so they can be transposed:
3822 @lilypond[verbatim,singleline]
3823 twoWays = \notes \transpose c c' {
3833 << \context ChordNames \twoWays
3834 \context Voice \twoWays >> }
3837 This example also shows that the chord printing routines do not try to
3838 be intelligent. The last chord (@code{f bes d}) is not interpreted as
3844 * Printing chord names::
3849 @subsection Chords mode
3852 Chord mode is a mode where you can input sets of pitches using common
3853 names. It is introduced by the keyword @code{\chords}.
3854 In chords mode, a chord is entered by the root, which is entered
3855 like a common pitch:
3856 @lilypond[fragment,verbatim,quote, relative=1]
3857 \chords { es4. d8 c2 }
3862 Other chords may be entered by suffixing a colon, and introducing a
3863 modifier, and optionally, a number:
3865 @lilypond[fragment,verbatim,quote]
3866 \chords { e1:m e1:7 e1:m7 }
3868 The first number following the root is taken to be the `type' of the
3869 chord, thirds are added to the root until it reaches the specified
3871 @lilypond[fragment,verbatim]
3872 \chords { c:3 c:5 c:6 c:7 c:8 c:9 c:10 c:11 }
3875 @cindex root of chord
3876 @cindex additions, in chords
3877 @cindex removals, in chords
3879 More complex chords may also be constructed adding separate steps
3880 to a chord. Additions are added after the number following
3881 the colon, and are separated by dots:
3883 @lilypond[verbatim,fragment,quote]
3884 \chords { c:5.6 c:3.7.8 c:3.6.13 }
3886 Chord steps can be altered by suffixing a @code{-} or @code{+} sign
3888 @lilypond[verbatim,fragment,quote]
3889 \chords { c:7+ c:5+.3- c:3-.5-.7- }
3891 Removals are specified similarly, and are introduced by a caret. They
3892 must come after the additions:
3893 @lilypond[verbatim,fragment]
3894 \chords { c^3 c:7^5 c:9^3.5 }
3897 Modifiers can be used to change pitches. The following modifiers are
3901 is the minor chord. This modifier lowers the 3rd and (if present) the 7th step.
3903 is the diminished chord. This modifier lowers the 3rd, 5th and (if present)
3906 is the augmented chord. This modifier raises the 5th step.
3908 is the major 7th chord. This modifier raises the 7th step if present.
3910 is the suspended 4th or 2nd. This modifier removes the 3rd
3911 step. Append either @code{2} or @code{4} to add the 2nd or 4th step to
3914 Modifiers can be mixed with additions:
3915 @lilypond[verbatim,fragment]
3916 \chords { c:sus4 c:7sus4 c:dim7 c:m6 }
3919 @cindex modifiers, in chords.
3926 Since an unaltered 11 does not sound good when combined with an
3927 unaltered 13, the 11 is removed in this case (, unless it is added
3929 @lilypond[fragment,verbatim]
3930 \chords { c:13 c:13.11 c:m13 }
3935 An inversion (putting one pitch of the chord on the bottom), as well
3936 as bass notes, can be specified by appending
3937 @code{/}@var{pitch} to the chord:
3938 @lilypond[fragment,verbatim,center]
3939 \chords { c1 c/g c/f }
3943 A bass note can be added instead of transposed out of the chord,
3944 by using @code{/+}@var{pitch}.
3946 @lilypond[fragment,verbatim,center]
3947 \chords { c1 c/+g c/+f }
3950 Chords is a mode similar to @code{\lyrics}, @code{\notes} etc. Most
3951 of the commands continue to work, for example, @code{r} and
3952 @code{\skip} can be used to insert rests and spaces, and
3953 @code{\property} may be used to change various settings.
3959 Each step can only be present in a chord once. The following
3960 simply produces the augmented chord, since @code{5+} is interpreted
3963 @lilypond[verbatim,fragment]
3964 \chords { c:5.5-.5+ }
3968 @node Printing chord names
3969 @subsection Printing chord names
3971 @cindex printing chord names
3975 For displaying printed chord names, use the @internalsref{ChordNames} context.
3976 The chords may be entered either using the notation
3977 described above, or directly using @code{<} and @code{>}:
3979 @lilypond[verbatim,singleline]
3981 \chords {a1 b c} <d' f' a'> <e' g' b'>
3985 \context ChordNames \scheme
3986 \context Staff \scheme
3991 You can make the chord changes stand out by setting
3992 @internalsref{ChordNames}.@code{chordChanges} to true. This will only
3993 display chord names when there is a change in the chords scheme and at
3994 the start of a new line:
3996 @lilypond[verbatim, linewidth=9cm]
3998 c1:m c:m \break c:m c:m d
4002 \context ChordNames {
4003 \property ChordNames.chordChanges = ##t
4005 \context Staff \transpose c c' \scheme
4010 The default chord name layout is a system for Jazz music, proposed by
4011 Klaus Ignatzek (see @ref{Literature}). It can be tuned through the
4012 following properties:
4015 @cindex chordNameExceptions
4016 @item chordNameExceptions
4017 This is a list that contains the chords that have special formatting.
4019 @inputfileref{input/regression,chord-name-exceptions.ly}.
4020 @cindex exceptions, chord names.
4023 @cindex majorSevenSymbol
4024 @item majorSevenSymbol
4025 This property contains the markup object used for the 7th step, when
4026 it is major. Predefined options are @code{whiteTriangleMarkup} and
4027 @code{blackTriangleMarkup}. See
4028 @inputfileref{input/regression,chord-name-major7.ly} for an example.
4030 @cindex chordNameSeparator
4031 @item chordNameSeparator
4032 Different parts of a chord name are normally separated by a
4033 slash. By setting @code{chordNameSeparator}, you can specify other
4035 @lilypond[fragment,verbatim]
4036 \context ChordNames \chords {
4038 \property ChordNames.chordNameSeparator
4039 = \markup { \typewriter "|" }
4043 @cindex chordRootNamer
4044 @item chordRootNamer
4045 The root of a chord is usually printed as a letter with an optional
4046 alteration. The transformation from pitch to letter is done by this
4047 function. Special note names (for example, the German ``H'' for a
4048 B-chord) can be produced by storing a new function in this property.
4050 @cindex chordNoteNamer
4051 @item chordNoteNamer
4052 The default is to print single pitch, e.g. the bass note, using the
4053 @code{chordRootNamer}. The @code{chordNoteNamer} property can be set
4054 to a specialized function to change this behavior. For example, the
4055 base can be printed in lower case.
4060 There are also two other chord name schemes implemented: an alternate
4061 Jazz chord notation, and a systematic scheme called Banter chords. The
4062 alternate jazz notation is also shown on the chart in @ref{Chord name
4063 chart}. Turning on these styles is described in the input file
4064 @inputfileref{input/test/,chord-names-jazz.ly}.
4068 @cindex chords, jazz
4073 @cindex @code{\germanChords}
4074 @code{\germanChords},
4075 @cindex @code{\semiGermanChords}
4076 @code{\semiGermanChords}.
4083 @inputfileref{input/regression,chord-name-major7.ly},
4084 @inputfileref{input/regression,chord-name-exceptions.ly},
4085 @inputfileref{input/test,chord-names-jazz.ly},
4086 @inputfileref{input/test,chord-names-german.ly},
4087 @file{scm/chords-ignatzek.scm}, and @file{scm/chord-entry.scm}.
4092 Chord names are determined solely from the list of pitches. Chord
4093 inversions are not identified, and neither are added bass notes. This
4094 may result in strange chord names when chords are entered with the
4095 @code{< .. >} syntax.
4100 @node Orchestral music
4101 @section Orchestral music
4103 @cindex Writing parts
4105 Orchestral music involves some special notation, both in the full
4106 score and the individual parts. This section explains how to tackle
4107 some common problems in orchestral music.
4112 * Multiple staff contexts::
4115 * Instrument names::
4117 * Multi measure rests::
4118 * Automatic part combining::
4120 * Different editions from one source::
4121 * Sound output for transposing instruments::
4124 @node Multiple staff contexts
4125 @subsection Multiple staff contexts
4127 Polyphonic scores consist of many staves. These staves can be
4128 constructed in three different ways:
4130 @item The group is started with a brace at the left. This is done with the
4131 @internalsref{GrandStaff} context.
4132 @item The group is started with a bracket. This is done with the
4133 @internalsref{StaffGroup} context
4134 @item The group is started with a vertical line. This is the default
4138 @cindex Staff, multiple
4139 @cindex bracket, vertical
4140 @cindex brace, vertical
4147 @node Rehearsal marks
4148 @subsection Rehearsal marks
4149 @cindex Rehearsal marks
4151 @cindex @code{\mark}
4153 To print a rehearsal mark, use the @code{\mark} command:
4154 @lilypond[fragment,verbatim]
4164 The mark is incremented automatically if you use @code{\mark
4165 \default}. The value to use is stored in the property
4166 @code{rehearsalMark} is used and automatically incremented.
4168 The @code{\mark} command can also be used to put signs like coda,
4169 segno and fermatas on a barline. Use @code{\markup} to
4170 to access the appropriate symbol:
4172 @lilypond[fragment,verbatim,relative=1]
4173 c1 \mark \markup { \musicglyph #"scripts-ufermata" }
4177 In this case, during line breaks,
4178 marks must also be printed at the end of the line, and not at the
4179 beginning. Use the following to force that behavior:
4181 \property Score.RehearsalMark \override
4182 #'break-visibility = #begin-of-line-invisible
4185 See @inputfileref{input/test,boxed-molecule.ly} for putting boxes
4191 @cindex barlines, putting symbols on
4195 @internalsref{MarkEvent}, @internalsref{RehearsalMark}, and
4196 @inputfileref{input/test,boxed-molecule.ly}.
4200 @subsection Bar numbers
4204 @cindex measure numbers
4205 @cindex currentBarNumber
4207 Bar numbers are printed by default at the start of the line. The
4208 number itself is stored in the
4209 @code{currentBarNumber} property,
4210 which is normally updated automatically for every measure.
4212 Bar numbers can be typeset at regular intervals instead of at the
4213 beginning of each line. This is illustrated in the following example,
4214 whose source is available as
4215 @inputfileref{input/test,bar-number-regular-interval.ly}:
4217 @lilypondfile[notexidoc]{bar-number-regular-interval.ly}
4222 @internalsref{BarNumber},
4223 @inputfileref{input/test,bar-number-every-five-reset.ly}, and
4224 @inputfileref{input/test,bar-number-regular-interval.ly}.
4228 Bar numbers can collide with the @internalsref{StaffGroup} bracket, if
4229 there is one at the top. To solve this, the
4230 @code{padding} property of @internalsref{BarNumber} can be
4231 used to position the number correctly.
4233 @node Instrument names
4234 @subsection Instrument names
4236 In an orchestral score, instrument names are printed left side of the
4239 This can be achieved by setting @internalsref{Staff}.@code{instrument}
4240 and @internalsref{Staff}.@code{instr}. This will print a string before
4241 the start of the staff. For the first start, @code{instrument} is
4242 used, for the next ones @code{instr} is used:
4244 @lilypond[verbatim,singleline]
4245 \property Staff.instrument = "ploink " { c''4 }
4248 You can also use markup texts to construct more complicated instrument
4251 @lilypond[fragment,verbatim,singleline]
4253 \property Staff.instrument = \markup {
4254 \column < "Clarinetti"
4256 \smaller \musicglyph #"accidentals--1"
4267 @internalsref{InstrumentName}.
4271 When you put a name on a grand staff or piano staff the width of the
4272 brace is not taken into account. You must add extra spaces to the end of
4273 the name to avoid a collision.
4276 @subsection Transpose
4278 @cindex transposition of pitches
4279 @cindex @code{\transpose}
4281 A music expression can be transposed with @code{\transpose}. The syntax
4284 \transpose @var{from} @var{to} @var{musicexpr}
4287 This means that @var{musicexpr} is transposed by the interval
4288 between @var{from} and @var{to}.
4290 @code{\transpose} distinguishes between enharmonic pitches: both
4291 @code{\transpose c cis} or @code{\transpose c des} will transpose up
4292 half a tone. The first version will print sharps and the second
4293 version will print flats:
4295 @lilypond[singleline, verbatim]
4296 mus =\notes { \key d \major cis d fis g }
4297 \score { \notes \context Staff {
4300 \transpose c g' \mus
4301 \transpose c f' \mus
4307 @internalsref{TransposedMusic}, and @internalsref{UntransposableMusic}.
4311 If you want to use both @code{\transpose} and @code{\relative}, then
4312 you must put @code{\transpose} outside of @code{\relative}, since
4313 @code{\relative} will have no effect music that appears inside a
4319 @node Multi measure rests
4320 @subsection Multi measure rests
4321 @cindex multi measure rests
4322 @cindex Rests, multi measure
4326 Multi measure rests are entered using `@code{R}'. It is specifically
4327 meant for full bar rests and for entering parts: the rest can expand to
4328 fill a score with rests, or it can be printed as a single multimeasure
4329 rest. This expansion is controlled by the property
4330 @code{Score.skipBars}. If this is set to true, Lily will not expand
4331 empty measures, and the appropriate number is added automatically:
4333 @lilypond[fragment,verbatim]
4334 \time 4/4 r1 | R1 | R1*2
4335 \property Score.skipBars = ##t R1*17 R1*4
4338 The @code{1} in @code{R1} is similar to the duration notation used for
4339 notes. Hence, for time signatures other than 4/4, you must enter other
4340 durations. This can be done with augmentation dots or fractions:
4342 @lilypond[fragment,verbatim]
4343 \property Score.skipBars = ##t
4351 An @code{R} spanning a single measure is printed as either a whole rest
4352 or a breve, centered in the measure regardless of the time signature.
4354 @cindex text on multi-measure rest
4355 @cindex script on multi-measure rest
4356 @cindex fermata on multi-measure rest
4358 Texts can be added to multi-measure rests by using the
4359 @var{note}-@code{markup} syntax (see @ref{Text markup}). In this case, the number is
4360 replaced. If you need both texts and the number, you must add the
4361 number by hand. A variable (@code{\fermataMarkup}) is provided for
4365 @lilypond[verbatim,fragment]
4367 R2._\markup { "Ad lib" }
4372 @cindex whole rests for a full measure
4376 @internalsref{MultiMeasureRestEvent},
4377 @internalsref{MultiMeasureTextEvent},
4378 @internalsref{MultiMeasureRestMusicGroup}, and
4379 @internalsref{MultiMeasureRest}.
4381 The layout object @internalsref{MultiMeasureRestNumber} is for the
4382 default number, and @internalsref{MultiMeasureRestText} for user
4387 It is not possible to use fingerings (e.g. @code{R1-4}) to put numbers
4388 over multi-measure rests.
4390 @cindex condensing rests
4392 There is no way to automatically condense multiple rests into a single
4393 multimeasure rest. Multi measure rests do not take part in rest
4396 Be careful when entering multimeasure rests followed by whole notes,
4400 will enter two notes lasting four measures each. When @code{skipBars}
4401 is set, then the result will look OK, but the bar numbering will be
4404 @node Automatic part combining
4405 @subsection Automatic part combining
4406 @cindex automatic part combining
4407 @cindex part combiner
4410 Automatic part combining is used to merge two parts of music onto a
4411 staff. It is aimed at typesetting orchestral scores. When the two
4412 parts are identical for a period of time, only one is shown. In
4413 places where the two parts differ, they are typeset as separate
4414 voices, and stem directions are set automatically. Also, solo and
4415 @emph{a due} parts are identified and can be marked.
4419 The syntax for part combining is
4422 \partcombine @var{context} @var{musicexpr1} @var{musicexpr2}
4424 where the pieces of music @var{musicexpr1} and @var{musicexpr2} will be
4425 combined into one context of type @var{context}. The music expressions
4426 must be interpreted by contexts whose names should start with @code{one}
4429 The following example demonstrates the basic functionality of the part
4430 combiner: putting parts on one staff, and setting stem directions and
4433 @lilypond[verbatim,singleline,fragment]
4435 \context Voice=one \partcombine Voice
4436 \context Thread=one \relative c'' {
4439 \context Thread=two \relative c'' {
4445 The first @code{g} appears only once, although it was
4446 specified twice (once in each part). Stem, slur and tie directions are
4447 set automatically, depending whether there is a solo or unisono. The
4448 first part (with context called @code{one}) always gets up stems, and
4449 `solo', while the second (called @code{two}) always gets down stems and
4452 If you just want the merging parts, and not the textual markings, you
4453 may set the property @var{soloADue} to false:
4455 @lilypond[verbatim,singleline,fragment]
4457 \property Staff.soloADue = ##f
4458 \context Voice=one \partcombine Voice
4459 \context Thread=one \relative c'' {
4462 \context Thread=two \relative c'' {
4470 @internalsref{PartCombineMusic},
4471 @internalsref{Thread_devnull_engraver}, and
4472 @internalsref{Voice_devnull_engraver} and @internalsref{A2_engraver}.
4476 The syntax for naming contexts in inconsistent with the syntax for
4479 In @code{soloADue} mode, when the two voices play the same notes on and
4480 off, the part combiner may typeset @code{a2} more than once in a
4483 @lilypond[fragment,singleline]
4485 \context Voice=one \partcombine Voice
4486 \context Thread=one \relative c'' {
4489 \context Thread=two \relative c'' {
4495 The part combiner is rather buggy, and it will be replaced by a better
4496 mechanism in the near future.
4498 @cindex @code{Thread_devnull_engraver}
4499 @cindex @code{Voice_engraver}
4500 @cindex @code{A2_engraver}
4503 @subsection Hiding staves
4505 @cindex Frenched scores
4506 @cindex Hiding staves
4508 In orchestral scores, staff lines that only have rests are usually
4509 removed. This saves some space. This style is called `French Score'.
4510 For @internalsref{Lyrics}, @internalsref{LyricsVoice},
4511 @internalsref{ChordNames} and @internalsref{FiguredBass}, this is
4512 switched on by default. When these line of these contexts turn out
4513 empty after the line-breaking process, they are removed.
4515 For normal staves, a specialized @internalsref{Staff} context is
4516 available, which does the same: staves containing nothing (or only
4517 multi measure rests) are removed. The context definition is stored in
4518 @code{\RemoveEmptyStaffContext} variable. Observe how the second staff
4519 in this example disappears in the second line:
4524 \notes \relative c' <<
4525 \new Staff { e4 f g a \break c1 }
4526 \new Staff { c4 d e f \break R1 }
4530 \translator { \RemoveEmptyStaffContext }
4535 In orchestral scores, the first page usually shows all staffs in
4536 full. To prevent empty staffs from being discarded from the first
4537 page, set @code{remove-first} to false in
4538 @internalsref{RemoveEmptyVerticalGroup}.
4540 @node Different editions from one source
4541 @subsection Different editions from one source
4543 The @code{\tag} command marks music expressions with a name. These
4544 tagged expressions can be filtered out later. With this mechanism it
4545 is possible to make different versions of the same music source.
4547 In the following example, we see two versions of a piece of music, one
4548 for the full score, and one with cue notes for the instrumental part:
4556 \property Voice.fontSize = #-1
4564 The same can be applied to articulations, texts, etc.: they are
4567 -\tag #@var{your-tag}
4569 to an articulation, for example,
4574 This defines a note with a conditional fingering indication.
4576 By applying the @code{remove-tag} function, tagged expressions can be
4577 filtered. For example,
4581 \apply #(remove-tag 'score) @var{the music}
4582 \apply #(remove-tag 'part) @var{the music}
4587 @lilypondfile[notexidoc]{tag-filter.ly}
4589 The argument of the @code{\tag} command should be a symbol, or a list
4590 of symbols, for example,
4592 \tag #'(original-part transposed-part) @dots{}
4597 @inputfileref{input/regression,tag-filter.ly}
4600 @node Sound output for transposing instruments
4601 @subsection Sound output for transposing instruments
4603 When you want to make a MIDI file from a score containing transposed
4604 and untransposed instruments, you have to instruct LilyPond the pitch
4605 offset (in semitones) for the transposed instruments. This is done
4606 using the @code{transposing} property. It does not affect printed
4609 @cindex @code{transposing}
4612 \property Staff.instrument = #"Cl. in B-flat"
4613 \property Staff.transposing = #-2
4617 @node Ancient notation
4618 @section Ancient notation
4620 @cindex Vaticana, Editio
4621 @cindex Medicaea, Editio
4626 @c [TODO: write more comprehensive introduction on ancient notation]
4628 Support for ancient notation is still under heavy development.
4629 Regardless of all of the current limitations (see the bugs section
4630 below for details), it includes features for mensural
4631 notation and Gregorian Chant notation. There is also limited support
4632 for figured bass notation.
4634 Many graphical objects provide a @code{style} property, see
4635 @ref{Ancient note heads}, @ref{Ancient accidentals}, @ref{Ancient
4636 rests}, @ref{Ancient clefs}, @ref{Ancient flags} and @ref{Ancient time
4637 signatures}. By manipulating such a grob property, the typographical
4638 appearance of the affected graphical objects can be accomodated for a
4639 specific notation flavour without need for introducing any new
4643 Other aspects of ancient notation can not that easily be expressed as
4644 in terms of just changing a style property of a graphical object.
4645 Therefore, some notational concepts are introduced specifically for
4646 ancient notation, see @ref{Custodes}, @ref{Divisiones},
4647 @ref{Ligatures}, and @ref{Figured bass}.
4651 * Ancient note heads::
4652 * Ancient accidentals::
4656 * Ancient time signatures::
4661 * Vaticana style contexts::
4664 If this all is way too much of documentation for you, and you just
4665 want to dive into typesetting without worrying too much about the
4666 details on how to customize a context, then you may have a look at the
4667 predefined contexts (see @ref{Vaticana style contexts}). Use them to
4668 set up predefined style-specific voice and staff contexts, and
4669 directly go ahead with the note entry.
4673 Ligatures need special spacing that has not yet been implemented. As
4674 a result, there is too much space between ligatures most of the time,
4675 and line breaking often is unsatisfactory. Also, lyrics do not
4676 correctly align with ligatures.
4678 Accidentals must not be printed within a ligature, but instead need to
4679 be collected and printed in front of it.
4681 Augmentum dots within ligatures are not handled correctly.
4684 @node Ancient note heads
4685 @subsection Ancient note heads
4691 For ancient notation, a note head style other than the @code{default}
4692 style may be chosen. This is accomplished by setting the @code{style}
4693 property of the NoteHead object to the desired value (@code{baroque},
4694 @code{neo_mensural} or @code{mensural}). The @code{baroque} style
4695 differs from the @code{default} style only in using a square shape for
4696 @code{\breve} note heads. The @code{neo_mensural} style differs from
4697 the @code{baroque} style in that it uses rhomboidal heads for whole
4698 notes and all smaller durations. Stems are centered on the note
4699 heads. This style is in particular useful when transcribing mensural
4700 music, e.g. for the incipit. The @code{mensural} style finally
4701 produces note heads that mimick the look of note heads in historic
4702 printings of the 16th century.
4704 The following example demonstrates the @code{neo_mensural} style:
4706 @lilypond[fragment,singleline,verbatim]
4707 \property Voice.NoteHead \set #'style = #'neo_mensural
4708 a'\longa a'\breve a'1 a'2 a'4 a'8 a'16
4711 When typesetting a piece in Gregorian Chant notation, a Gregorian
4712 ligature engraver will automatically select the proper note heads,
4713 such there is no need to explicitly set the note head style. Still,
4714 the note head style can be set e.g. to @code{vaticana_punctum} to
4715 produce punctum neumes. Similarly, a mensural ligature engraver is
4716 used to automatically assemble mensural ligatures. See
4717 @ref{Ligatures} for how ligature engravers work.
4721 @inputfileref{input/regression,note-head-style.ly} gives an overview
4722 over all available note head styles.
4724 @ref{Percussion staves} use note head styles of their own that are
4725 frequently used in contemporary music notation.
4727 @node Ancient accidentals
4728 @subsection Ancient accidentals
4734 Use the @code{style} property of grob @internalsref{Accidental} to
4735 select ancient accidentals. Supported styles are
4736 @code{mensural}, @code{vaticana}, @code{hufnagel} and @code{medicaea}.
4738 @lilypond[singleline,26pt]
4746 { " " \musicglyph #"accidentals-vaticana-1"
4747 " " \musicglyph #"accidentals-vaticana0" }
4751 { " " \musicglyph #"accidentals-medicaea-1" }
4755 { " " \musicglyph #"accidentals-hufnagel-1" }
4759 { " " \musicglyph #"accidentals-mensural-1"
4760 " " \musicglyph #"accidentals-mensural1" }
4769 \remove "Bar_number_engraver"
4773 \remove "Clef_engraver"
4774 \remove "Key_engraver"
4775 \remove "Time_signature_engraver"
4776 \remove "Staff_symbol_engraver"
4777 minimumVerticalExtent = ##f
4783 As shown, not all accidentals are supported by each style. When
4784 trying to access an unsupported accidental, LilyPond will switch to a
4785 different style, as demonstrated in
4786 @inputfileref{input/test,ancient-accidentals.ly}.
4788 Similarly to local accidentals, the style of the key signature can be
4789 controlled by the @code{style} property of the
4790 @internalsref{KeySignature} grob.
4794 @ref{Pitches}, @ref{Chromatic alterations} and @ref{Accidentals} give
4795 a general introduction into the use of accidentals. @ref{Key
4796 signature} gives a general introduction into the use of key
4801 @subsection Ancient rests
4807 Use the @code{style} property of grob @internalsref{Rest} to select
4808 ancient accidentals. Supported styles are @code{classical},
4809 @code{neo_mensural} and @code{mensural}. @code{classical} differs
4810 from the @code{default} style only in that the quarter rest looks like
4811 a horizontally mirrored 8th rest. The @code{neo_mensural} style suits
4812 well for e.g. the incipit of a transcribed mensural piece of music.
4813 The @code{mensural} style finally mimicks the appearance of rests as
4814 in historic prints of the 16th century.
4816 The following example demonstrates the @code{neo_mensural} style:
4818 @lilypond[fragment,singleline,verbatim]
4819 \property Voice.Rest \set #'style = #'neo_mensural
4820 r\longa r\breve r1 r2 r4 r8 r16
4823 There are no 32th and 64th rests specifically for the mensural or
4824 neo-mensural style. Instead, the rests from the default style will be
4825 taken. See @inputfileref{input/test,rests.ly} for a chart of all
4828 There are no rests in Gregorian Chant notation; instead, it uses
4833 @ref{Rests} gives a general introduction into the use of rests.
4837 @subsection Ancient clefs
4843 LilyPond supports a variety of clefs, many of them ancient.
4845 The following table shows all ancient clefs that are supported via the
4846 @code{\clef} command. Some of the clefs use the same glyph, but
4847 differ only with respect to the line they are printed on. In such
4848 cases, a trailing number in the name is used to enumerate these clefs.
4849 Still, you can manually force a clef glyph to be typeset on an
4850 arbitrary line, as described in @ref{Clef}. The note printed to the
4851 right side of each clef in the example column denotes the @code{c'}
4852 with respect to that clef.
4854 @multitable @columnfractions .3 .3 .3 .1
4858 @b{Description} @tab
4859 @b{Supported Clefs} @tab
4863 @code{clefs-neo_mensural_c} @tab
4864 modern style mensural C clef @tab
4865 @code{neo_mensural_c1}, @code{neo_mensural_c2},
4866 @code{neo_mensural_c3}, @code{neo_mensural_c4} @tab
4867 @lilypond[relative 0, notime]
4868 \property Staff.TimeSignature \set #'transparent = ##t
4869 \clef "neo_mensural_c2" c
4873 @code{clefs-petrucci_c1}
4874 @code{clefs-petrucci_c2}
4875 @code{clefs-petrucci_c3}
4876 @code{clefs-petrucci_c4}
4877 @code{clefs-petrucci_c5}
4880 petrucci style mensural C clefs, for use on different stafflines
4881 (the examples shows the 2nd staffline C clef).
4891 @lilypond[relative 0, notime]
4892 \property Staff.TimeSignature \set #'transparent = ##t
4893 \clef "petrucci_c2" c
4897 @code{clefs-petrucci_f} @tab
4898 petrucci style mensural F clef @tab
4899 @code{petrucci_f} @tab
4900 @lilypond[relative 0, notime]
4901 \property Staff.TimeSignature \set #'transparent = ##t
4902 \clef "petrucci_f" c
4906 @code{clefs-petrucci_g} @tab
4907 petrucci style mensural G clef @tab
4908 @code{petrucci_g} @tab
4909 @lilypond[relative 0, notime]
4910 \property Staff.TimeSignature \set #'transparent = ##t
4911 \clef "petrucci_g" c
4915 @code{clefs-mensural_c} @tab
4916 historic style mensural C clef @tab
4917 @code{mensural_c1}, @code{mensural_c2}, @code{mensural_c3},
4918 @code{mensural_c4} @tab
4919 @lilypond[relative 0, notime]
4920 \property Staff.TimeSignature \set #'transparent = ##t
4921 \clef "mensural_c2" c
4925 @code{clefs-mensural_f} @tab
4926 historic style mensural F clef @tab
4927 @code{mensural_f} @tab
4928 @lilypond[relative 0, notime]
4929 \property Staff.TimeSignature \set #'transparent = ##t
4930 \clef "mensural_f" c
4934 @code{clefs-mensural_g} @tab
4935 historic style mensural G clef @tab
4936 @code{mensural_g} @tab
4937 @lilypond[relative 0, notime]
4938 \property Staff.TimeSignature \set #'transparent = ##t
4939 \clef "mensural_g" c
4943 @code{clefs-vaticana_do} @tab
4944 Editio Vaticana style do clef @tab
4945 @code{vaticana_do1}, @code{vaticana_do2}, @code{vaticana_do3} @tab
4946 @lilypond[relative 0, notime]
4948 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4949 \property Staff.TimeSignature \set #'transparent = ##t
4950 \clef "vaticana_do2" c
4954 @code{clefs-vaticana_fa} @tab
4955 Editio Vaticana style fa clef @tab
4956 @code{vaticana_fa1}, @code{vaticana_fa2} @tab
4957 @lilypond[relative 0, notime]
4959 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4960 \property Staff.TimeSignature \set #'transparent = ##t
4961 \clef "vaticana_fa2" c
4965 @code{clefs-medicaea_do} @tab
4966 Editio Medicaea style do clef @tab
4967 @code{medicaea_do1}, @code{medicaea_do2}, @code{medicaea_do3} @tab
4968 @lilypond[relative 0, notime]
4970 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4971 \property Staff.TimeSignature \set #'transparent = ##t
4972 \clef "medicaea_do2" c
4976 @code{clefs-medicaea_fa} @tab
4977 Editio Medicaea style fa clef @tab
4978 @code{medicaea_fa1}, @code{medicaea_fa2} @tab
4979 @lilypond[relative 0, notime]
4981 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4982 \property Staff.TimeSignature \set #'transparent = ##t
4983 \clef "medicaea_fa2" c
4987 @code{clefs-hufnagel_do} @tab
4988 historic style hufnagel do clef @tab
4989 @code{hufnagel_do1}, @code{hufnagel_do2}, @code{hufnagel_do3} @tab
4990 @lilypond[relative 0, notime]
4992 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
4993 \property Staff.TimeSignature \set #'transparent = ##t
4994 \clef "hufnagel_do2" c
4998 @code{clefs-hufnagel_fa} @tab
4999 historic style hufnagel fa clef @tab
5000 @code{hufnagel_fa1}, @code{hufnagel_fa2} @tab
5001 @lilypond[relative 0, notime]
5003 \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #4
5004 \property Staff.TimeSignature \set #'transparent = ##t
5005 \clef "hufnagel_fa2" c
5009 @code{clefs-hufnagel_do_fa} @tab
5010 historic style hufnagel combined do/fa clef @tab
5011 @code{hufnagel_do_fa} @tab
5012 @lilypond[relative 0, notime]
5013 \property Staff.TimeSignature \set #'transparent = ##t
5014 \clef "hufnagel_do_fa" c
5019 @c --- This should go somewhere else: ---
5020 @c @item modern style percussion clef (glyph: @code{clefs-percussion})
5023 @c @code{percussion}
5025 @c @lilypond{\property Staff.TimeSignature \set #'transparent = ##t \clef "percussion" c'}
5027 @c @item modern style tab clef (glyph: @code{clefs-tab})
5032 @c @lilypond{\context Staff \outputproperty #(make-type-checker 'staff-symbol-interface) #'line-count = #6 \property Staff.TimeSignature \set #'transparent = ##t \clef "tab" c'}
5034 @emph{Modern style} means ``as is typeset in contemporary editions of
5035 transcribed mensural music''.
5037 @emph{Petrucci style} means ``inspired by printings published by the
5038 famous engraver Petrucci (1466-1539)''.
5040 @emph{Historic style} means ``as was typeset or written in historic
5041 editions (other than those of Petrucci)''.
5043 @emph{Editio XXX style} means ``as is/was printed in Editio XXX''.
5045 Petrucci used C clefs with differently balanced left-side vertical
5046 beams, depending on which staffline it is printed.
5050 For modern clefs, see @ref{Clef}. For the percussion clef, see
5051 @ref{Percussion staves}. For the @code{TAB} clef, see
5056 @subsection Ancient flags
5062 Use the @code{flag-style} property of grob @internalsref{Stem} to
5063 select ancient flags. Besides the @code{default} flag style,
5064 only @code{mensural} style is supported:
5066 @lilypond[fragment,singleline,verbatim]
5067 \property Voice.Stem \set #'flag-style = #'mensural
5068 \property Voice.Stem \set #'thickness = #1.0
5069 \property Voice.NoteHead \set #'style = #'mensural
5071 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
5072 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5075 Note that the innermost flare of each mensural flag always is
5076 vertically aligned with a staff line. If you do not like this
5077 behaviour, you can set the @code{adjust-if-on-staffline} property of
5078 grob @internalsref{Stem} to @code{##f}. Then, the vertical position
5079 of the end of each flare is different between notes on staff lines and
5080 notes between staff lines:
5082 @lilypond[fragment,singleline]
5083 \property Voice.Stem \set #'flag-style = #'mensural
5084 \property Voice.Stem \set #'thickness = #1.0
5085 \property Voice.Stem \set #'adjust-if-on-staffline = ##f
5086 \property Voice.NoteHead \set #'style = #'mensural
5088 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
5089 c''8 d''8 e''8 f''8 c''16 d''16 e''16 f''16 c''32 d''32 e''32 f''32
5092 There is no particular flag style for neo-mensural notation. Hence,
5093 when typesetting e.g. the incipit of a transcibed piece of mensural
5094 music, the default flag style should be used. There are no flags in
5095 Gregorian Chant notation.
5098 @node Ancient time signatures
5099 @subsection Ancient time signatures
5101 @cindex time signatures
5105 There is limited support for mensural time signatures. The
5106 glyphs are hard-wired to particular time fractions. In other words,
5107 to get a particular mensural signature glyph with the @code{\time n/m}
5108 command, @code{n} and @code{m} have to be chosen according to the
5114 \property Score.timing = ##f
5115 \property Score.barAlways = ##t
5116 s_\markup { "$\\backslash$time 4/4" }
5117 ^\markup { " " \musicglyph #"timesig-neo\_mensural4/4" }
5119 s_\markup { "$\\backslash$time 2/2" }
5120 ^\markup { " " \musicglyph #"timesig-neo\_mensural2/2" }
5122 s_\markup { "$\\backslash$time 6/4" }
5123 ^\markup { " " \musicglyph #"timesig-neo\_mensural6/4" }
5125 s_\markup { "$\\backslash$time 6/8" }
5126 ^\markup { " " \musicglyph #"timesig-neo\_mensural6/8" }
5128 s_\markup { "$\\backslash$time 3/2" }
5129 ^\markup { " " \musicglyph #"timesig-neo\_mensural3/2" }
5131 s_\markup { "$\\backslash$time 3/4" }
5132 ^\markup { " " \musicglyph #"timesig-neo\_mensural3/4" }
5134 s_\markup { "$\\backslash$time 9/4" }
5135 ^\markup { " " \musicglyph #"timesig-neo\_mensural9/4" }
5137 s_\markup { "$\\backslash$time 9/8" }
5138 ^\markup { " " \musicglyph #"timesig-neo\_mensural9/8" }
5140 s_\markup { "$\\backslash$time 4/8" }
5141 ^\markup { " " \musicglyph #"timesig-neo\_mensural4/8" }
5143 s_\markup { "$\\backslash$time 2/4" }
5144 ^\markup { " " \musicglyph #"timesig-neo\_mensural2/4" }
5152 \remove Staff_symbol_engraver
5153 \remove Clef_engraver
5154 \remove Time_signature_engraver
5160 Use the @code{style} property of grob @internalsref{TimeSignature} to
5161 select ancient time signatures. Supported styles are
5162 @code{neo_mensural} and @code{mensural}. The above table uses the
5163 @code{neo_mensural} style. This style is appropriate e.g. for the
5164 incipit of transcriptions of mensural pieces. The @code{mensural}
5165 style mimicks the look of historical printings of the 16th century.
5167 @inputfileref{input/test,time.ly} gives an overview over all available
5168 ancient and modern styles.
5172 @ref{Time signature} gives a general introduction into the use of time
5177 Mensural signature glyphs are mapped to time fractions in a
5178 hard-wired way. This mapping is sensible, but still arbitrary: given
5179 a mensural time signature, the time fraction represents a modern meter
5180 that usually will be a good choice when transcribing a mensural piece
5181 of music. For a particular piece of mensural music, however, the
5182 mapping may be unsatisfactory. In particular, the mapping assumes a
5183 fixed transcription of durations (e.g. brevis = half note in 2/2,
5184 i.e. 4:1). Some glyphs (such as the alternate glyph for 6/8 meter)
5185 are not at all accessible through the @code{\time} command.
5187 Mensural time signatures are supported typographically, but not yet
5188 musically. The internal representation of durations is
5189 based on a purely binary system; a ternary division such as 1 brevis =
5190 3 semibrevis (tempus perfectum) or 1 semibrevis = 3 minima (cum
5191 prolatione maiori) is not correctly handled: event times in ternary
5192 modes will be badly computed, resulting e.g. in horizontally
5193 misaligned note heads, and bar checks are likely to erroneously fail.
5195 The syntax and semantics of the @code{\time} command for mensural
5196 music is subject to change.
5199 @subsection Custodes
5204 A @emph{custos} (plural: @emph{custodes}; latin word for `guard') is a
5205 symbol that appears at the end of a staff. It anticipates the pitch
5206 of the first note(s) of the following line and thus helps the player
5207 or singer to manage line breaks during performance, thus enhancing
5208 readability of a score.
5210 Custodes were frequently used in music notation until the 17th
5211 century. Nowadays, they have survived only in a few particular forms
5212 of musical notation such as contemporary editions of Gregorian chant
5213 like the @emph{editio vaticana}. There are different custos glyphs
5214 used in different flavours of notational style.
5218 For typesetting custodes, just put a @internalsref{Custos_engraver} into the
5219 @internalsref{Staff} context when declaring the @code{\paper} block,
5220 as shown in the following example:
5226 \consists Custos_engraver
5227 Custos \override #'style = #'mensural
5232 The result looks like this:
5238 \property Staff.Custos \set #'style = #'mensural
5245 \consists Custos_engraver
5252 The custos glyph is selected by the @code{style} property. The styles
5253 supported are @code{vaticana}, @code{medicaea}, @code{hufnagel} and
5254 @code{mensural}. They are demonstrated in the following fragment:
5264 { " " \musicglyph #"custodes-vaticana-u0" }
5268 { " " \musicglyph #"custodes-medicaea-u0" }
5272 { " " \musicglyph #"custodes-hufnagel-u0" }
5276 { " " \musicglyph #"custodes-mensural-u0" }
5285 \remove "Bar_number_engraver"
5289 \remove "Clef_engraver"
5290 \remove "Key_engraver"
5291 \remove "Time_signature_engraver"
5292 \remove "Staff_symbol_engraver"
5293 minimumVerticalExtent = ##f
5299 If the boolean property @code{adjust-if-on-staffline} is set to
5300 @code{#t} (which it is by default), lily typesets slightly different
5301 variants of the custos glyph, depending on whether the custos, is
5302 typeset on or between stafflines. The glyph will
5303 optically fit well into the staff, with the appendage on the right of
5304 the custos always ending at the same vertical position between two
5305 stafflines regardless of the pitch. If you set
5306 @code{adjust-if-on-staffline} to @code{#f}, then
5307 a compromise between both forms is used.
5309 Just like stems can be attached to noteheads in two directions
5310 @emph{up} and @emph{down}, each custos glyph is available with its
5311 appendage pointing either up or down. If the pitch of a custos is
5312 above a selectable position, the appendage will point downwards; if
5313 the pitch is below this position, the appendage will point upwards.
5314 Use property @code{neutral-position} to select this position. By
5315 default, it is set to @code{0}, such that the neutral position is the
5316 center of the staff. Use property @code{neutral-direction} to control
5317 what happens if a custos is typeset on the neutral position itself.
5318 By default, this property is set to @code{-1}, such that the appendage
5319 will point downwards. If set to @code{1}, the appendage will point
5320 upwards. Other values such as @code{0} are reserved for future
5321 extensions and should not be used.
5325 @internalsref{Custos} and @inputfileref{input/regression,custos.ly}.
5329 @subsection Divisiones
5335 A @emph{divisio} (plural: @emph{divisiones}; latin word for
5336 `division') is a staff context symbol that is used to structure
5337 Gregorian music into phrases and sections. The musical meaning of
5338 @emph{divisio minima}, @emph{divisio maior} and @emph{divisio maxima}
5339 can be characterized as short, medium and long pause, somewhat like
5340 @ref{Breath marks}. The @emph{finalis} sign not only marks the end of
5341 a chant, but is also frequently used within a single
5342 antiphonal/responsorial chant to mark the end of each section.
5346 To use divisiones, include the file @code{gregorian-init.ly}. It
5347 contains definitions that you can apply by just inserting
5348 @code{\divisioMinima}, @code{\divisioMaior}, @code{\divisioMaxima},
5349 and @code{\finalis} at proper places in the input. Some editions use
5350 @emph{virgula} or @emph{caesura} instead of divisio minima.
5351 Therefore, @code{gregorian-init.ly} also defines @code{\virgula} and
5354 @lilypondfile[notexidoc]{divisiones.ly}
5358 @cindex @code{\virgula}
5360 @cindex @code{\caesura}
5362 @cindex @code{\divisioMinima}
5363 @code{\divisioMinima},
5364 @cindex @code{\divisioMaior}
5365 @code{\divisioMaior},
5366 @cindex @code{\divisioMaxima}
5367 @code{\divisioMaxima},
5368 @cindex @code{\finalis}
5373 @internalsref{BreathingSign}, @internalsref{BreathingSignEvent},
5374 @inputfileref{input/test,divisiones.ly}, and @ref{Breath marks}.
5377 @subsection Ligatures
5381 @c TODO: Should double check if I recalled things correctly when I wrote
5382 @c down the following paragraph by heart.
5384 In musical terminology, a ligature is a coherent graphical symbol that
5385 represents at least two distinct notes. Ligatures originally appeared
5386 in the manuscripts of Gregorian chant notation roughly since the 9th
5387 century as an allusion to the accent symbols of greek lyric poetry to
5388 denote ascending or descending sequences of notes. Both, the shape
5389 and the exact meaning of ligatures changed tremendously during the
5390 following centuries: In early notation, ligatures were used for
5391 monophonic tunes (Gregorian chant) and very soon denoted also the way
5392 of performance in the sense of articulation. With upcoming
5393 multiphony, the need for a metric system arised, since multiple voices
5394 of a piece have to be synchronized some way. New notation systems
5395 were invented that used the manifold shapes of ligatures to now denote
5396 rhythmical patterns (e.g. black mensural notation, mannered notation,
5397 ars nova). With the invention of the metric system of the white
5398 mensural notation, the need for ligatures to denote such patterns
5399 disappeared. Nevertheless, ligatures were still in use in the
5400 mensural system for a couple of decades until they finally disappeared
5401 during the late 16th / early 17th century. Still, ligatures have
5402 survived in contemporary editions of Gregorian chant such as the
5403 Editio Vaticana from 1905/08.
5407 Syntactically, ligatures are simply enclosed by @code{\[} and
5408 @code{\]}. Some ligature styles (such as Editio Vaticana) may need
5409 additional input syntax specific for this particular type of ligature.
5410 By default, the @internalsref{LigatureBracket} engraver just puts a
5411 square bracket above the ligature:
5413 @lilypond[singleline,verbatim]
5415 \notes \transpose c c' {
5423 To select a specific style of ligatures, a proper ligature engraver
5424 has to be added to the @internalsref{Voice} context, as explained in
5425 the following subsections. Only white mensural ligatures
5426 are supported with certain limitations. Support for Editio Vaticana
5427 will be added in the future.
5430 * White mensural ligatures::
5431 * Gregorian square neumes ligatures::
5434 @node White mensural ligatures
5435 @subsubsection White mensural ligatures
5437 @cindex Mensural ligatures
5438 @cindex White mensural ligatures
5440 There is limited support for white mensural ligatures. The
5441 implementation is still experimental; it may output strange
5442 warnings or even crash in some cases or produce weird results on more
5447 To engrave white mensural ligatures, in the paper block the
5448 @internalsref{Mensural_ligature_engraver} has to be put into the
5449 @internalsref{Voice} context, and remove the
5450 @internalsref{Ligature_bracket_engraver}:
5456 \remove Ligature_bracket_engraver
5457 \consists Mensural_ligature_engraver
5462 There is no additional input language to describe the shape of a
5463 white mensural ligature. The shape is rather determined solely from
5464 the pitch and duration of the enclosed notes. While this approach may
5465 take a new user a while to get accustomed, it has the great advantage
5466 that the full musical information of the ligature is known internally.
5467 This is not only required for correct MIDI output, but also allows for
5468 automatic transcription of the ligatures.
5473 \property Score.timing = ##f
5474 \property Score.defaultBarType = "empty"
5475 \property Voice.NoteHead \set #'style = #'neo_mensural
5476 \property Staff.TimeSignature \set #'style = #'neo_mensural
5478 \[ g\longa c\breve a\breve f\breve d'\longa \]
5480 \[ e1 f1 a\breve g\longa \]
5482 @lilypond[singleline]
5484 \notes \transpose c c' {
5485 \property Score.timing = ##f
5486 \property Score.defaultBarType = "empty"
5487 \property Voice.NoteHead \set #'style = #'neo_mensural
5488 \property Staff.TimeSignature \set #'style = #'neo_mensural
5490 \[ g\longa c\breve a\breve f\breve d'\longa \]
5492 \[ e1 f1 a\breve g\longa \]
5497 \remove Ligature_bracket_engraver
5498 \consists Mensural_ligature_engraver
5504 Without replacing @internalsref{Ligature_bracket_engraver} with
5505 @internalsref{Mensural_ligature_engraver}, the same music transcribes
5508 @lilypond[singleline]
5510 \notes \transpose c c' {
5511 \property Score.timing = ##f
5512 \property Score.defaultBarType = "empty"
5513 \property Voice.NoteHead \set #'style = #'neo_mensural
5514 \property Staff.TimeSignature \set #'style = #'neo_mensural
5516 \[ g\longa c\breve a\breve f\breve d'\longa \]
5518 \[ e1 f1 a\breve g\longa \]
5524 @node Gregorian square neumes ligatures
5525 @subsubsection Gregorian square neumes ligatures
5527 @cindex Square neumes ligatures
5528 @cindex Gregorian square neumes ligatures
5530 Gregorian square neumes notation (following the style of the Editio
5531 Vaticana) is under heavy development, but not yet really usable for
5532 production purposes. Core ligatures can already be typeset, but
5533 essential issues for serious typesetting are still under development,
5534 such as (among others) horizontal alignment of multiple ligatures,
5535 lyrics alignment and proper accidentals handling. Still, this section
5536 gives a sneak preview of what Gregorian chant may look like once it
5539 The following table contains the extended neumes table of the 2nd
5540 volume of the Antiphonale Romanum (@emph{Liber Hymnarius}), published
5541 1983 by the monks of Solesmes.
5543 @multitable @columnfractions .4 .2 .2 .2
5546 @b{Neuma aut@*Neumarum Elementa} @tab
5547 @b{Figurae@*Rectae} @tab
5548 @b{Figurae@*Liquescentes Auctae} @tab
5549 @b{Figurae@*Liquescentes Deminutae}
5551 @c TODO: \paper block is identical in all of the below examples.
5552 @c Therefore, it should somehow be included rather than duplicated all
5555 @c why not make identifiers in ly/engraver-init.ly? --hwn
5557 @c Because it's just used to typeset plain notes without
5558 @c a staff for demonstration purposes rather than something
5559 @c special of Gregorian chant notation. --jr
5564 @lilypond[noindent, 26pt, nofragment, linewidth=1.5cm]
5565 \include "gregorian-init.ly"
5567 \notes \transpose c c' {
5570 \noBreak s^\markup {"a"} \noBreak
5572 % Punctum Inclinatum
5574 \noBreak s^\markup {"b"}
5580 \remove "Bar_number_engraver"
5584 \remove "Clef_engraver"
5585 \remove "Key_engraver"
5586 StaffSymbol \set #'transparent = ##t
5587 \remove "Time_signature_engraver"
5588 \remove "Bar_engraver"
5589 minimumVerticalExtent = ##f
5593 \remove Ligature_bracket_engraver
5594 \consists Vaticana_ligature_engraver
5595 NoteHead \set #'style = #'vaticana_punctum
5596 Stem \set #'transparent = ##t
5602 @lilypond[noindent, 26pt, nofragment, linewidth=2.5cm]
5603 \include "gregorian-init.ly"
5605 \notes \transpose c c' {
5606 % Punctum Auctum Ascendens
5607 \[ \auctum \ascendens b \]
5608 \noBreak s^\markup {"c"} \noBreak
5610 % Punctum Auctum Descendens
5611 \[ \auctum \descendens b \]
5612 \noBreak s^\markup {"d"} \noBreak
5614 % Punctum Inclinatum Auctum
5615 \[ \inclinatum \auctum b \]
5616 \noBreak s^\markup {"e"}
5622 \remove "Bar_number_engraver"
5626 \remove "Clef_engraver"
5627 \remove "Key_engraver"
5628 StaffSymbol \set #'transparent = ##t
5629 \remove "Time_signature_engraver"
5630 \remove "Bar_engraver"
5631 minimumVerticalExtent = ##f
5635 \remove Ligature_bracket_engraver
5636 \consists Vaticana_ligature_engraver
5637 NoteHead \set #'style = #'vaticana_punctum
5638 Stem \set #'transparent = ##t
5644 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5645 \include "gregorian-init.ly"
5647 \notes \transpose c c' {
5648 % Punctum Inclinatum Parvum
5649 \[ \inclinatum \deminutum b \]
5650 \noBreak s^\markup {"f"}
5656 \remove "Bar_number_engraver"
5660 \remove "Clef_engraver"
5661 \remove "Key_engraver"
5662 StaffSymbol \set #'transparent = ##t
5663 \remove "Time_signature_engraver"
5664 \remove "Bar_engraver"
5665 minimumVerticalExtent = ##f
5669 \remove Ligature_bracket_engraver
5670 \consists Vaticana_ligature_engraver
5671 NoteHead \set #'style = #'vaticana_punctum
5672 Stem \set #'transparent = ##t
5681 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5682 \include "gregorian-init.ly"
5684 \notes \transpose c c' {
5687 \noBreak s^\markup {"g"}
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
5718 @code{3. Apostropha vel Stropha}
5720 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5721 \include "gregorian-init.ly"
5723 \notes \transpose c c' {
5726 \noBreak s^\markup {"h"}
5732 \remove "Bar_number_engraver"
5736 \remove "Clef_engraver"
5737 \remove "Key_engraver"
5738 StaffSymbol \set #'transparent = ##t
5739 \remove "Time_signature_engraver"
5740 \remove "Bar_engraver"
5741 minimumVerticalExtent = ##f
5745 \remove Ligature_bracket_engraver
5746 \consists Vaticana_ligature_engraver
5747 NoteHead \set #'style = #'vaticana_punctum
5748 Stem \set #'transparent = ##t
5754 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5755 \include "gregorian-init.ly"
5757 \notes \transpose c c' {
5759 \[ \stropha \auctum b \]
5760 \noBreak s^\markup {"i"}
5766 \remove "Bar_number_engraver"
5770 \remove "Clef_engraver"
5771 \remove "Key_engraver"
5772 StaffSymbol \set #'transparent = ##t
5773 \remove "Time_signature_engraver"
5774 \remove "Bar_engraver"
5775 minimumVerticalExtent = ##f
5779 \remove Ligature_bracket_engraver
5780 \consists Vaticana_ligature_engraver
5781 NoteHead \set #'style = #'vaticana_punctum
5782 Stem \set #'transparent = ##t
5792 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5793 \include "gregorian-init.ly"
5795 \notes \transpose c c' {
5798 \noBreak s^\markup {"j"}
5804 \remove "Bar_number_engraver"
5808 \remove "Clef_engraver"
5809 \remove "Key_engraver"
5810 StaffSymbol \set #'transparent = ##t
5811 \remove "Time_signature_engraver"
5812 \remove "Bar_engraver"
5813 minimumVerticalExtent = ##f
5817 \remove Ligature_bracket_engraver
5818 \consists Vaticana_ligature_engraver
5819 NoteHead \set #'style = #'vaticana_punctum
5820 Stem \set #'transparent = ##t
5829 @code{5. Clivis vel Flexa}
5831 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5832 \include "gregorian-init.ly"
5834 \notes \transpose c c' {
5843 \remove "Bar_number_engraver"
5847 \remove "Clef_engraver"
5848 \remove "Key_engraver"
5849 StaffSymbol \set #'transparent = ##t
5850 \remove "Time_signature_engraver"
5851 \remove "Bar_engraver"
5852 minimumVerticalExtent = ##f
5856 \remove Ligature_bracket_engraver
5857 \consists Vaticana_ligature_engraver
5858 NoteHead \set #'style = #'vaticana_punctum
5859 Stem \set #'transparent = ##t
5865 @lilypond[noindent, 26pt, nofragment, linewidth=2.0cm]
5866 \include "gregorian-init.ly"
5868 \notes \transpose c c' {
5869 % Clivis Aucta Descendens
5870 \[ b \flexa \auctum \descendens g \]
5871 \noBreak s^\markup {"l"} \noBreak
5873 % Clivis Aucta Ascendens
5874 \[ b \flexa \auctum \ascendens g \]
5875 \noBreak s^\markup {"m"}
5881 \remove "Bar_number_engraver"
5885 \remove "Clef_engraver"
5886 \remove "Key_engraver"
5887 StaffSymbol \set #'transparent = ##t
5888 \remove "Time_signature_engraver"
5889 \remove "Bar_engraver"
5890 minimumVerticalExtent = ##f
5894 \remove Ligature_bracket_engraver
5895 \consists Vaticana_ligature_engraver
5896 NoteHead \set #'style = #'vaticana_punctum
5897 Stem \set #'transparent = ##t
5903 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5904 \include "gregorian-init.ly"
5906 \notes \transpose c c' {
5908 \[ b \flexa \deminutum g \]
5915 \remove "Bar_number_engraver"
5919 \remove "Clef_engraver"
5920 \remove "Key_engraver"
5921 StaffSymbol \set #'transparent = ##t
5922 \remove "Time_signature_engraver"
5923 \remove "Bar_engraver"
5924 minimumVerticalExtent = ##f
5928 \remove Ligature_bracket_engraver
5929 \consists Vaticana_ligature_engraver
5930 NoteHead \set #'style = #'vaticana_punctum
5931 Stem \set #'transparent = ##t
5938 @code{6. Podatus vel Pes}
5940 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
5941 \include "gregorian-init.ly"
5943 \notes \transpose c c' {
5952 \remove "Bar_number_engraver"
5956 \remove "Clef_engraver"
5957 \remove "Key_engraver"
5958 StaffSymbol \set #'transparent = ##t
5959 \remove "Time_signature_engraver"
5960 \remove "Bar_engraver"
5961 minimumVerticalExtent = ##f
5965 \remove Ligature_bracket_engraver
5966 \consists Vaticana_ligature_engraver
5967 NoteHead \set #'style = #'vaticana_punctum
5968 Stem \set #'transparent = ##t
5974 @lilypond[noindent, 26pt, nofragment, linewidth=2.0cm]
5975 \include "gregorian-init.ly"
5977 \notes \transpose c c' {
5978 % Pes Auctus Descendens
5979 \[ g \pes \auctum \descendens b \]
5980 \noBreak s^\markup {"p"} \noBreak
5982 % Pes Auctus Ascendens
5983 \[ g \pes \auctum \ascendens b \]
5984 \noBreak s^\markup {"q"}
5990 \remove "Bar_number_engraver"
5994 \remove "Clef_engraver"
5995 \remove "Key_engraver"
5996 StaffSymbol \set #'transparent = ##t
5997 \remove "Time_signature_engraver"
5998 \remove "Bar_engraver"
5999 minimumVerticalExtent = ##f
6003 \remove Ligature_bracket_engraver
6004 \consists Vaticana_ligature_engraver
6005 NoteHead \set #'style = #'vaticana_punctum
6006 Stem \set #'transparent = ##t
6012 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6013 \include "gregorian-init.ly"
6015 \notes \transpose c c' {
6017 \[ g \pes \deminutum b \]
6024 \remove "Bar_number_engraver"
6028 \remove "Clef_engraver"
6029 \remove "Key_engraver"
6030 StaffSymbol \set #'transparent = ##t
6031 \remove "Time_signature_engraver"
6032 \remove "Bar_engraver"
6033 minimumVerticalExtent = ##f
6037 \remove Ligature_bracket_engraver
6038 \consists Vaticana_ligature_engraver
6039 NoteHead \set #'style = #'vaticana_punctum
6040 Stem \set #'transparent = ##t
6047 @code{7. Pes Quassus}
6049 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6050 \include "gregorian-init.ly"
6052 \notes \transpose c c' {
6054 \[ \oriscus g \pes \virga b \]
6061 \remove "Bar_number_engraver"
6065 \remove "Clef_engraver"
6066 \remove "Key_engraver"
6067 StaffSymbol \set #'transparent = ##t
6068 \remove "Time_signature_engraver"
6069 \remove "Bar_engraver"
6070 minimumVerticalExtent = ##f
6074 \remove Ligature_bracket_engraver
6075 \consists Vaticana_ligature_engraver
6076 NoteHead \set #'style = #'vaticana_punctum
6077 Stem \set #'transparent = ##t
6083 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6084 \include "gregorian-init.ly"
6086 \notes \transpose c c' {
6087 % Pes Quassus Auctus Descendens
6088 \[ \oriscus g \pes \auctum \descendens b \]
6095 \remove "Bar_number_engraver"
6099 \remove "Clef_engraver"
6100 \remove "Key_engraver"
6101 StaffSymbol \set #'transparent = ##t
6102 \remove "Time_signature_engraver"
6103 \remove "Bar_engraver"
6104 minimumVerticalExtent = ##f
6108 \remove Ligature_bracket_engraver
6109 \consists Vaticana_ligature_engraver
6110 NoteHead \set #'style = #'vaticana_punctum
6111 Stem \set #'transparent = ##t
6119 @code{8. Quilisma Pes}
6121 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6122 \include "gregorian-init.ly"
6124 \notes \transpose c c' {
6126 \[ \quilisma g \pes b \]
6133 \remove "Bar_number_engraver"
6137 \remove "Clef_engraver"
6138 \remove "Key_engraver"
6139 StaffSymbol \set #'transparent = ##t
6140 \remove "Time_signature_engraver"
6141 \remove "Bar_engraver"
6142 minimumVerticalExtent = ##f
6146 \remove Ligature_bracket_engraver
6147 \consists Vaticana_ligature_engraver
6148 NoteHead \set #'style = #'vaticana_punctum
6149 Stem \set #'transparent = ##t
6155 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6156 \include "gregorian-init.ly"
6158 \notes \transpose c c' {
6159 % Quilisma Pes Auctus Descendens
6160 \[ \quilisma g \pes \auctum \descendens b \]
6167 \remove "Bar_number_engraver"
6171 \remove "Clef_engraver"
6172 \remove "Key_engraver"
6173 StaffSymbol \set #'transparent = ##t
6174 \remove "Time_signature_engraver"
6175 \remove "Bar_engraver"
6176 minimumVerticalExtent = ##f
6180 \remove Ligature_bracket_engraver
6181 \consists Vaticana_ligature_engraver
6182 NoteHead \set #'style = #'vaticana_punctum
6183 Stem \set #'transparent = ##t
6191 @code{9. Podatus Initio Debilis}
6193 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6194 \include "gregorian-init.ly"
6196 \notes \transpose c c' {
6197 % Pes Initio Debilis
6198 \[ \deminutum g \pes b \]
6205 \remove "Bar_number_engraver"
6209 \remove "Clef_engraver"
6210 \remove "Key_engraver"
6211 StaffSymbol \set #'transparent = ##t
6212 \remove "Time_signature_engraver"
6213 \remove "Bar_engraver"
6214 minimumVerticalExtent = ##f
6218 \remove Ligature_bracket_engraver
6219 \consists Vaticana_ligature_engraver
6220 NoteHead \set #'style = #'vaticana_punctum
6221 Stem \set #'transparent = ##t
6227 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6228 \include "gregorian-init.ly"
6230 \notes \transpose c c' {
6231 % Pes Auctus Descendens Initio Debilis
6232 \[ \deminutum g \pes \auctum \descendens b \]
6239 \remove "Bar_number_engraver"
6243 \remove "Clef_engraver"
6244 \remove "Key_engraver"
6245 StaffSymbol \set #'transparent = ##t
6246 \remove "Time_signature_engraver"
6247 \remove "Bar_engraver"
6248 minimumVerticalExtent = ##f
6252 \remove Ligature_bracket_engraver
6253 \consists Vaticana_ligature_engraver
6254 NoteHead \set #'style = #'vaticana_punctum
6255 Stem \set #'transparent = ##t
6265 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6266 \include "gregorian-init.ly"
6268 \notes \transpose c c' {
6270 \[ a \pes b \flexa g \]
6277 \remove "Bar_number_engraver"
6281 \remove "Clef_engraver"
6282 \remove "Key_engraver"
6283 StaffSymbol \set #'transparent = ##t
6284 \remove "Time_signature_engraver"
6285 \remove "Bar_engraver"
6286 minimumVerticalExtent = ##f
6290 \remove Ligature_bracket_engraver
6291 \consists Vaticana_ligature_engraver
6292 NoteHead \set #'style = #'vaticana_punctum
6293 Stem \set #'transparent = ##t
6299 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6300 \include "gregorian-init.ly"
6302 \notes \transpose c c' {
6303 % Torculus Auctus Descendens
6304 \[ a \pes b \flexa \auctum \descendens g \]
6311 \remove "Bar_number_engraver"
6315 \remove "Clef_engraver"
6316 \remove "Key_engraver"
6317 StaffSymbol \set #'transparent = ##t
6318 \remove "Time_signature_engraver"
6319 \remove "Bar_engraver"
6320 minimumVerticalExtent = ##f
6324 \remove Ligature_bracket_engraver
6325 \consists Vaticana_ligature_engraver
6326 NoteHead \set #'style = #'vaticana_punctum
6327 Stem \set #'transparent = ##t
6333 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6334 \include "gregorian-init.ly"
6336 \notes \transpose c c' {
6337 % Torculus Deminutus
6338 \[ a \pes b \flexa \deminutum g \]
6345 \remove "Bar_number_engraver"
6349 \remove "Clef_engraver"
6350 \remove "Key_engraver"
6351 StaffSymbol \set #'transparent = ##t
6352 \remove "Time_signature_engraver"
6353 \remove "Bar_engraver"
6354 minimumVerticalExtent = ##f
6358 \remove Ligature_bracket_engraver
6359 \consists Vaticana_ligature_engraver
6360 NoteHead \set #'style = #'vaticana_punctum
6361 Stem \set #'transparent = ##t
6368 @code{11. Torculus Initio Debilis}
6370 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6371 \include "gregorian-init.ly"
6373 \notes \transpose c c' {
6374 % Torculus Initio Debilis
6375 \[ \deminutum a \pes b \flexa g \]
6382 \remove "Bar_number_engraver"
6386 \remove "Clef_engraver"
6387 \remove "Key_engraver"
6388 StaffSymbol \set #'transparent = ##t
6389 \remove "Time_signature_engraver"
6390 \remove "Bar_engraver"
6391 minimumVerticalExtent = ##f
6395 \remove Ligature_bracket_engraver
6396 \consists Vaticana_ligature_engraver
6397 NoteHead \set #'style = #'vaticana_punctum
6398 Stem \set #'transparent = ##t
6404 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6405 \include "gregorian-init.ly"
6407 \notes \transpose c c' {
6408 % Torculus Auctus Descendens Initio Debilis
6409 \[ \deminutum a \pes b \flexa \auctum \descendens g \]
6416 \remove "Bar_number_engraver"
6420 \remove "Clef_engraver"
6421 \remove "Key_engraver"
6422 StaffSymbol \set #'transparent = ##t
6423 \remove "Time_signature_engraver"
6424 \remove "Bar_engraver"
6425 minimumVerticalExtent = ##f
6429 \remove Ligature_bracket_engraver
6430 \consists Vaticana_ligature_engraver
6431 NoteHead \set #'style = #'vaticana_punctum
6432 Stem \set #'transparent = ##t
6438 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6439 \include "gregorian-init.ly"
6441 \notes \transpose c c' {
6442 % Torculus Deminutus Initio Debilis
6443 \[ \deminutum a \pes b \flexa \deminutum g \]
6450 \remove "Bar_number_engraver"
6454 \remove "Clef_engraver"
6455 \remove "Key_engraver"
6456 StaffSymbol \set #'transparent = ##t
6457 \remove "Time_signature_engraver"
6458 \remove "Bar_engraver"
6459 minimumVerticalExtent = ##f
6463 \remove Ligature_bracket_engraver
6464 \consists Vaticana_ligature_engraver
6465 NoteHead \set #'style = #'vaticana_punctum
6466 Stem \set #'transparent = ##t
6473 @code{12. Porrectus}
6475 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6476 \include "gregorian-init.ly"
6478 \notes \transpose c c' {
6480 \[ a \flexa g \pes b \]
6487 \remove "Bar_number_engraver"
6491 \remove "Clef_engraver"
6492 \remove "Key_engraver"
6493 StaffSymbol \set #'transparent = ##t
6494 \remove "Time_signature_engraver"
6495 \remove "Bar_engraver"
6496 minimumVerticalExtent = ##f
6500 \remove Ligature_bracket_engraver
6501 \consists Vaticana_ligature_engraver
6502 NoteHead \set #'style = #'vaticana_punctum
6503 Stem \set #'transparent = ##t
6509 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6510 \include "gregorian-init.ly"
6512 \notes \transpose c c' {
6513 % Porrectus Auctus Descendens
6514 \[ a \flexa g \pes \auctum \descendens b \]
6521 \remove "Bar_number_engraver"
6525 \remove "Clef_engraver"
6526 \remove "Key_engraver"
6527 StaffSymbol \set #'transparent = ##t
6528 \remove "Time_signature_engraver"
6529 \remove "Bar_engraver"
6530 minimumVerticalExtent = ##f
6534 \remove Ligature_bracket_engraver
6535 \consists Vaticana_ligature_engraver
6536 NoteHead \set #'style = #'vaticana_punctum
6537 Stem \set #'transparent = ##t
6543 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6544 \include "gregorian-init.ly"
6546 \notes \transpose c c' {
6547 % Porrectus Deminutus
6548 \[ a \flexa g \pes \deminutum b \]
6555 \remove "Bar_number_engraver"
6559 \remove "Clef_engraver"
6560 \remove "Key_engraver"
6561 StaffSymbol \set #'transparent = ##t
6562 \remove "Time_signature_engraver"
6563 \remove "Bar_engraver"
6564 minimumVerticalExtent = ##f
6568 \remove Ligature_bracket_engraver
6569 \consists Vaticana_ligature_engraver
6570 NoteHead \set #'style = #'vaticana_punctum
6571 Stem \set #'transparent = ##t
6580 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6581 \include "gregorian-init.ly"
6583 \notes \transpose c c' {
6585 \[ \virga b \inclinatum a \inclinatum g \]
6592 \remove "Bar_number_engraver"
6596 \remove "Clef_engraver"
6597 \remove "Key_engraver"
6598 StaffSymbol \set #'transparent = ##t
6599 \remove "Time_signature_engraver"
6600 \remove "Bar_engraver"
6601 minimumVerticalExtent = ##f
6605 \remove Ligature_bracket_engraver
6606 \consists Vaticana_ligature_engraver
6607 NoteHead \set #'style = #'vaticana_punctum
6608 Stem \set #'transparent = ##t
6614 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6615 \include "gregorian-init.ly"
6617 \notes \transpose c c' {
6619 \[ \virga b \inclinatum a \inclinatum \auctum g \]
6626 \remove "Bar_number_engraver"
6630 \remove "Clef_engraver"
6631 \remove "Key_engraver"
6632 StaffSymbol \set #'transparent = ##t
6633 \remove "Time_signature_engraver"
6634 \remove "Bar_engraver"
6635 minimumVerticalExtent = ##f
6639 \remove Ligature_bracket_engraver
6640 \consists Vaticana_ligature_engraver
6641 NoteHead \set #'style = #'vaticana_punctum
6642 Stem \set #'transparent = ##t
6648 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6649 \include "gregorian-init.ly"
6651 \notes \transpose c c' {
6652 % Climacus Deminutus
6653 \[ \virga b \inclinatum a \inclinatum \deminutum g \]
6660 \remove "Bar_number_engraver"
6664 \remove "Clef_engraver"
6665 \remove "Key_engraver"
6666 StaffSymbol \set #'transparent = ##t
6667 \remove "Time_signature_engraver"
6668 \remove "Bar_engraver"
6669 minimumVerticalExtent = ##f
6673 \remove Ligature_bracket_engraver
6674 \consists Vaticana_ligature_engraver
6675 NoteHead \set #'style = #'vaticana_punctum
6676 Stem \set #'transparent = ##t
6683 @code{14. Scandicus}
6685 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6686 \include "gregorian-init.ly"
6688 \notes \transpose c c' {
6690 \[ g \pes a \virga b \]
6697 \remove "Bar_number_engraver"
6701 \remove "Clef_engraver"
6702 \remove "Key_engraver"
6703 StaffSymbol \set #'transparent = ##t
6704 \remove "Time_signature_engraver"
6705 \remove "Bar_engraver"
6706 minimumVerticalExtent = ##f
6710 \remove Ligature_bracket_engraver
6711 \consists Vaticana_ligature_engraver
6712 NoteHead \set #'style = #'vaticana_punctum
6713 Stem \set #'transparent = ##t
6719 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6720 \include "gregorian-init.ly"
6722 \notes \transpose c c' {
6723 % Scandicus Auctus Descendens
6724 \[ g \pes a \pes \auctum \descendens b \]
6731 \remove "Bar_number_engraver"
6735 \remove "Clef_engraver"
6736 \remove "Key_engraver"
6737 StaffSymbol \set #'transparent = ##t
6738 \remove "Time_signature_engraver"
6739 \remove "Bar_engraver"
6740 minimumVerticalExtent = ##f
6744 \remove Ligature_bracket_engraver
6745 \consists Vaticana_ligature_engraver
6746 NoteHead \set #'style = #'vaticana_punctum
6747 Stem \set #'transparent = ##t
6753 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6754 \include "gregorian-init.ly"
6756 \notes \transpose c c' {
6757 % Scandicus Deminutus
6758 \[ g \pes a \pes \deminutum b \]
6765 \remove "Bar_number_engraver"
6769 \remove "Clef_engraver"
6770 \remove "Key_engraver"
6771 StaffSymbol \set #'transparent = ##t
6772 \remove "Time_signature_engraver"
6773 \remove "Bar_engraver"
6774 minimumVerticalExtent = ##f
6778 \remove Ligature_bracket_engraver
6779 \consists Vaticana_ligature_engraver
6780 NoteHead \set #'style = #'vaticana_punctum
6781 Stem \set #'transparent = ##t
6790 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6791 \include "gregorian-init.ly"
6793 \notes \transpose c c' {
6795 \[ g \oriscus a \pes \virga b \]
6802 \remove "Bar_number_engraver"
6806 \remove "Clef_engraver"
6807 \remove "Key_engraver"
6808 StaffSymbol \set #'transparent = ##t
6809 \remove "Time_signature_engraver"
6810 \remove "Bar_engraver"
6811 minimumVerticalExtent = ##f
6815 \remove Ligature_bracket_engraver
6816 \consists Vaticana_ligature_engraver
6817 NoteHead \set #'style = #'vaticana_punctum
6818 Stem \set #'transparent = ##t
6824 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6825 \include "gregorian-init.ly"
6827 \notes \transpose c c' {
6828 % Salicus Auctus Descendens
6829 \[ g \oriscus a \pes \auctum \descendens b \]
6836 \remove "Bar_number_engraver"
6840 \remove "Clef_engraver"
6841 \remove "Key_engraver"
6842 StaffSymbol \set #'transparent = ##t
6843 \remove "Time_signature_engraver"
6844 \remove "Bar_engraver"
6845 minimumVerticalExtent = ##f
6849 \remove Ligature_bracket_engraver
6850 \consists Vaticana_ligature_engraver
6851 NoteHead \set #'style = #'vaticana_punctum
6852 Stem \set #'transparent = ##t
6862 @lilypond[noindent, 26pt, nofragment, linewidth=1.0cm]
6863 \include "gregorian-init.ly"
6865 \notes \transpose c c' {
6867 \[ \stropha b \stropha b \stropha a \]
6874 \remove "Bar_number_engraver"
6878 \remove "Clef_engraver"
6879 \remove "Key_engraver"
6880 StaffSymbol \set #'transparent = ##t
6881 \remove "Time_signature_engraver"
6882 \remove "Bar_engraver"
6883 minimumVerticalExtent = ##f
6887 \remove Ligature_bracket_engraver
6888 \consists Vaticana_ligature_engraver
6889 NoteHead \set #'style = #'vaticana_punctum
6890 Stem \set #'transparent = ##t
6902 Unlike most other neumes notation systems, the input language for
6903 neumes does not necessarily reflect directly the typographical
6904 appearance, but is designed to solely focuse on musical meaning. For
6905 example, @code{\[ a \pes b \flexa g \]} produces a Torculus consisting
6906 of three Punctum heads, while @code{\[ a \flexa g \pes b \]} produces
6907 a Porrectus with a curved flexa shape and only a single Punctum head.
6908 There is no command to explicitly typeset the curved flexa shape; the
6909 decision of when to typeset a curved flexa shape is purely taken from
6910 the musical input. The idea of this approach is to separate the
6911 musical aspects of the input from the notation style of the output.
6912 This way, the same input can be reused to typeset the same music in a
6913 different style of Gregorian chant notation such as Hufnagel (also
6914 known as German gothic neumes) or Medicaea (kind of a very simple
6915 forerunner of the Editio Vaticana). As soon as Hufnagel ligature
6916 engraver and Medicaea ligature engraver will have been implemented, it
6917 will be as simple as replacing the ligature engraver in the
6918 @internalsref{Voice} context to get the desired notation style from
6921 The following table shows the code fragments that produce the
6922 ligatures in the above neumes table. The letter in the first column
6923 in each line of the below table indicates to which ligature in the
6924 above table it refers. The second column gives the name of the
6925 ligature. The third column shows the code fragment that produces this
6926 ligature, using @code{g}, @code{a} and @code{b} as example pitches.
6928 @multitable @columnfractions .1 .4 .5
6942 Punctum Inclinatum @tab
6943 @code{\[ \inclinatum b \]}
6947 Punctum Auctum Ascendens @tab
6948 @code{\[ \auctum \ascendens b \]}
6952 Punctum Auctum Descendens @tab
6953 @code{\[ \auctum \descendens b \]}
6957 Punctum Inclinatum Auctum @tab
6958 @code{\[ \inclinatum \auctum b \]}
6962 Punctum Inclinatum Parvum @tab
6963 @code{\[ \inclinatum \deminutum b \]}
6968 @code{\[ \virga b \]}
6973 @code{\[ \stropha b \]}
6978 @code{\[ \stropha \auctum b \]}
6983 @code{\[ \oriscus b \]}
6987 Clivis vel Flexa @tab
6988 @code{\[ b \flexa g \]}
6992 Clivis Aucta Descendens @tab
6993 @code{\[ b \flexa \auctum \descendens g \]}
6997 Clivis Aucta Ascendens @tab
6998 @code{\[ b \flexa \auctum \ascendens g \]}
7003 @code{\[ b \flexa \deminutum g \]}
7007 Podatus vel Pes @tab
7008 @code{\[ g \pes b \]}
7012 Pes Auctus Descendens @tab
7013 @code{\[ g \pes \auctum \descendens b \]}
7017 Pes Auctus Ascendens @tab
7018 @code{\[ g \pes \auctum \ascendens b \]}
7023 @code{\[ g \pes \deminutum b \]}
7028 @code{\[ \oriscus g \pes \virga b \]}
7032 Pes Quassus Auctus Descendens @tab
7033 @code{\[ \oriscus g \pes \auctum \descendens b \]}
7038 @code{\[ \quilisma g \pes b \]}
7042 Quilisma Pes Auctus Descendens @tab
7043 @code{\[ \quilisma g \pes \auctum \descendens b \]}
7047 Pes Initio Debilis @tab
7048 @code{\[ \deminutum g \pes b \]}
7052 Pes Auctus Descendens Initio Debilis @tab
7053 @code{\[ \deminutum g \pes \auctum \descendens b \]}
7058 @code{\[ a \pes b \flexa g \]}
7062 Torculus Auctus Descendens @tab
7063 @code{\[ a \pes b \flexa \auctum \descendens g \]}
7067 Torculus Deminutus @tab
7068 @code{\[ a \pes b \flexa \deminutum g \]}
7072 Torculus Initio Debilis @tab
7073 @code{\[ \deminutum a \pes b \flexa g \]}
7077 Torculus Auctus Descendens Initio Debilis @tab
7078 @code{\[ \deminutum a \pes b \flexa \auctum \descendens g \]}
7082 Torculus Deminutus Initio Debilis @tab
7083 @code{\[ \deminutum a \pes b \flexa \deminutum g \]}
7088 @code{\[ a \flexa g \pes b \]}
7092 Porrectus Auctus Descendens @tab
7093 @code{\[ a \flexa g \pes \auctum \descendens b \]}
7097 Porrectus Deminutus @tab
7098 @code{\[ a \flexa g \pes \deminutum b \]}
7103 @code{\[ \virga b \inclinatum a \inclinatum g \]}
7107 Climacus Auctus @tab
7108 @code{\[ \virga b \inclinatum a \inclinatum \auctum g \]}
7112 Climacus Deminutus @tab
7113 @code{\[ \virga b \inclinatum a \inclinatum \deminutum g \]}
7118 @code{\[ g \pes a \virga b \]}
7122 Scandicus Auctus Descendens @tab
7123 @code{\[ g \pes a \pes \auctum \descendens b \]}
7127 Scandicus Deminutus @tab
7128 @code{\[ g \pes a \pes \deminutum b \]}
7133 @code{\[ g \oriscus a \pes \virga b \]}
7137 Salicus Auctus Descendens @tab
7138 @code{\[ g \oriscus a \pes \auctum \descendens b \]}
7143 @code{\[ \stropha b \stropha b \stropha a \]}
7149 The following head prefixes are supported:
7151 @cindex @code{\virga}
7153 @cindex @code{\stropha}
7155 @cindex @code{\inclinatum}
7157 @cindex @code{\auctum}
7159 @cindex @code{\descendens}
7161 @cindex @code{\ascendens}
7163 @cindex @code{\oriscus}
7165 @cindex @code{\quilisma}
7167 @cindex @code{\deminutum}
7170 Head prefixes can be accumulated, though restrictions apply. For
7171 example, either @code{\descendens} or @code{\ascendens} can be applied
7172 to a head, but not both to the same head.
7175 @cindex @code{\flexa}
7176 Two adjacent heads can be tied together with the @code{\pes} and
7177 @code{\flexa} infix commands for a rising and falling line of melody,
7182 Trigonus: apply equal spacing, regardless of pitch.
7185 @subsection Figured bass
7187 @cindex Basso continuo
7189 @c TODO: musicological blurb about FB
7193 LilyPond has limited support for figured bass:
7195 @lilypond[verbatim,fragment]
7197 \context Voice \notes { \clef bass dis4 c d ais}
7198 \context FiguredBass
7200 < 6 >4 < 7 >8 < 6+ [_!] >
7206 The support for figured bass consists of two parts: there is an input
7207 mode, introduced by @code{\figures}, where you can enter bass figures
7208 as numbers, and there is a context called @internalsref{FiguredBass} that
7209 takes care of making @internalsref{BassFigure} objects.
7211 In figures input mode, a group of bass figures is delimited by
7212 @code{<} and @code{>}. The duration is entered after the @code{>>}:
7217 \context FiguredBass
7221 Accidentals are added when you append @code{-}, @code{!} and @code{+}
7228 \context FiguredBass
7229 \figures { <4- 6+ 7!> }
7232 Spaces or dashes may be inserted by using @code{_}. Brackets are
7233 introduced with @code{[} and @code{]}:
7239 \context FiguredBass
7240 \figures { < [4 6] 8 [_! 12]> }
7243 Although the support for figured bass may superficially resemble chord
7244 support, it works much simpler. The @code{\figures} mode simply
7245 stores the numbers , and @internalsref{FiguredBass} context prints
7246 them as entered. There is no conversion to pitches, and no
7247 realizations of the bass are played in the MIDI file.
7249 Internally, the code produces markup texts. You can use any of the
7250 markup text properties to override formatting. For example, the
7251 vertical spacing of the figures may be set with @code{baseline-skip}.
7255 @internalsref{BassFigureEvent} music, @internalsref{BassFigure} object,
7256 and @internalsref{FiguredBass} context.
7260 Slash notation for alterations is not supported.
7263 @node Vaticana style contexts
7264 @subsection Vaticana style contexts
7266 @cindex VaticanaVoiceContext
7267 @cindex VaticanaStaffContext
7269 The predefined @code{VaticanaVoiceContext} and
7270 @code{VaticanaStaffContext} can be used to easily engrave a piece of
7271 Gregorian Chant in the style of the Editio Vaticana. These contexts
7272 initialize all relevant context properties and grob properties to
7273 proper values. With these contexts, you can immediately go ahead
7274 entering the chant, as the following short excerpt demonstrates:
7276 @lilypond[raggedright,verbatim,noindent]
7277 \include "gregorian-init.ly"
7280 \context VaticanaVoice {
7281 \property Score.BarNumber \set #'transparent = ##t
7283 \[ c'( c' \flexa a \] \[ a \flexa \deminutum g) \] f \divisioMinima
7284 \[ f( \pes a c' c' \pes d') \] c' \divisioMinima \break
7285 \[ c'( c' \flexa a \] \[ a \flexa \deminutum g) \] f \divisioMinima
7288 \context Lyrics \lyrics {
7289 San- ctus, San- ctus, San- ctus
7294 @node Contemporary notation
7295 @section Contemporary notation
7297 In the 20th century, composers have greatly expanded the musical
7298 vocabulary. With this expansion, many innovations in musical notation
7299 have been tried. For a comprehensive overview, refer to @cite{Stone
7300 1980} (see @ref{Literature}). In general, the use of new, innovative
7301 notation makes a piece harder to understand and perform and its use
7302 should therefore be avoided if possible. For this reason, support for
7303 contemporary notation in LilyPond is limited.
7312 @subsection Clusters
7316 In musical terminology, a @emph{cluster} denotes a range of
7317 simultaneously sounding pitches that may change over time. The set of
7318 available pitches to apply usually depends on the accoustic source.
7319 Thus, in piano music, a cluster typically consists of a continous range
7320 of the semitones as provided by the piano's fixed set of a chromatic
7321 scale. In choral music, each singer of the choir typically may sing an
7322 arbitrary pitch within the cluster's range that is not bound to any
7323 diatonic, chromatic or other scale. In electronic music, a cluster
7324 (theoretically) may even cover a continuous range of pitches, thus
7325 resulting in coloured noise, such as pink noise.
7327 Clusters can be denoted in the context of ordinary staff notation by
7328 engraving simple geometrical shapes that replace ordinary notation of
7329 notes. Ordinary notes as musical events specify starting time and
7330 duration of pitches; however, the duration of a note is expressed by the
7331 shape of the note head rather than by the horizontal graphical extent of
7332 the note symbol. In contrast, the shape of a cluster geometrically
7333 describes the development of a range of pitches (vertical extent) over
7334 time (horizontal extent). Still, the geometrical shape of a cluster
7335 covers the area in wich any single pitch contained in the cluster would
7336 be notated as an ordinary note. From this point of view, it is
7337 reasonable to specify a cluster as the envelope of a set of notes.
7341 A cluster is engraved as the envelope of a set of
7342 cluster-notes. Cluster notes are created by applying the function
7343 @code{notes-to-clusters} to a sequence of chords, e.g.
7345 @lilypond[relative 1,verbatim]
7346 \apply #notes-to-clusters { <c e > <b f'> }
7349 The following example (from
7350 @inputfileref{input/regression,cluster.ly}) shows what the result
7353 @lilypondfile[notexidoc]{cluster.ly}
7355 By default, @internalsref{Cluster_spanner_engraver} is in the
7356 @internalsref{Voice} context. This allows putting ordinary notes and
7357 clusters together in the same staff, even simultaneously. In such a
7358 case no attempt is made to automatically avoid collisions between
7359 ordinary notes and clusters.
7363 @internalsref{ClusterSpanner}, @internalsref{ClusterSpannerBeacon},
7364 @inputfileref{input/regression,cluster.ly},
7365 @internalsref{Cluster_spanner_engraver}, and @internalsref{ClusterNoteEvent}.
7369 Music expressions like @code{<< @{ g8 e8 @} a4 >>} are not printed
7370 accurately. Use @code{<g a>8 <e a>8} instead.
7375 @subsection Fermatas
7381 Contemporary music notation frequently uses special fermata symbols to
7382 indicate fermatas of differing lengths.
7386 The following are supported
7388 @lilypond[singleline]
7390 << \addlyrics \notes {
7410 \context Lyrics \lyrics {
7411 "shortfermata" "fermata" "longfermata" "verylongfermata"
7416 See @ref{Articulations} for general instructions how to apply scripts
7417 such as fermatas to a @code{\notes@{@}} block.
7420 @section Tuning output
7422 There are situations where default layout decisions are not
7423 sufficient. In this section we discuss ways to override these
7426 Formatting is internally done by manipulating so called objects
7427 (graphic objects). Each object carries with it a set of properties
7428 (object or layout properties) specific to that object. For example, a
7429 stem object has properties that specify its direction, length and
7432 The most direct way of tuning the output is by altering the values of
7433 these properties. There are two ways of doing that: first, you can
7434 temporarily change the definition of one type of object, thus
7435 affecting a whole set of objects. Second, you can select one specific
7436 object, and set a layout property in that object.
7438 Do not confuse layout properties with translation
7439 properties. Translation properties always use a mixed caps style
7440 naming, and are manipulated using @code{\property}:
7442 \property Context.propertyName = @var{value}
7444 Layout properties are use Scheme style variable naming, i.e. lower
7445 case words separated with dashes. They are symbols, and should always
7446 be quoted using @code{#'}. For example, this could be an imaginary
7447 layout property name:
7449 #'layout-property-name
7454 * Constructing a tweak::
7463 @node Tuning objects
7464 @subsection Tuning objects
7466 @cindex object description
7468 The definition of an object is a list of default object
7469 properties. For example, the definition of the Stem object (available
7470 in @file{scm/define-grobs.scm}), includes the following definitions
7471 for @internalsref{Stem}:
7475 (beamed-lengths . (0.0 2.5 2.0 1.5))
7476 (Y-extent-callback . ,Stem::height)
7481 Adding variables on top of this existing definition overrides the
7482 system default, and alters the resulting appearance of the layout
7488 Changing a variable for only one object is commonly achieved with
7492 \once \property @var{context}.@var{objectname}
7493 \override @var{symbol} = @var{value}
7495 Here @var{symbol} is a Scheme expression of symbol type, @var{context}
7496 and @var{objectname} is a string and @var{value} is a Scheme expression.
7497 This command applies a setting only during one moment in the score.
7499 In the following example, only one @internalsref{Stem} object is
7500 changed from its original setting:
7502 @lilypond[verbatim, fragment, relative=1]
7504 \once \property Voice.Stem \set #'thickness = #4
7508 @cindex @code{\once}
7510 For changing more objects, the same command, without @code{\once} can
7513 \property @var{context}.@var{objectname} \override @var{symbol} = @var{value}
7515 This command adds @code{@var{symbol} = @var{value}} to the definition
7516 of @var{objectname} in the context @var{context}, and this definition
7517 stays in place until it is removed.
7519 An existing definition may be removed by the following command:
7522 \property @var{context}.@var{objectname} \revert @var{symbol}
7525 All @code{\override} and @code{\revert} commands should be balanced.
7526 The @code{\set} shorthand performs a revert followed by an override,
7527 and is often more convenient to use
7530 \property @var{context}.@var{objectname} \set @var{symbol} = @var{value}
7534 @lilypond[verbatim,quote]
7535 c'4 \property Voice.Stem \override #'thickness = #4.0
7537 c'4 \property Voice.Stem \revert #'thickness
7541 The following example gives exactly the same result as the previous
7542 one (assuming the system default for stem thickness is 1.3):
7544 @lilypond[verbatim,quote]
7545 c'4 \property Voice.Stem \set #'thickness = #4.0
7547 c'4 \property Voice.Stem \set #'thickness = #1.3
7551 Reverting a setting which was not set in the first place has no
7552 effect. However, if the setting was set as a system default, this may
7553 remove the default value, and this may give surprising results,
7554 including crashes. In other words, @code{\override} and
7555 @code{\revert} must be carefully balanced. The following are examples
7556 of correct nesting of @code{\override}, @code{\set}, @code{\revert}:
7560 a clumsy but correct form:
7562 \override \revert \override \revert \override \revert
7566 shorter version of the same:
7568 \override \set \set \revert
7572 a short form, using only @code{\set}. This requires you to know the
7575 \set \set \set \set @var{to default value}
7579 if there is no default (i.e. by default, the object property is unset),
7582 \set \set \set \revert
7586 For the digirati, the object description is an Scheme association
7587 list. Since a Scheme list is a singly linked list, we can treat it as
7588 a stack, and @code{\override} and @code{\revert} are push and pop
7589 operations. The association list is stored in a normal context
7592 \property Voice.NoteHead = #'()
7594 will effectively erase @internalsref{NoteHead}s from the current
7595 @internalsref{Voice}. However, this mechanism is not guaranteed to
7596 work, and may cause crashes or other anomalous behavior.
7600 @internalsref{OverrideProperty}, @internalsref{RevertProperty},
7601 @internalsref{PropertySet}, @internalsref{All-backend-properties}, and
7602 @internalsref{All-layout-objects}.
7607 The backend is not very strict in type-checking object properties.
7608 Cyclic references in @var{value} cause hangs and/or crashes.
7609 Similarly, reverting properties that are system defaults may also lead
7612 @node Constructing a tweak
7613 @subsection Constructing a tweak
7616 @cindex internal documentation
7617 @cindex finding graphical objects
7618 @cindex graphical object descriptions
7620 @cindex @code{\override}
7622 @cindex internal documentation
7626 Three pieces of information are required to use @code{\override} and
7627 @code{\set}: the name of the layout object, the context and the name
7628 of the property. We demonstrate how to glean this information from
7629 the notation manual and the generated documentation.
7631 The generated documentation is a set of HTML pages which should be
7632 included if you installed a binary distribution, typically in
7633 @file{/usr/share/doc/lilypond}. They are also available on the web:
7634 go to the @uref{http://lilypond.org,LilyPond website}, click
7635 ``Documentation'', and then ``Program reference'' on the side bar. It
7636 is advisable to bookmark either the local HTML files if possible. They
7637 will load faster than the ones on the web. If you use the version
7638 from the web, you must check whether the documentation matches the
7639 program version: the documentation is generated from the definitions
7640 that the program uses, and therefore it is strongly tied to the
7644 @c [TODO: revise for new site.]
7646 Suppose we want to move the fingering indication in the fragment below:
7648 @lilypond[relative=2,verbatim]
7654 If you visit the documentation of @code{Fingering} (in @ref{Fingering
7655 instructions}), you will notice that there is written:
7660 @internalsref{FingerEvent} and @internalsref{Fingering}.
7664 In other words, the fingerings once entered, are internally stored as
7665 @code{FingerEvent} music objects. When printed, a @code{Fingering}
7666 layout object is created for every @code{FingerEvent}.
7668 The Fingering object has a number of different functions, and each of
7669 those is captured in an interface, when we look up
7670 @internalsref{Fingering} in the generated documentation.
7674 The @code{Fingering} object has a fixed size
7675 (@internalsref{item-interface}), the symbol is a piece of text
7676 (@internalsref{text-interface}), whose font can be set
7677 (@internalsref{font-interface}). It is centered horizontally
7678 (@internalsref{self-alignment-interface}), it is placed next to other
7679 objects (@internalsref{side-position-interface}) vertically, and its
7680 placement is coordinated with other scripts
7681 (@internalsref{text-script-interface}). It also has the standard
7682 @internalsref{grob-interface} (grob stands for Graphical object)
7684 @cindex graphical object
7685 @cindex layout object
7686 @cindex object, layout
7687 with all the variables that come with
7688 it. Finally, it denotes a fingering instruction, so it has
7689 @internalsref{finger-interface}.
7691 For the vertical placement, we have to look under
7692 @code{side-position-interface}:
7694 @code{side-position-interface}
7696 Position a victim object (this one) next to other objects (the
7697 support). In this case, the direction signifies where to put the
7698 victim object relative to the support (left or right, up or down?)
7703 below this description, the variable @code{padding} is described as
7707 (dimension, in staff space)
7709 add this much extra space between objects that are next to each
7710 other. Default value: @code{0.6}
7714 By increasing the value of @code{padding}, we can move away the
7715 fingering. The following command inserts 3 staff spaces of white
7716 between the note and the fingering:
7718 \once \property Voice.Fingering \set #'padding = #3
7721 Inserting this command before the Fingering object is created,
7722 i.e. before @code{c2}, yields the following result:
7724 @lilypond[relative=2,fragment,verbatim]
7725 \once \property Voice.Fingering
7732 The context name @code{Voice} in the example above can be determined
7733 as follows. In the documentation for @internalsref{Fingering}, it says
7735 Fingering grobs are created by: @internalsref{Fingering_engraver}
7738 Clicking @code{Fingering_engraver} shows the documentation of
7739 the module responsible for interpreting the fingering instructions and
7740 translating them to a @code{Fingering} object. Such a module is called
7741 an @emph{engraver}. The documentation of the @code{Fingering_engraver}
7744 Fingering_engraver is part of contexts: Voice
7746 so tuning the settings for Fingering should be done with
7748 \property Voice.Fingering \set @dots{}
7751 Of course, the tweak may also done in a larger context than
7752 @code{Voice}, for example, @internalsref{Staff} or
7753 @internalsref{Score}.
7755 The internals document also contains alphabetical lists of
7756 @internalsref{Contexts}, @internalsref{All-layout-objects} and
7757 @internalsref{Music-expressions}, so you can also find which objects to
7758 tweak by browsing the internals document.
7762 @subsection Applyoutput
7764 The most versatile way of tuning an object is @code{\applyoutput}. Its
7767 \applyoutput @var{proc}
7771 where @var{proc} is a Scheme function, taking four arguments.
7773 When interpreted, the function @var{proc} is called for every layout object found
7774 in the context, with the following arguments:
7776 @item the layout object itself,
7777 @item the context where the layout object was created, and
7778 @item the context where @code{\applyoutput} is processed.
7781 In addition, the cause of the layout object, i.e. the music
7782 expression or object that was responsible for creating it, is in the
7783 object property @code{cause}. For example, for a note head, this is a
7784 @internalsref{NoteHead} event, and for a @internalsref{Stem} object,
7785 this is a @internalsref{NoteHead} object.
7788 @node Outputproperty
7789 @subsection Outputproperty
7791 @cindex @code{\outputproperty}
7793 Another way of tuning objects is the more arcane @code{\outputproperty}
7794 feature. The syntax is as follows:
7796 \outputproperty @var{predicate} @var{symbol} = @var{value}
7798 Here @code{predicate} is a Scheme function taking an object argument, and
7799 returning a boolean. This statement is processed by the
7800 @code{Output_property_engraver}. It instructs the engraver to feed all
7801 objects that it sees to @var{predicate}. Whenever the predicate returns
7802 true, the object property @var{symbol} will be set to @var{value}.
7804 You will need to combine this statement with @code{\context} to select
7805 the appropriate context to apply this to.
7806 @inputfileref{input/regression,output-property.ly} shows an example of
7807 the use of @code{\outputproperty}.
7811 This command is slated for removal. Please use the
7812 @code{\applyoutput} command, see @ref{Applyoutput}.
7815 @node Font selection
7816 @subsection Font selection
7818 The most common thing to change about the appearance of fonts is their
7819 size. The font size of any context can be easily changed by setting
7820 the @code{fontSize} property for that context. Its value is an
7821 integer: negative numbers make the font smaller, positive numbers
7822 larger. An example is given below:
7824 @lilypond[fragment,relative=1,verbatim,quote]
7825 c4 c4 \property Voice.fontSize = #-1
7828 This command will set @code{font-relative-size} (see below), and does
7829 not change the size of variable symbols, such as beams or slurs.
7832 One of the uses of @code{fontSize} is to get smaller symbol for cue
7833 notes. An elaborate example of those is in
7834 @inputfileref{input/test,cue-notes.ly}.
7836 @cindex magnification
7838 The size of the font may be scaled with the object property
7839 @code{font-magnification}. For example, @code{2.0} blows up all
7840 letters by a factor 2 in both directions.
7849 The font used for printing a object can be selected by setting
7850 @code{font-name}, e.g.
7852 \property Staff.TimeSignature
7853 \set #'font-name = #"cmr17"
7857 Any font can be used, as long as it is available to @TeX{}. Possible
7858 fonts include foreign fonts or fonts that do not belong to the
7859 Computer Modern font family.
7861 Font selection for the standard fonts, @TeX{}'s Computer Modern fonts,
7862 can also be adjusted with a more fine-grained mechanism. By setting
7863 the object properties described below, you can select a different font;
7864 all three mechanisms work for every object that supports
7865 @code{font-interface}:
7869 is a symbol indicating the general class of the typeface. Supported are
7870 @code{roman} (Computer Modern), @code{braces} (for piano staff
7871 braces), @code{music} (the standard music font, including ancient
7872 glyphs), @code{dynamic} (for dynamic signs) and @code{typewriter}.
7875 is a symbol indicating the shape of the font, there are typically several
7876 font shapes available for each font family. Choices are @code{italic},
7877 @code{caps} and @code{upright}.
7880 is a symbol indicating the series of the font. There are typically several
7881 font series for each font family and shape. Choices are @code{medium}
7884 @item font-relative-size
7885 is a number indicating the size relative the standard size. For example,
7886 with 20pt staff height, relative size -1 corresponds to 16pt staff
7887 height, and relative size +1 corresponds to 23 pt staff height.
7889 There are small differences in design between fonts designed for
7890 different sizes, hence @code{font-relative-size} is preferred over
7891 @code{font-magnification} for changing font sizes.
7894 @item font-design-size
7895 is a number indicating the design size of the font.
7897 This is a feature of the Computer Modern Font: each point size has a
7898 slightly different design. Smaller design sizes are relatively wider,
7899 which enhances readability.
7902 For any of these properties, the value @code{*} (i.e. the symbol
7903 @code{*}, entered as @code{#'*}), acts as a wildcard. This can be used
7904 to override default setting, which are always present. For example:
7906 \property Lyrics . LyricText \override #'font-series = #'bold
7907 \property Lyrics . LyricText \override #'font-family = #'typewriter
7908 \property Lyrics . LyricText \override #'font-shape = #'*
7911 @cindex @code{font-style}
7915 The following commands set @code{fontSize} for the current voice.
7917 @cindex @code{\tiny}
7919 @cindex @code{\small}
7921 @cindex @code{\normalsize}
7926 Relative size is not linked to any real size.
7928 There is no style sheet provided for other fonts besides the @TeX{}
7929 family, and the style sheet cannot be modified easily.
7931 @cindex font selection
7932 @cindex font magnification
7933 @cindex @code{font-interface}
7937 @subsection Text markup
7942 @cindex typeset text
7944 LilyPond has an internal mechanism to typeset texts. You can access it
7945 with the keyword @code{\markup}. Within markup mode, you can enter texts
7946 similar to lyrics: simply enter them, surrounded by spaces:
7949 @lilypond[verbatim,fragment,relative=1]
7950 c1^\markup { hello }
7951 c1_\markup { hi there }
7952 c1^\markup { hi \bold there, is \italic anyone home? }
7955 @cindex font switching
7957 The markup in the example demonstrates font switching commands. The
7958 command @code{\bold} and @code{\italic} only apply to the first
7959 following word; enclose a set of texts with braces to apply a command
7962 \markup @{ \bold @{ hi there @} @}
7966 For clarity, you can also do this for single arguments, e.g.
7968 \markup @{ is \italic @{ anyone @} home @}
7971 @cindex font size, texts
7973 The following size commands set absolute sizes:
7975 @cindex @code{\teeny}
7976 @cindex @code{\tiny}
7977 @cindex @code{\small}
7978 @cindex @code{\large}
7979 @cindex @code{\huge}
7989 You can also make letter larger or smaller relative to their neighbors,
7990 with the commands @code{\larger} and @code{\smaller}.
7994 @cindex font style, for texts
7995 @cindex @code{\bold}
7996 @cindex @code{\dynamic}
7997 @cindex @code{\number}
7998 @cindex @code{\italic}
8000 The following font change commands are defined:
8003 changes to the font used in dynamic signs. This font does not
8004 contain all characters of the alphabet, so when producing ``piu f'',
8005 the ``piu'' should be done in a different font.
8009 changes to the font used in time signatures. It only contains
8010 numbers and a few punctuation marks.
8012 changes @code{font-shape} to @code{italic}.
8014 changes @code{font-series} to @code{bold}.
8017 @cindex raising text
8018 @cindex lowering text
8020 @cindex translating text
8023 @cindex @code{\super}
8025 Raising and lowering texts can be done with @code{\super} and
8028 @lilypond[verbatim,fragment,relative=1]
8029 c1^\markup { E "=" mc \super "2" }
8032 @cindex @code{\raise}
8034 If you want to give an explicit amount for lowering or raising, use
8035 @code{\raise}. This command takes a Scheme valued first argument, and
8036 a markup object as second argument:
8038 @lilypond[verbatim,fragment,relative=1,quote]
8039 c1^\markup { C \small \raise #1.0 \bold { "9/7+" }}
8041 The argument to @code{\raise} is the vertical displacement amount,
8042 measured in (global) staff spaces. @code{\raise} and @code{\super}
8043 raise objects in relation to their surrounding markups. They cannot be
8044 used to move a single text up or down, when it is above or below a
8045 note, since the mechanism that positions it next to the note cancels
8046 any vertical shift. For vertical positioning, use the @code{padding}
8047 and/or @code{extra-offset} properties.
8049 Other commands taking single arguments include
8052 @item \bracket, \hbracket
8053 Bracket the argument markup with normal and horizontal brackets
8057 @cindex @code{\musicglyph}
8058 This is converted to a musical symbol, e.g. @code{\musicglyph
8059 #"accidentals-0"} will select the natural sign from the music font.
8060 See @ref{The Feta font} for a complete listing of the possible glyphs.
8062 This produces a single character, e.g. @code{\char #65} produces the
8065 @item \note @var{log} @var{dots} @var{dir}
8066 @cindex @code{\note}
8068 This produces a note with a stem pointing in @var{dir} direction, with
8069 duration log @var{log} and @var{dots} augmentation dots. The duration
8070 log is the negative 2-logarithm of the duration denominator. For
8071 example, a quarter note has log 2, an eighth note 3 and a breve has
8074 @item \hspace #@var{amount}
8075 @cindex @code{\hspace}
8076 This produces a invisible object taking horizontal space.
8078 \markup @{ A \hspace #2.0 B @}
8080 will put extra space between A and B, on top of the space that is
8081 normally inserted before elements on a line.
8083 @item \fontsize #@var{size}
8084 @cindex @code{\fontsize}
8085 This sets the relative font size, eg.
8087 A \fontsize #2 @{ B C @} D
8091 This will enlarge the B and the C by two steps.
8092 @item \translate #(cons @var{x} @var{y})
8094 This translates an object. Its first argument is a cons of numbers
8096 A \translate #(cons 2 -3) @{ B C @} D
8098 This moves `B C' 2 spaces to the right, and 3 down.
8100 @item \magnify #@var{mag}
8101 @cindex @code{\magnify}
8102 This sets the font magnification for the its argument. In the following
8103 example, the middle A will be 10% larger:
8105 A \magnify #1.1 @{ A @} A
8109 @item \override #(@var{key} . @var{value})
8110 @cindex @code{\override}
8111 This overrides a formatting property for its argument. The argument
8112 should be a key/value pair, e.g.
8114 m \override #'(font-family . math) m m
8118 In markup mode you can compose expressions, similar to mathematical
8119 expressions, XML documents and music expressions. The braces group
8120 notes into horizontal lines. Other types of lists also exist: you can
8121 stack expressions grouped with @code{<}, and @code{>} vertically with
8122 the command @code{\column}. Similarly, @code{\center} aligns texts by
8125 @lilypond[verbatim,fragment,relative=1]
8126 c1^\markup { \column < a bbbb c > }
8127 c1^\markup { \center < a bbbb c > }
8128 c1^\markup { \line < a b c > }
8131 The markup mechanism is extensible. Refer to
8132 @file{scm/new-markup.scm} for more information.
8138 @internalsref{Markup-functions}, and @file{scm/new-markup.scm}.
8145 Text layout is ultimately done by @TeX{}, which does kerning of
8146 letters. LilyPond does not account for kerning, so texts will be
8147 spaced slightly too wide.
8149 Syntax errors for markup mode are confusing.
8151 Markup texts cannot be used in the titling of the @code{\header}
8152 field. Titles are made by La@TeX{}, so La@TeX{} commands should be used
8159 @section Global layout
8161 The global layout determined by three factors: the page layout, the
8162 line breaks and the spacing. These all influence each other. The
8163 choice of spacing determines how densely each system of music is set,
8164 which influences where line breaks breaks are chosen, and thus
8165 ultimately how many pages a piece of music takes. In this section, the
8166 algorithm for spacing music is explained, and how spacing can be
8169 Globally spoken, this procedure happens in three steps: first,
8170 flexible distances (``springs'') are chosen, based on durations. All
8171 possible line breaking combination are tried, and the one with the
8172 best results---a layout that has uniform density and requires as
8173 little stretching or cramping as possible---is chosen. When the score
8174 is processed by @TeX{}, each page is filled with systems, and page breaks
8175 are chosen whenever the page gets full.
8180 * Vertical spacing::
8181 * Horizontal spacing::
8188 @node Vertical spacing
8189 @subsection Vertical spacing
8191 @cindex vertical spacing
8192 @cindex distance between staves
8193 @cindex staff distance
8194 @cindex between staves, distance
8195 @cindex staffs per page
8196 @cindex space between staves
8198 The height of each system is determined automatically by LilyPond, to
8199 keep systems from bumping into each other, some minimum distances are
8200 set. By changing these, you can put staves closer together, and thus
8201 put more systems onto one page.
8203 Normally staves are stacked vertically. To make
8204 staves maintain a distance, their vertical size is padded. This is
8205 done with the property @code{minimumVerticalExtent}. It takes a pair
8206 of numbers, so if you want to make it smaller from its, then you could
8209 \property Staff.minimumVerticalExtent = #'(-4 . 4)
8211 This sets the vertical size of the current staff to 4 staff-space on
8212 either side of the center staff line. The argument of
8213 @code{minimumVerticalExtent} is interpreted as an interval, where the
8214 center line is the 0, so the first number is generally negative. The
8215 staff can be made larger at the bottom by setting it to @code{(-6
8218 The piano staves are handled a little differently: to make cross-staff
8219 beaming work correctly, it is necessary that the distance between staves
8220 is fixed beforehand. This is also done with a
8221 @internalsref{VerticalAlignment} object, created in
8222 @internalsref{PianoStaff}. In this object the distance between the
8223 staves is fixed by setting @code{forced-distance}. If you want to
8224 override this, use a @code{\translator} block as follows:
8228 VerticalAlignment \override #'forced-distance = #9
8231 This would bring the staves together at a distance of 9 staff spaces,
8232 measured from the center line of each staff.
8236 Vertical alignment of staves is handled by the
8237 @internalsref{VerticalAlignment} object.
8241 @node Horizontal spacing
8242 @subsection Horizontal Spacing
8244 The spacing engine translates differences in durations into
8245 stretchable distances (``springs'') of differing lengths. Longer
8246 durations get more space, shorter durations get less. The shortest
8247 durations get a fixed amount of space (which is controlled by
8248 @code{shortest-duration-space} in the @internalsref{SpacingSpanner} object).
8249 /The longer the duration, the more space it gets: doubling a
8250 duration adds a fixed amount (this amount is controlled by
8251 @code{spacing-increment}) of space to the note.
8253 For example, the following piece contains lots of half, quarter and
8254 8th notes, the eighth note is followed by 1 note head width (NHW).
8255 The quarter note is followed by 2 NHW, the half by 3 NHW, etc.
8256 @lilypond[fragment, verbatim, relative=1] c2 c4. c8 c4. c8 c4. c8 c8
8260 Normally, @code{shortest-duration-space} is set to 1.2, which is the
8261 width of a note head, and @code{shortest-duration-space} is set to
8262 2.0, meaning that the shortest note gets 2 NHW (2 times
8263 @code{shortest-duration-space}) of space. For normal notes, this space
8264 is always counted from the left edge of the symbol, so the shortest
8265 notes are generally followed by one NHW of space.
8267 If one would follow the above procedure exactly, then adding a single
8268 32th note to a score that uses 8th and 16th notes, would widen up the
8269 entire score a lot. The shortest note is no longer a 16th, but a 32nd,
8270 thus adding 2 noteheads of space to every note. To prevent this, the
8271 shortest duration for spacing is not the shortest note in the score,
8272 but the most commonly found shortest note. Notes that are even
8273 shorter this are followed by a space that is proportonial to their
8274 duration relative to the common shortest note. So if we were to add
8275 only a few 16th notes to the example above, they would be followed by
8278 @lilypond[fragment, verbatim, relative=2]
8279 c2 c4. c8 c4. c16[ c] c4. c8 c8 c8 c4 c4 c4
8282 The most common shortest duration is determined as follows: in every
8283 measure, the shortest duration is determined. The most common short
8284 duration, is taken as the basis for the spacing, with the stipulation
8285 that this shortest duration should always be equal to or shorter than
8286 1/8th note. The shortest duration is printed when you run lilypond
8287 with @code{--verbose}. These durations may also be customized. If you
8288 set the @code{common-shortest-duration} in
8289 @internalsref{SpacingSpanner}, then this sets the base duration for
8290 spacing. The maximum duration for this base (normally 1/8th), is set
8291 through @code{base-shortest-duration}.
8293 @cindex @code{common-shortest-duration}
8294 @cindex @code{base-shortest-duration}
8295 @cindex @code{stem-spacing-correction}
8296 @cindex @code{spacing}
8298 In the introduction it was explained that stem directions influence
8299 spacing. This is controlled with @code{stem-spacing-correction}
8300 property in @internalsref{NoteSpacing}, which are generated for every
8301 @internalsref{Voice} context. The @code{StaffSpacing} object
8302 (generated at @internalsref{Staff} context) contains the same property
8303 for controlling the stem/barline spacing. The following example
8304 shows these corrections, once with default settings, and once with
8305 exaggerated corrections:
8311 \property Staff.NoteSpacing \override #'stem-spacing-correction
8313 \property Staff.StaffSpacing \override #'stem-spacing-correction
8318 \paper { raggedright = ##t } }
8321 @cindex SpacingSpanner, overriding properties
8323 Properties of the @internalsref{SpacingSpanner} must be overridden
8324 from the @code{\paper} block, since the @internalsref{SpacingSpanner} is
8325 created before any @code{\property} statements are interpreted.
8327 \paper @{ \translator @{
8329 SpacingSpanner \override #'spacing-increment = #3.0
8336 @internalsref{SpacingSpanner}, @internalsref{NoteSpacing},
8337 @internalsref{StaffSpacing}, @internalsref{SeparationItem}, and
8338 @internalsref{SeparatingGroupSpanner}.
8342 Spacing is determined on a score wide basis. If you have a score that
8343 changes its character (measured in durations) halfway during the
8344 score, the part containing the longer durations will be spaced too
8347 There is no convenient mechanism to manually override spacing.
8352 @subsection Font size
8353 @cindex font size, setting
8354 @cindex staff size, setting
8355 @cindex @code{paper} file
8357 The Feta font provides musical symbols at seven different sizes.
8358 These fonts are 11 point, 13 point, 16 point, 20 point, 23 point, and
8359 26 point. The point size of a font is the height of the corresponding
8360 staff (excluding line thicknesses).
8362 Definitions for these sizes are the files @file{paperSZ.ly}, where
8363 @code{SZ} is one of 11, 13, 16, 20, 23 and 26. If you include any
8364 of these files, the variables @code{paperEleven},
8365 @code{paperThirteen}, @code{paperSixteen},
8366 @code{paperTwenty}, @code{paperTwentythree}, and @code{paperTwentysix}
8367 are defined respectively. The default @code{\paper} block is also
8368 set. These files should be imported at toplevel, i.e.
8370 \include "paper26.ly"
8374 The default font size settings for each staff heights are generated
8375 from the 20pt style sheet. For more details, see the file
8376 @file{scm/font.scm}.
8380 @subsection Line breaking
8383 @cindex breaking lines
8385 Line breaks are normally computed automatically. They are chosen such
8386 that lines look neither cramped nor loose, and that consecutive lines
8387 have similar density.
8389 Occasionally you might want to override the automatic breaks; you can
8390 do this by specifying @code{\break}. This will force a line break at
8391 this point. Line breaks can only occur at places where there are bar
8392 lines. If you want to have a line break where there is no bar line,
8393 you can force an invisible bar line by entering @code{\bar
8394 ""}. Similarly, @code{\noBreak} forbids a line break at a
8398 @cindex regular line breaks
8399 @cindex four bar music.
8401 For linebreaks at regular intervals use @code{\break} separated by
8402 skips and repeated with @code{\repeat}:
8404 << \repeat unfold 7 @{ s1 * 4 \break @}
8405 @emph{the real music}
8410 This makes the following 28 measures (assuming 4/4 time) be broken every
8415 @internalsref{BreakEvent}.
8419 @subsection Page layout
8422 @cindex breaking pages
8424 @cindex @code{indent}
8425 @cindex @code{linewidth}
8427 The most basic settings influencing the spacing are @code{indent} and
8428 @code{linewidth}. They are set in the @code{\paper} block. They
8429 control the indentation of the first line of music, and the lengths of
8432 If @code{raggedright} is set to true in the @code{\paper}
8433 block, then the lines are justified at their natural length. This
8434 useful for short fragments, and for checking how tight the natural
8438 @cindex vertical spacing
8440 The page layout process happens outside the LilyPond formatting
8441 engine: variables controlling page layout are passed to the output,
8442 and are further interpreted by @code{lilypond} wrapper program. It
8443 responds to the following variables in the @code{\paper} block. The
8444 variable @code{textheight} sets the total height of the music on each
8445 page. The spacing between systems is controlled with
8446 @code{interscoreline}, its default is 16pt. The distance between the
8447 score lines will stretch in order to fill the full page
8448 @code{interscorelinefill} is set to a positive number. In that case
8449 @code{interscoreline} specifies the minimum spacing.
8451 @cindex @code{textheight}
8452 @cindex @code{interscoreline}
8453 @cindex @code{interscorelinefill}
8455 If the variable @code{lastpagefill} is defined,
8456 @c fixme: this should only be done if lastpagefill == #t
8457 systems are evenly distributed vertically on the last page. This
8458 might produce ugly results in case there are not enough systems on the
8459 last page. The @command{lilypond-book} command ignores
8460 @code{lastpagefill}. See @ref{lilypond-book manual} for more
8463 @cindex @code{lastpagefill}
8465 Page breaks are normally computed by @TeX{}, so they are not under
8466 direct control of LilyPond. However, you can insert a commands into
8467 the @file{.tex} output to instruct @TeX{} where to break pages. This
8468 is done by setting the @code{between-systems-strings} on the
8469 @internalsref{NonMusicalPaperColumn} where the system is broken.
8470 An example is shown in @inputfileref{input/regression,between-systems.ly}.
8471 The predefined command @code{\newpage} also does this.
8475 @cindex @code{papersize}
8477 To change the paper size, you must first set the @code{papersize} paper
8478 variable variable as in the example below. Set it to
8479 the strings @code{a4}, @code{letter}, or @code{legal}. After this
8480 specification, you must set the font as described above. If you want
8481 the default font, then use the 20 point font.
8484 \paper@{ papersize = "a4" @}
8485 \include "paper16.ly"
8488 The file @code{paper16.ly} will now include a file named @file{a4.ly}, which
8489 will set the paper variables @code{hsize} and @code{vsize} (used by
8490 @code{lilypond-book} and @code{lilypond}).
8495 @cindex @code{\newpage}
8501 @ref{Invoking lilypond},
8502 @inputfileref{input/regression,between-systems.ly}, and
8503 @internalsref{NonMusicalPaperColumn}.
8507 LilyPond has no concept of page layout, which makes it difficult to
8508 reliably choose page breaks in longer pieces.
8517 Entered music can also be converted to MIDI output. The performance
8518 is good enough for proof-hearing the music for errors.
8520 Ties, dynamics and tempo changes are interpreted. Dynamic marks,
8521 crescendi and decrescendi translate into MIDI volume levels. Dynamic
8522 marks translate to a fixed fraction of the available MIDI volume
8523 range, crescendi and decrescendi make the volume vary linearly between
8524 their two extremities. The fractions can be adjusted by
8525 @code{dynamicAbsoluteVolumeFunction} in @internalsref{Voice} context.
8526 For each type of MIDI instrument, a volume range can be defined. This
8527 gives a basic equalizer control, which can enhance the quality of
8528 the MIDI output remarkably. The equalizer can be controlled by
8529 setting @code{instrumentEqualizer}.
8533 Many musically interesting effects, such as swing, articulation,
8534 slurring, etc., are not translated to MIDI.
8539 * MIDI instrument names::
8544 @subsection MIDI block
8548 The MIDI block is analogous to the paper block, but it is somewhat
8549 simpler. The @code{\midi} block can contain:
8553 @item a @code{\tempo} definition, and
8554 @item context definitions.
8557 Assignments in the @code{\midi} block are not allowed.
8559 A number followed by a period is interpreted as a real number, so
8560 for setting the tempo for dotted notes, an extra space should be
8561 inserted, for example:
8564 \midi @{ \tempo 4 . = 120 @}
8568 @cindex context definition
8570 Context definitions follow precisely the same syntax as within the
8571 \paper block. Translation modules for sound are called performers.
8572 The contexts for MIDI output are defined in @file{ly/performer-init.ly}.
8575 @node MIDI instrument names
8576 @subsection MIDI instrument names
8578 @cindex instrument names
8579 @cindex @code{Staff.midiInstrument}
8580 @cindex @code{Staff.instrument}
8582 The MIDI instrument name is set by the @code{Staff.midiInstrument}
8583 property or, if that property is not set, the @code{Staff.instrument}
8584 property. The instrument name should be chosen from the list in
8585 @ref{MIDI instruments}.
8589 If the selected string does not exactly match, then LilyPond uses the
8590 default (Grand Piano). It is not possible to select an instrument by