1 @c -*- coding: utf-8; mode: texinfo; -*-
3 Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
5 When revising a translation, copy the HEAD committish of the
6 version that you are working on. For details, see the Contributors'
7 Guide, node Updating translation committishes..
16 @lilypondfile[quote]{pitches-headword.ly}
18 This section discusses how to specify the pitch of notes. There
19 are three steps to this process: input, modification, and output.
23 * Changing multiple pitches::
24 * Displaying pitches::
30 @subsection Writing pitches
32 This section discusses how to input pitches. There are two
33 different ways to place notes in octaves: absolute and relative
34 mode. In most cases, relative mode will be more convenient.
37 * Absolute octave entry::
38 * Relative octave entry::
40 * Note names in other languages::
44 @node Absolute octave entry
45 @unnumberedsubsubsec Absolute octave entry
50 @cindex absolute octave specification
51 @cindex octave specification, absolute
52 @cindex absolute octave entry
53 @cindex octave entry, absolute
55 A pitch name is specified using lowercase letters@tie{}@code{a}
56 through@tie{}@code{g}. The note names @code{c} to @code{b} are
57 engraved in the octave below middle C.
60 @lilypond[verbatim,quote]
69 @cindex octave changing mark
74 Other octaves may be specified with a single quote@tie{}(@code{'})
75 or comma@tie{}(@code{,}) character. Each@tie{}@code{'} raises the
76 pitch by one octave; each@tie{}@code{,} lowers the pitch by an
79 @lilypond[verbatim,quote]
92 Common octave marks can be entered just once on a reference pitch
93 after @code{\fixed} placed before the music. Pitches inside
94 @code{\fixed} only need @code{'} or@tie{}@code{,} marks
95 when they are above or below the octave of the reference pitch.
97 @lilypond[verbatim,quote]
112 Pitches in the music expression following @code{\fixed} are
113 unaffected by any enclosing @code{\relative}, discussed next.
123 @node Relative octave entry
124 @unnumberedsubsubsec Relative octave entry
127 @cindex relative octave entry
128 @cindex octave entry, relative
129 @cindex relative octave specification
130 @cindex octave specification, relative
135 Absolute octave entry requires specifying the octave for every
136 single note. Relative octave entry, in contrast, specifies each
137 octave in relation to the last note: changing one note's octave
138 will affect all of the following notes.
140 Relative note mode has to be entered explicitly using the
141 @code{\relative} command:
144 \relative @var{startpitch} @var{musicexpr}
147 In relative mode, each note is assumed to be as close to the
148 previous note as possible. This means that the octave of each
149 pitch inside @code{@var{musicexpr}} is calculated as follows:
153 If no octave changing mark is used on a pitch, its octave is
154 calculated so that the interval with the previous note is less
155 than a fifth. This interval is determined without considering
159 An octave changing mark@tie{}@code{'} or@tie{}@code{,} can be
160 added to respectively raise or lower a pitch by an extra octave,
161 relative to the pitch calculated without an octave mark.
164 Multiple octave changing marks can be used. For example,
165 @code{''}@tie{}and@tie{}@code{,,} will alter the pitch by two
169 The pitch of the first note is relative to
170 @code{@var{startpitch}}. @code{@var{startpitch}} is specified in
171 absolute octave mode. Which choices are meaningful?
174 @item an octave of @code{c}
175 Identifying middle C with @code{c'} is quite basic, so finding
176 octaves of @code{c} tends to be straightforward. If your music
177 starts with @code{gis} above @code{c'''}, you'd write something
178 like @code{\relative @{ gis''' @dots{} @}}
180 @item an octave of the first note inside
181 Writing @code{\relative @{ gis''' @dots{} @}} makes it easy to
182 determine the absolute pitch of the first note inside.
184 @item no explicit starting pitch
185 This (namely writing @code{\relative @{ gis''' @dots{} @}}) can be
186 viewed as a compact version of the previous option: the first note
187 inside is written in absolute pitch itself. This happens to be
188 equivalent to choosing @code{f} as the reference pitch.
191 The documentation will usually employ the first option.
194 Here is the relative mode shown in action:
196 @lilypond[verbatim,quote]
205 Octave changing marks are used for intervals greater than a
208 @lilypond[verbatim,quote]
215 A note sequence without a single octave mark can nevertheless span
218 @lilypond[verbatim,quote]
225 When @code{\relative} blocks are nested, the innermost
226 @code{\relative} block applies.
228 @lilypond[verbatim,quote]
237 @code{\relative} has no effect on @code{\chordmode} blocks.
239 @lilypond[verbatim,quote]
248 @code{\relative} is not allowed inside of @code{\chordmode} blocks.
250 Music inside a @code{\transpose} block is absolute unless a
251 @code{\relative} is included.
253 @lilypond[verbatim,quote]
266 @cindex chords and relative octave entry
267 @cindex relative octave entry and chords
269 If the preceding item is a chord, the first note of the chord is
270 used as the reference point for the octave placement of a
271 following note or chord. Inside chords, the next note is always
272 relative to the preceding one. Examine the next example
273 carefully, paying attention to the @code{c} notes.
275 @lilypond[verbatim,quote]
284 As explained above, the octave of pitches is calculated only with
285 the note names, regardless of any alterations. Therefore, an
286 E-double-sharp following a B will be placed higher, while an
287 F-double-flat will be placed lower. In other words, a
288 double-augmented fourth is considered a smaller interval than a
289 double-diminished fifth, regardless of the number of semitones
290 that each interval contains.
292 @lilypond[verbatim,quote]
301 One consequence of these rules is that the first note inside
302 @code{@w{\relative f}} music is interpreted just the same as
303 if it was written in absolute pitch mode.
318 @rinternals{RelativeOctaveMusic}.
320 @cindex relative octave entry and transposition
321 @cindex transposition and relative octave entry
332 @unnumberedsubsubsec Accidentals
335 @cindex key signature
338 @c duplicated in Key signature and Accidentals
339 @warning{New users are sometimes confused about accidentals and
340 key signatures. In LilyPond, note names specify pitches; key
341 signatures and clefs determine how these pitches are displayed.
342 An unaltered note like@tie{}@code{c} means @q{C natural},
343 regardless of the key signature or clef. For more information,
344 see @rlearning{Pitches and key signatures}.}
346 @cindex note names, Dutch
347 @cindex note names, default
348 @cindex default note names
352 @cindex sharp, double
356 @cindex natural pitch
358 A @notation{sharp} pitch is made by adding @code{is} to the note
359 name, and a @notation{flat} pitch by adding @code{es}. As you
360 might expect, a @notation{double sharp} or @notation{double flat}
361 is made by adding @code{isis} or @code{eses}. This syntax is
362 derived from Dutch note naming conventions. To use other names
363 for accidentals, see @ref{Note names in other languages}.
365 @lilypond[verbatim,quote,relative=2]
369 A natural pitch is entered as a simple note name; no suffix is
370 required. A natural sign will be printed when needed to cancel
371 the effect of an earlier accidental or key signature.
373 @lilypond[verbatim,quote,relative=2]
377 @cindex quarter tones
381 Quarter tones may be added; the following is a series of Cs with
384 @lilypond[verbatim,quote,relative=2]
385 ceseh1 ces ceh c cih cis cisih
390 @cindex accidental, reminder
391 @cindex accidental, cautionary
392 @cindex accidental, parenthesized
393 @cindex reminder accidental
394 @cindex cautionary accidental
395 @cindex parenthesized accidental
401 Normally accidentals are printed automatically, but you may also
402 print them manually. A reminder accidental can be forced by
403 adding an exclamation mark@tie{}@code{!} after the pitch. A
404 cautionary accidental (i.e., an accidental within parentheses) can
405 be obtained by adding the question mark@tie{}@code{?} after the
408 @lilypond[verbatim,quote,relative=2]
409 cis cis cis! cis? c c c! c?
412 @cindex accidental on tied note
413 @cindex tied note, accidental
415 Accidentals on tied notes are only printed at the beginning of a
418 @lilypond[verbatim,quote,relative=2,ragged-right]
427 @lilypondfile[verbatim,quote,texidoc,doctitle,ragged-right]
428 {hiding-accidentals-on-tied-notes-at-the-start-of-a-new-system.ly}
430 @lilypondfile[verbatim,quote,texidoc,doctitle]
431 {preventing-extra-naturals-from-being-automatically-added.ly}
437 @rglos{double sharp},
440 @rglos{quarter tone}.
443 @rlearning{Pitches and key signatures}.
446 @ref{Automatic accidentals},
447 @ref{Annotational accidentals (musica ficta)},
448 @ref{Note names in other languages}.
454 @rinternals{Accidental_engraver},
455 @rinternals{Accidental},
456 @rinternals{AccidentalCautionary},
457 @rinternals{accidental-interface}.
459 @cindex accidental, quarter-tone
460 @cindex quarter-tone accidental
463 There are no generally accepted standards for denoting
464 quarter-tone accidentals, so LilyPond's symbol does not conform to
468 @node Note names in other languages
469 @unnumberedsubsubsec Note names in other languages
471 @cindex note names, other languages
472 @cindex pitch names, other languages
473 @cindex language, note names in other
474 @cindex language, pitch names in other
476 There are predefined sets of note and accidental names for various
477 other languages. Selecting the note name language is usually done
478 at the beginning of the file; the following example is written
479 using Italian note names:
481 @lilypond[quote,verbatim]
489 The available languages and the note names they define are:
492 @multitable {@code{nederlands}} {do re mi fa sol la sib si}
495 @item @code{nederlands}
496 @tab c d e f g a bes b
498 @tab do re mi fa sol la sib si
502 @tab c d e f g a bf b
503 @item @code{espanol} or @code{español}
504 @tab do re mi fa sol la sib si
505 @item @code{italiano} or @code{français}
506 @tab do re mi fa sol la sib si
509 @item @code{portugues}
510 @tab do re mi fa sol la sib si
516 @tab do re mi fa sol la sib si
520 In addition to note names, accidental suffixes may
521 also vary depending on the language:
524 @multitable {@code{nederlands}} {-@code{s}/-@code{-sharp}} {-@code{ess}/-@code{es}} {-@code{ss}/-@code{x}/-@code{-sharpsharp}} {-@code{essess}/-@code{eses}}
526 @tab sharp @tab flat @tab double sharp @tab double flat
527 @item @code{nederlands}
528 @tab -@code{is} @tab -@code{es} @tab -@code{isis} @tab -@code{eses}
530 @tab -@code{d}/-@code{s} @tab -@code{b} @tab -@code{dd}/-@code{ss} @tab -@code{bb}
532 @tab -@code{is} @tab -@code{es} @tab -@code{isis} @tab -@code{eses}
534 @tab -@code{s}/-@code{-sharp} @tab -@code{f}/-@code{-flat} @tab -@code{ss}/-@code{x}/-@code{-sharpsharp}
535 @tab -@code{ff}/-@code{-flatflat}
536 @item @code{espanol} or @code{español}
537 @tab -@code{s} @tab -@code{b} @tab -@code{ss}/-@code{x} @tab -@code{bb}
538 @item @code{italiano} or @code{français}
539 @tab -@code{d} @tab -@code{b} @tab -@code{dd} @tab -@code{bb}
541 @tab -@code{iss}/-@code{is} @tab -@code{ess}/-@code{es} @tab -@code{ississ}/-@code{isis}
542 @tab -@code{essess}/-@code{eses}
543 @item @code{portugues}
544 @tab -@code{s} @tab -@code{b} @tab -@code{ss} @tab -@code{bb}
546 @tab -@code{is} @tab -@code{es} @tab -@code{isis} @tab -@code{eses}
548 @tab -@code{iss} @tab -@code{ess} @tab -@code{ississ} @tab -@code{essess}
550 @tab -@code{k} @tab -@code{b} @tab -@code{kk} @tab -@code{bb}
554 In Dutch, @code{aes} is contracted to @code{as}, but both forms
555 are accepted in LilyPond. Similarly, both @code{es} and
556 @code{ees} are accepted. This also applies to
557 @code{aeses}@tie{}/@tie{}@code{ases} and
558 @code{eeses}@tie{}/@tie{}@code{eses}. Sometimes only these
559 contracted names are defined in the corresponding language files.
561 @lilypond[verbatim,quote,relative=2]
562 a2 as e es a ases e eses
572 Some music uses microtones whose alterations are fractions of a
573 @q{normal} sharp or flat. The following table lists note names
574 for quarter-tone accidentals in various languages; here the prefixes
575 @notation{semi-} and @notation{sesqui-} respectively
576 mean @q{half} and @q{one and a half}. Languages that do not
577 appear in this table do not provide special note names yet.
580 @multitable {@code{nederlands}} {@b{semi-sharp}} {@b{semi-flat}} {@b{sesqui-sharp}} {@b{sesqui-flat}}
582 @tab semi-sharp @tab semi-flat @tab sesqui-sharp @tab sesqui-flat
584 @item @code{nederlands}
585 @tab -ih @tab -eh @tab -isih @tab -eseh
587 @tab -ih @tab -eh @tab -isih @tab -eseh
589 @tab -qs @tab -qf @tab -tqs @tab -tqf
590 @item @code{espanol} or @code{español}
591 @tab -cs @tab -cb @tab -tcs @tab -tcb
592 @item @code{italiano} or @code{français}
593 @tab -sd @tab -sb @tab -dsd @tab -bsb
594 @item @code{portugues}
595 @tab -sqt @tab -bqt @tab -stqt @tab -btqt
599 Most languages presented here are commonly associated with
600 Western classical music, also referred to as
601 @notation{Common Practice Period}. However, alternate
602 pitches and tuning systems are also supported: see
603 @ref{Common notation for non-Western music}.
608 @rglos{Common Practice Period}.
611 @ref{Common notation for non-Western music}.
614 @file{scm/define-note-names.scm}.
620 @node Changing multiple pitches
621 @subsection Changing multiple pitches
623 This section discusses how to modify pitches.
630 * Modal transformations::
634 @unnumberedsubsubsec Octave checks
636 @cindex octave correction
638 @cindex control pitch
641 @funindex \octaveCheck
642 @funindex octaveCheck
643 @funindex controlpitch
645 In relative mode, it is easy to forget an octave changing mark.
646 Octave checks make such errors easier to find by displaying a
647 warning and correcting the octave if a note is found in an
650 To check the octave of a note, specify the absolute octave after
651 the @code{=}@tie{}symbol. This example will generate a warning
652 (and change the pitch) because the second note is the absolute
653 octave @code{d''} instead of @code{d'} as indicated by the octave
656 @lilypond[verbatim,quote]
663 The octave of notes may also be checked with the
664 @code{\octaveCheck@tie{}@var{controlpitch}} command.
665 @code{@var{controlpitch}} is specified in absolute mode. This
666 checks that the interval between the previous note and the
667 @code{@var{controlpitch}} is within a fourth (i.e., the normal
668 calculation of relative mode). If this check fails, a warning is
669 printed, but the previous note is not changed. Future notes are
670 relative to the @code{@var{controlpitch}}.
672 @lilypond[verbatim,quote]
680 Compare the two bars below. The first and third @code{\octaveCheck}
681 checks fail, but the second one does not fail.
683 @lilypond[verbatim,quote]
702 @rinternals{RelativeOctaveCheck}.
706 @unnumberedsubsubsec Transpose
710 @cindex transposition
711 @cindex transposition of pitches
712 @cindex transposition of notes
713 @cindex pitches, transposition of
714 @cindex notes, transposition of
719 A music expression can be transposed with @code{\transpose}. The
723 \transpose @var{frompitch} @var{topitch} @var{musicexpr}
727 This means that @code{@var{musicexpr}} is transposed by the
728 interval between the pitches @code{@var{frompitch}} and
729 @code{@var{topitch}}: any note with pitch @code{@var{frompitch}}
730 is changed to @code{@var{topitch}} and any other note is
731 transposed by the same interval. Both pitches are entered in
734 @warning{Music inside a @code{@bs{}transpose} block is absolute
735 unless a @code{@bs{}relative} is included in the block.}
737 Consider a piece written in the key of D-major. It can be
738 transposed up to E-major; note that the key signature is
739 automatically transposed as well.
741 @lilypond[verbatim,quote]
750 @cindex transposing instruments
751 @cindex instruments, transposing
753 If a part written in C (normal @notation{concert pitch}) is to be
754 played on the A clarinet (for which an A is notated as a C and
755 thus sounds a minor third lower than notated), the appropriate
756 part will be produced with:
758 @lilypond[verbatim,quote]
768 Note that we specify @w{@code{\key c \major}} explicitly. If we
769 do not specify a key signature, the notes will be transposed but
770 no key signature will be printed.
772 @code{\transpose} distinguishes between enharmonic pitches: both
773 @w{@code{\transpose c cis}} or @w{@code{\transpose c des}} will
774 transpose up a semitone. The first version will print sharps and
775 the notes will remain on the same scale step, the second version
776 will print flats on the scale step above.
778 @lilypond[verbatim,quote]
779 music = \relative { c' d e f }
781 \transpose c cis { \music }
782 \transpose c des { \music }
787 @code{\transpose} may also be used in a different way, to input
788 written notes for a transposing instrument. The previous examples
789 show how to enter pitches in C (or @notation{concert pitch}) and
790 typeset them for a transposing instrument, but the opposite is
791 also possible if you for example have a set of instrumental parts
792 and want to print a conductor's score. For example, when entering
793 music for a B-flat trumpet that begins on a notated E (concert D),
797 musicInBflat = @{ e4 @dots{} @}
798 \transpose c bes, \musicInBflat
802 To print this music in F (e.g., rearranging to a French horn) you
803 could wrap the existing music with another @code{\transpose}:
806 musicInBflat = @{ e4 @dots{} @}
807 \transpose f c' @{ \transpose c bes, \musicInBflat @}
811 For more information about transposing instruments,
812 see @ref{Instrument transpositions}.
817 @lilypondfile[verbatim,quote,texidoc,doctitle]
818 {transposing-pitches-with-minimum-accidentals-smart-transpose.ly}
822 @ref{Instrument transpositions},
824 @ref{Modal transformations},
825 @ref{Relative octave entry},
832 @rinternals{TransposedMusic}.
842 The relative conversion will not affect @code{\transpose},
843 @code{\chordmode} or @code{\relative} sections in its argument. To use
844 relative mode within transposed music, an additional @code{\relative}
845 must be placed inside @code{\transpose}.
847 Triple accidentals will not be printed if using @code{\transpose}. An
848 @q{enharmonically equivalent} pitch will be used instead (e.g. d-flat
849 rather than e-triple-flat).
853 @unnumberedsubsubsec Inversion
856 @cindex operation, inversion
859 A music expression can be inverted and transposed in a single
863 \inversion @var{around-pitch} @var{to-pitch} @var{musicexpr}
866 The @code{@var{musicexpr}} is inverted interval-by-interval around
867 @code{@var{around-pitch}}, and then transposed so that
868 @code{@var{around-pitch}} is mapped to @code{@var{to-pitch}}.
870 @lilypond[verbatim,quote]
871 music = \relative { c' d e f }
874 \inversion d' d' \music
875 \inversion d' ees' \music
879 @warning{Motifs to be inverted should be expressed in absolute form
880 or be first converted to absolute form by enclosing them in a
881 @code{\relative} block.}
885 @ref{Modal transformations},
891 @unnumberedsubsubsec Retrograde
893 @cindex retrograde transformation
894 @cindex transformation, retrograde
895 @cindex operation, retrograde
896 @funindex \retrograde
899 A music expression can be reversed to produce its retrograde:
901 @lilypond[verbatim,quote]
902 music = \relative { c'8. ees16( fis8. a16 b8.) gis16 f8. d16 }
911 Manual ties inside @code{\retrograde} will be broken and
912 generate warnings. Some ties can be generated automatically
913 by enabling @ref{Automatic note splitting}.
918 @ref{Modal transformations},
922 @node Modal transformations
923 @unnumberedsubsubsec Modal transformations
925 @cindex modal transformations
926 @cindex transformations, modal
927 @cindex operations, modal
929 In a musical composition that is based on a scale, a motif is
930 frequently transformed in various ways. It may be
931 @notation{transposed} to start at different places in the scale or
932 it may be @notation{inverted} around a pivot point in the scale.
933 It may also be reversed to produce its @notation{retrograde}, see
936 @warning{Any note that does not lie within the given scale will be
939 @subsubsubheading Modal transposition
941 @cindex modal transposition
942 @cindex transposition, modal
943 @cindex operation, transposition
944 @funindex \modalTranspose
945 @funindex modalTranspose
947 A motif can be transposed within a given scale with:
950 \modalTranspose @var{from-pitch} @var{to-pitch} @var{scale} @var{motif}
953 The notes of @var{motif} are shifted within the @var{scale} by the
954 number of scale degrees given by the interval between @var{to-pitch}
955 and @var{from-pitch}:
957 @lilypond[verbatim,quote]
958 diatonicScale = \relative { c' d e f g a b }
959 motif = \relative { c'8 d e f g a b c }
963 \modalTranspose c f \diatonicScale \motif
964 \modalTranspose c b, \diatonicScale \motif
968 An ascending scale of any length and with any intervals may be
971 @lilypond[verbatim,quote]
972 pentatonicScale = \relative { ges aes bes des ees }
973 motif = \relative { ees'8 des ges,4 <ges' bes,> <ges bes,> }
977 \modalTranspose ges ees' \pentatonicScale \motif
981 When used with a chromatic scale @code{\modalTranspose} has a
982 similar effect to @code{\transpose}, but with the ability to
983 specify the names of the notes to be used:
985 @lilypond[verbatim,quote]
986 chromaticScale = \relative { c' cis d dis e f fis g gis a ais b }
987 motif = \relative { c'8 d e f g a b c }
991 \transpose c f \motif
992 \modalTranspose c f \chromaticScale \motif
996 @subsubsubheading Modal inversion
998 @cindex modal inversion
999 @cindex inversion, modal
1000 @cindex operation, modal inversion
1001 @funindex \modalInversion
1002 @funindex modalInversion
1004 A motif can be inverted within a given scale around a given pivot
1005 note and transposed in a single operation with:
1008 \modalInversion @var{around-pitch} @var{to-pitch} @var{scale} @var{motif}
1011 The notes of @var{motif} are placed the same number of scale degrees
1012 from the @var{around-pitch} note within the @var{scale}, but in the
1013 opposite direction, and the result is then shifted within the
1014 @var{scale} by the number of scale degrees given by the interval between
1015 @var{to-pitch} and @var{around-pitch}.
1017 So to simply invert around a note in the scale use the same value for
1018 @var{around-pitch} and @var{to-pitch}:
1020 @lilypond[verbatim,quote]
1021 octatonicScale = \relative { ees' f fis gis a b c d }
1022 motif = \relative { c'8. ees16 fis8. a16 b8. gis16 f8. d16 }
1026 \modalInversion fis' fis' \octatonicScale \motif
1030 To invert around a pivot between two notes in the scale, invert around
1031 one of the notes and then transpose by one scale degree. The two notes
1032 specified can be interpreted as bracketing the pivot point:
1034 @lilypond[verbatim,quote]
1035 scale = \relative { c' g' }
1036 motive = \relative { c' c g' c, }
1040 \modalInversion c' g' \scale \motive
1044 The combined operation of inversion and retrograde produce the
1045 retrograde-inversion:
1047 @lilypond[verbatim,quote]
1048 octatonicScale = \relative { ees' f fis gis a b c d }
1049 motif = \relative { c'8. ees16 fis8. a16 b8. gis16 f8. d16 }
1053 \retrograde \modalInversion c' c' \octatonicScale \motif
1064 @node Displaying pitches
1065 @subsection Displaying pitches
1067 This section discusses how to alter the output of pitches.
1073 * Instrument transpositions::
1074 * Automatic accidentals::
1080 @unnumberedsubsubsec Clef
1091 @cindex soprano clef
1092 @cindex mezzosoprano clef
1093 @cindex baritone clef
1094 @cindex varbaritone clef
1095 @cindex subbass clef
1097 @cindex ancient clef
1098 @cindex clef, ancient
1102 @cindex clef, treble
1103 @cindex clef, violin
1107 @cindex clef, french
1108 @cindex clef, soprano
1109 @cindex clef, mezzosoprano
1110 @cindex clef, baritone
1111 @cindex clef, varbaritone
1112 @cindex clef, subbass
1118 Without any explicit command, the default clef for LilyPond is the
1119 treble (or @emph{G}) clef.
1121 @lilypond[verbatim,quote,relative=1,ragged-right]
1125 However, the clef can be changed by using the @code{\clef} command and
1126 an appropriate clef name. @emph{Middle C} is shown in each of the
1129 @lilypond[verbatim,quote,relative=1]
1140 For the full range of possible clef names see @ref{Clef styles}.
1142 Specialized clefs, such as those used in @emph{Ancient} music, are
1143 described in @ref{Mensural clefs} and @ref{Gregorian clefs}. Music that
1144 requires tablature clefs is discussed in @ref{Default tablatures} and
1145 @ref{Custom tablatures}.
1148 @cindex Clefs with cue notes
1149 For mixing clefs when using cue notes, see the @code{\cueClef} and
1150 @code{\cueDuringWithClef} commands in @ref{Formatting cue notes}.
1152 @cindex transposing clef
1153 @cindex clef, transposing
1154 @cindex octave transposition
1155 @cindex optional octave transposition
1156 @cindex octave transposition, optional
1157 @cindex choral tenor clef
1158 @cindex tenor clef, choral
1160 By adding@tie{}@code{_8} or@tie{}@code{^8} to the clef name, the
1161 clef is transposed one octave down or up respectively,
1162 and@tie{}@code{_15} and@tie{}@code{^15} transpose by two octaves.
1163 Other integers can be used if required. Clef names containing
1164 non-alphabetic characters must be enclosed in quotes
1166 @lilypond[verbatim,quote,relative=1]
1181 Optional octavation can be obtained by enclosing the numeric
1182 argument in parentheses or brackets:
1184 @lilypond[verbatim,quote,relative=1]
1191 The pitches are displayed as if the numeric argument were
1192 given without parentheses/brackets.
1194 By default, a clef change taking place at a line break will cause
1195 the new clef symbol to be printed at the end of the previous line,
1196 as a @emph{warning} clef, as well as the beginning of the next.
1197 This @emph{warning} clef can be suppressed.
1199 @lilypond[verbatim,quote,relative=1]
1200 \clef treble { c2 c } \break
1201 \clef bass { c2 c } \break
1203 \set Staff.explicitClefVisibility = #end-of-line-invisible
1205 \unset Staff.explicitClefVisibility
1206 \clef bass { c2 c } \break
1209 By default, a clef that has previously been printed will not be
1210 re-printed if the same @code{\clef} command is issued again and
1211 will be ignored. The the command
1212 @code{\set Staff.forceClef = ##t} changes this behaviour.
1214 @lilypond[verbatim,quote,relative=1]
1219 \set Staff.forceClef = ##t
1225 When there is a manual clef change, the glyph of the changed clef
1226 will be smaller than normal. This behaviour can be overridden.
1228 @lilypond[verbatim,quote,relative=1]
1235 \override Staff.Clef.full-size-change = ##t
1240 \revert Staff.Clef.full-size-change
1248 @lilypondfile[verbatim,quote,texidoc,doctitle]
1249 {tweaking-clef-properties.ly}
1253 @ref{Mensural clefs},
1254 @ref{Gregorian clefs},
1255 @ref{Default tablatures},
1256 @ref{Custom tablatures},
1257 @ref{Formatting cue notes}.
1260 @file{scm/parser-clef.scm}.
1265 Internals Reference:
1266 @rinternals{Clef_engraver},
1268 @rinternals{ClefModifier},
1269 @rinternals{clef-interface}.
1272 Ottavation numbers attached to clefs are treated as separate
1273 grobs. So any @code{\override} done to the @var{Clef} will also
1274 need to be applied, as a separate @code{\override}, to the
1275 @var{ClefModifier} grob.
1277 @lilypond[fragment,quote,verbatim,relative=1]
1279 \override Clef.color = #blue
1280 \override ClefModifier.color = #red
1288 @unnumberedsubsubsec Key signature
1290 @cindex key signature
1295 @c duplicated in Key signature and Accidentals
1296 @warning{New users are sometimes confused about accidentals and
1297 key signatures. In LilyPond, note names are the raw input; key
1298 signatures and clefs determine how this raw input is displayed.
1299 An unaltered note like@tie{}@code{c} means @q{C natural},
1300 regardless of the key signature or clef. For more information,
1301 see @rlearning{Pitches and key signatures}.}
1303 The key signature indicates the tonality in which a piece is
1304 played. It is denoted by a set of alterations (flats or sharps)
1305 at the start of the staff. The key signature may be altered:
1308 \key @var{pitch} @var{mode}
1321 @funindex \mixolydian
1322 @funindex mixolydian
1330 @cindex church modes
1343 Here, @code{@var{mode}} should be @code{\major} or @code{\minor}
1344 to get a key signature of @code{@var{pitch}}-major or
1345 @code{@var{pitch}}-minor, respectively. You may also use the
1346 standard mode names, also called @notation{church modes}:
1347 @code{\ionian}, @code{\dorian}, @code{\phrygian}, @code{\lydian},
1348 @code{\mixolydian}, @code{\aeolian}, and @code{\locrian}.
1350 @lilypond[verbatim,quote,relative=2]
1357 Additional modes can be defined, by listing the alterations
1358 for each scale step when the mode starts on C.
1360 @lilypond[verbatim,quote]
1361 freygish = #`((0 . ,NATURAL) (1 . ,FLAT) (2 . ,NATURAL)
1362 (3 . ,NATURAL) (4 . ,NATURAL) (5 . ,FLAT) (6 . ,FLAT))
1365 \key c \freygish c'4 des e f
1366 \bar "||" \key d \freygish d es fis g
1370 Accidentals in the key signature may be printed in octaves other
1371 than their traditional positions, or in multiple octaves, by
1372 using the @code{flat-positions} and @code{sharp-positions}
1373 properties of @code{KeySignature}. Entries in these properties
1374 specify the range of staff-positions where accidentals will be
1375 printed. If a single position is specified in an entry, the
1376 accidentals are placed within the octave ending at that staff
1379 @lilypond[verbatim, quote,relative=0]
1380 \override Staff.KeySignature.flat-positions = #'((-5 . 5))
1381 \override Staff.KeyCancellation.flat-positions = #'((-5 . 5))
1382 \clef bass \key es \major es g bes d
1383 \clef treble \bar "||" \key es \major es g bes d
1385 \override Staff.KeySignature.sharp-positions = #'(2)
1386 \bar "||" \key b \major b fis b2
1391 @lilypondfile[verbatim,quote,texidoc,doctitle]
1392 {preventing-natural-signs-from-being-printed-when-the-key-signature-changes.ly}
1394 @lilypondfile[verbatim,quote,texidoc,doctitle]
1395 {non-traditional-key-signatures.ly}
1400 @rglos{church mode},
1404 @rlearning{Pitches and key signatures}.
1409 Internals Reference:
1410 @rinternals{KeyChangeEvent},
1411 @rinternals{Key_engraver},
1412 @rinternals{Key_performer},
1413 @rinternals{KeyCancellation},
1414 @rinternals{KeySignature},
1415 @rinternals{key-signature-interface}.
1418 @node Ottava brackets
1419 @unnumberedsubsubsec Ottava brackets
1427 @funindex set-octavation
1431 @notation{Ottava brackets} introduce an extra transposition of an
1432 octave for the staff:
1434 @lilypond[verbatim,quote,relative=2]
1450 @lilypondfile[verbatim,quote,texidoc,doctitle]
1453 @lilypondfile[verbatim,quote,texidoc,doctitle]
1454 {adding-an-ottava-marking-to-a-single-voice.ly}
1456 @lilypondfile[verbatim,quote,texidoc,doctitle]
1457 {modifying-the-ottava-spanner-slope.ly}
1466 Internals Reference:
1467 @rinternals{Ottava_spanner_engraver},
1468 @rinternals{OttavaBracket},
1469 @rinternals{ottava-bracket-interface}.
1472 @node Instrument transpositions
1473 @unnumberedsubsubsec Instrument transpositions
1475 @cindex transposition, MIDI
1476 @cindex transposition, instrument
1477 @cindex transposing instrument
1479 @cindex MIDI transposition
1481 @funindex \transposition
1482 @funindex transposition
1484 When typesetting scores that involve transposing instruments, some
1485 parts can be typeset in a different pitch than the
1486 @notation{concert pitch}. In these cases, the key of the
1487 @notation{transposing instrument} should be specified; otherwise
1488 the MIDI output and cues in other parts will produce incorrect
1489 pitches. For more information about quotations, see
1490 @ref{Quoting other voices}.
1493 \transposition @var{pitch}
1496 The pitch to use for @code{\transposition} should correspond to
1497 the real sound heard when a@tie{}@code{c'} written on the staff is
1498 played by the transposing instrument. This pitch is entered in
1499 absolute mode, so an instrument that produces a real sound which
1500 is one tone higher than the printed music should use
1501 @w{@code{\transposition d'}}. @code{\transposition} should
1502 @emph{only} be used if the pitches are @emph{not} being entered in
1505 Here are a few notes for violin and B-flat clarinet where the
1506 parts have been entered using the notes and key as they appear in
1507 each part of the conductor's score. The two instruments are
1510 @lilypond[verbatim,quote]
1512 \new Staff = "violin" {
1514 \set Staff.instrumentName = #"Vln"
1515 \set Staff.midiInstrument = #"violin"
1516 % not strictly necessary, but a good reminder
1523 \new Staff = "clarinet" {
1525 \set Staff.instrumentName = \markup { Cl (B\flat) }
1526 \set Staff.midiInstrument = #"clarinet"
1536 The @code{\transposition} may be changed during a piece. For
1537 example, a clarinetist may be required to switch from an A clarinet
1538 to a B-flat clarinet.
1540 @lilypond[verbatim,quote]
1541 flute = \relative c'' {
1543 \cueDuring #"clarinet" #DOWN {
1544 R1 _\markup\tiny "clarinet"
1546 R1 _\markup\tiny "clarinet"
1549 clarinet = \relative c'' {
1553 R1^\markup { muta in B\flat }
1558 \addQuote "clarinet" \clarinet
1560 \new Staff \with { instrumentName = #"Flute" }
1562 \new Staff \with { instrumentName = #"Cl (A)" }
1569 @rglos{concert pitch},
1570 @rglos{transposing instrument}.
1573 @ref{Quoting other voices},
1580 @node Automatic accidentals
1581 @unnumberedsubsubsec Automatic accidentals
1583 @cindex accidental style
1584 @cindex accidental style, default
1586 @cindex accidentals, automatic
1587 @cindex automatic accidentals
1588 @cindex default accidental style
1590 @funindex \accidentalStyle
1594 There are many different conventions on how to typeset
1595 accidentals. LilyPond provides a function to specify which
1596 accidental style to use. This function is called as follows:
1600 \accidentalStyle voice
1605 The accidental style applies to the current @code{Staff} by
1606 default (with the exception of the styles @code{piano} and
1607 @code{piano-cautionary}, which are explained below). Optionally,
1608 the function can take a second argument that determines in which
1609 scope the style should be changed. For example, to use the same
1610 style in all staves of the current @code{StaffGroup}, use:
1613 \accidentalStyle StaffGroup.voice
1616 The following accidental styles are supported. To demonstrate
1617 each style, we use the following example:
1620 @lilypond[verbatim,quote]
1624 cis''8 fis, bes4 <a cis>8 f bis4 |
1638 \voiceTwo \relative {
1639 <fis a cis>8[ <fis a cis>
1642 \change Staff = down
1647 \change Staff = down
1648 <fis, a cis>4 gis <f a d>2 |
1655 \context Staff = "up" {
1656 \accidentalStyle default
1659 \context Staff = "down" {
1660 \accidentalStyle default
1667 Note that the last lines of this example can be replaced by the
1668 following, as long as the same accidental style should be used in
1674 \context Staff = "up" @{
1675 %%% change the next line as desired:
1676 \accidentalStyle Score.default
1679 \context Staff = "down" @{
1687 @c don't use verbatim in this table.
1691 @cindex default accidental style
1692 @cindex accidental style, default
1696 This is the default typesetting behavior. It corresponds to
1697 eighteenth-century common practice: accidentals are remembered to
1698 the end of the measure in which they occur and only in their own
1699 octave. Thus, in the example below, no natural signs are printed
1700 before the@tie{}@code{b} in the second measure or the
1707 cis''8 fis, bes4 <a cis>8 f bis4 |
1721 \voiceTwo \relative {
1722 <fis a cis>8[ <fis a cis>
1725 \change Staff = down
1730 \change Staff = down
1731 <fis, a cis>4 gis <f a d>2 |
1738 \context Staff = "up" {
1739 \accidentalStyle default
1742 \context Staff = "down" {
1743 \accidentalStyle default
1752 @cindex accidental style, voice
1753 @cindex voice accidental style
1754 @cindex accidental style, modern
1755 @cindex modern accidental style
1756 @cindex accidental style, modern-cautionary
1757 @cindex modern-cautionary accidental style
1761 The normal behavior is to remember the accidentals at
1762 @code{Staff}-level. In this style, however, accidentals are
1763 typeset individually for each voice. Apart from that, the rule is
1764 similar to @code{default}.
1766 As a result, accidentals from one voice do not get canceled in
1767 other voices, which is often an unwanted result: in the following
1768 example, it is hard to determine whether the second@tie{}@code{a}
1769 should be played natural or sharp. The @code{voice} option should
1770 therefore be used only if the voices are to be read solely by
1771 individual musicians. If the staff is to be used by one musician
1772 (e.g., a conductor or in a piano score) then @code{modern} or
1773 @code{modern-cautionary} should be used instead.
1780 cis''8 fis, bes4 <a cis>8 f bis4 |
1794 \voiceTwo \relative {
1795 <fis a cis>8[ <fis a cis>
1798 \change Staff = down
1803 \change Staff = down
1804 <fis, a cis>4 gis <f a d>2 |
1811 \context Staff = "up" {
1812 \accidentalStyle voice
1815 \context Staff = "down" {
1816 \accidentalStyle voice
1825 @cindex accidentals, modern style
1826 @cindex modern style accidentals
1830 This rule corresponds to the common practice in the twentieth
1831 century. It omits some extra natural signs, which were
1832 traditionally prefixed to a sharp following a double sharp,
1833 or a flat following a double flat. The @code{modern} rule
1834 prints the same accidentals as @code{default}, with
1835 two additions that serve to avoid ambiguity: after temporary
1836 accidentals, cancellation marks are printed also in the following
1837 measure (for notes in the same octave) and, in the same measure,
1838 for notes in other octaves. Hence the naturals before
1839 the@tie{}@code{b} and the@tie{}@code{c} in the second measure of
1846 cis''8 fis, bes4 <a cis>8 f bis4 |
1860 \voiceTwo \relative {
1861 <fis a cis>8[ <fis a cis>
1864 \change Staff = down
1869 \change Staff = down
1870 <fis, a cis>4 gis <f a d>2 |
1877 \context Staff = "up" {
1878 \accidentalStyle modern
1881 \context Staff = "down" {
1882 \accidentalStyle modern
1889 @item modern-cautionary
1891 @cindex accidentals, modern cautionary style
1892 @cindex modern accidental style
1893 @cindex modern cautionary accidental style
1894 @cindex modern style accidentals
1895 @cindex modern style cautionary accidentals
1897 @funindex modern-cautionary
1899 This rule is similar to @code{modern}, but the @q{extra}
1900 accidentals (the ones not typeset by @code{default}) are typeset
1901 as cautionary accidentals. They are by default printed with
1902 parentheses, but they can also be printed in reduced size by
1903 defining the @code{cautionary-style} property of
1904 @code{AccidentalSuggestion}.
1910 cis''8 fis, bes4 <a cis>8 f bis4 |
1924 \voiceTwo \relative {
1925 <fis a cis>8[ <fis a cis>
1928 \change Staff = down
1933 \change Staff = down
1934 <fis, a cis>4 gis <f a d>2 |
1941 \context Staff = "up" {
1942 \accidentalStyle modern-cautionary
1945 \context Staff = "down" {
1946 \accidentalStyle modern-cautionary
1955 @cindex accidental style, modern
1956 @cindex accidentals, modern
1957 @cindex accidentals, multivoice
1958 @cindex modern accidental style
1959 @cindex modern accidentals
1960 @cindex multivoice accidentals
1962 @funindex modern-voice
1964 This rule is used for multivoice accidentals to be read both by
1965 musicians playing one voice and musicians playing all voices.
1966 Accidentals are typeset for each voice, but they @emph{are}
1967 canceled across voices in the same @code{Staff}. Hence,
1968 the@tie{}@code{a} in the last measure is canceled because the
1969 previous cancellation was in a different voice, and
1970 the@tie{}@code{d} in the lower staff is canceled because of the
1971 accidental in a different voice in the previous measure:
1977 cis''8 fis, bes4 <a cis>8 f bis4 |
1991 \voiceTwo \relative {
1992 <fis a cis>8[ <fis a cis>
1995 \change Staff = down
2000 \change Staff = down
2001 <fis, a cis>4 gis <f a d>2 |
2008 \context Staff = "up" {
2009 \accidentalStyle modern-voice
2012 \context Staff = "down" {
2013 \accidentalStyle modern-voice
2020 @cindex accidental style, cautionary, modern voice
2021 @cindex accidental style, modern voice cautionary
2022 @cindex accidental style, voice, modern cautionary
2024 @funindex modern-voice-cautionary
2026 @item modern-voice-cautionary
2028 This rule is the same as @code{modern-voice}, but with the extra
2029 accidentals (the ones not typeset by @code{voice}) typeset as
2030 cautionaries. Even though all accidentals typeset by
2031 @code{default} @emph{are} typeset with this rule, some of them are
2032 typeset as cautionaries.
2038 cis''8 fis, bes4 <a cis>8 f bis4 |
2052 \voiceTwo \relative {
2053 <fis a cis>8[ <fis a cis>
2056 \change Staff = down
2061 \change Staff = down
2062 <fis, a cis>4 gis <f a d>2 |
2069 \context Staff = "up" {
2070 \accidentalStyle modern-voice-cautionary
2073 \context Staff = "down" {
2074 \accidentalStyle modern-voice-cautionary
2083 @cindex accidental style, piano
2084 @cindex accidentals, piano
2085 @cindex piano accidental style
2086 @cindex piano accidentals
2090 This rule reflects twentieth-century practice for piano notation.
2091 Its behavior is very similar to @code{modern} style, but here
2092 accidentals also get canceled across the staves in the same
2093 @code{GrandStaff} or @code{PianoStaff}, hence all the
2094 cancellations of the final notes.
2096 This accidental style applies to the current @code{GrandStaff} or
2097 @code{PianoStaff} by default.
2103 cis''8 fis, bes4 <a cis>8 f bis4 |
2117 \voiceTwo \relative {
2118 <fis a cis>8[ <fis a cis>
2121 \change Staff = down
2126 \change Staff = down
2127 <fis, a cis>4 gis <f a d>2 |
2134 \context Staff = "up" {
2135 \accidentalStyle piano
2138 \context Staff = "down" {
2145 @item piano-cautionary
2147 @cindex accidentals, piano cautionary
2148 @cindex cautionary accidentals, piano
2149 @cindex piano cautionary accidentals
2150 @cindex accidental style, piano cautionary
2151 @cindex cautionary accidental style, piano
2152 @cindex piano cautionary accidental style
2154 @funindex piano-cautionary
2156 This is the same as @code{piano} but with the extra accidentals
2157 typeset as cautionaries.
2163 cis''8 fis, bes4 <a cis>8 f bis4 |
2177 \voiceTwo \relative {
2178 <fis a cis>8[ <fis a cis>
2181 \change Staff = down
2186 \change Staff = down
2187 <fis, a cis>4 gis <f a d>2 |
2194 \context Staff = "up" {
2195 \accidentalStyle piano-cautionary
2198 \context Staff = "down" {
2208 @cindex neo-modern accidental style
2209 @cindex accidental style, neo-modern
2211 @funindex neo-modern
2213 This rule reproduces a common practice in contemporary music:
2214 accidentals are printed like with @code{modern}, but they are printed
2215 again if the same note appears later in the same measure -- except
2216 if the note is immediately repeated.
2222 cis''8 fis, bes4 <a cis>8 f bis4 |
2236 \voiceTwo \relative {
2237 <fis a cis>8[ <fis a cis>
2240 \change Staff = down
2245 \change Staff = down
2246 <fis, a cis>4 gis <f a d>2 |
2253 \context Staff = "up" {
2254 \accidentalStyle neo-modern
2257 \context Staff = "down" {
2258 \accidentalStyle neo-modern
2265 @item neo-modern-cautionary
2267 @cindex neo-modern-cautionary accidental style
2268 @cindex accidental style, neo-modern-cautionary
2270 @funindex neo-modern-cautionary
2272 This rule is similar to @code{neo-modern}, but the extra
2273 accidentals are printed as cautionary accidentals.
2279 cis''8 fis, bes4 <a cis>8 f bis4 |
2293 \voiceTwo \relative {
2294 <fis a cis>8[ <fis a cis>
2297 \change Staff = down
2302 \change Staff = down
2303 <fis, a cis>4 gis <f a d>2 |
2310 \context Staff = "up" {
2311 \accidentalStyle neo-modern-cautionary
2314 \context Staff = "down" {
2315 \accidentalStyle neo-modern-cautionary
2323 @item neo-modern-voice
2325 @cindex neo-modern-voice accidental style
2326 @cindex accidental style, neo-modern-voice
2328 @funindex neo-modern-voice
2330 This rule is used for multivoice accidentals to be read both by
2331 musicians playing one voice and musicians playing all voices.
2332 Accidentals are typeset for each voice as with @code{neo-modern},
2333 but they are canceled across voices in the same @code{Staff}.
2339 cis''8 fis, bes4 <a cis>8 f bis4 |
2353 \voiceTwo \relative {
2354 <fis a cis>8[ <fis a cis>
2357 \change Staff = down
2362 \change Staff = down
2363 <fis, a cis>4 gis <f a d>2 |
2370 \context Staff = "up" {
2371 \accidentalStyle neo-modern-voice
2374 \context Staff = "down" {
2375 \accidentalStyle neo-modern-voice
2382 @item neo-modern-voice-cautionary
2384 @cindex neo-modern-voice-cautionary accidental style
2385 @cindex accidental style, neo-modern-voice-cautionary
2387 @funindex neo-modern-voice-cautionary
2389 This rule is similar to @code{neo-modern-voice}, but the extra
2390 accidentals are printed as cautionary accidentals.
2396 cis''8 fis, bes4 <a cis>8 f bis4 |
2410 \voiceTwo \relative {
2411 <fis a cis>8[ <fis a cis>
2414 \change Staff = down
2419 \change Staff = down
2420 <fis, a cis>4 gis <f a d>2 |
2427 \context Staff = "up" {
2428 \accidentalStyle neo-modern-voice-cautionary
2431 \context Staff = "down" {
2432 \accidentalStyle neo-modern-voice-cautionary
2441 @cindex dodecaphonic accidental style
2442 @cindex dodecaphonic style, neo-modern
2444 @funindex dodecaphonic
2446 This rule reflects a practice introduced by composers at
2447 the beginning of the 20th century, in an attempt to
2448 abolish the hierarchy between natural and non-natural notes.
2449 With this style, @emph{every} note gets an accidental sign,
2450 including natural signs.
2456 cis''8 fis, bes4 <a cis>8 f bis4 |
2470 \voiceTwo \relative {
2471 <fis a cis>8[ <fis a cis>
2474 \change Staff = down
2479 \change Staff = down
2480 <fis, a cis>4 gis <f a d>2 |
2487 \context Staff = "up" {
2488 \accidentalStyle dodecaphonic
2491 \context Staff = "down" {
2492 \accidentalStyle dodecaphonic
2499 @item dodecaphonic-no-repeat
2501 @cindex dodecaphonic accidental style
2502 @cindex dodecaphonic style, neo-modern
2504 @funindex dodecaphonic-no-repeat
2506 Like with the dodecaphonic accidental style @emph{every} note
2507 gets an accidental sign by default, but accidentals are
2508 suppressed for pitches immediately repeated within the same staff.
2514 cis''8 fis, bes4 <a cis>8 f bis4 |
2528 \voiceTwo \relative {
2529 <fis a cis>8[ <fis a cis>
2532 \change Staff = down
2537 \change Staff = down
2538 <fis, a cis>4 gis <f a d>2 |
2545 \context Staff = "up" {
2546 \accidentalStyle dodecaphonic-no-repeat
2549 \context Staff = "down" {
2550 \accidentalStyle dodecaphonic-no-repeat
2558 @item dodecaphonic-first
2560 @cindex dodecaphonic accidental style
2561 @cindex dodecaphonic style, neo-modern
2563 @funindex dodecaphonic-first
2565 Similar to the dodecaphonic accidental style @emph{every} pitch
2566 gets an accidental sign, but only the first time it is encountered
2567 in a measure. Accidentals are only remembered for the actual octave
2568 but throughout voices.
2574 cis''8 fis, bes4 <a cis>8 f bis4 |
2588 \voiceTwo \relative {
2589 <fis a cis>8[ <fis a cis>
2592 \change Staff = down
2597 \change Staff = down
2598 <fis, a cis>4 gis <f a d>2 |
2605 \context Staff = "up" {
2606 \accidentalStyle dodecaphonic-first
2609 \context Staff = "down" {
2610 \accidentalStyle dodecaphonic-first
2620 @cindex teaching accidental style
2621 @cindex accidental style, teaching
2625 This rule is intended for students, and makes it easy to create
2626 scale sheets with automatically created cautionary accidentals.
2627 Accidentals are printed like with @code{modern}, but cautionary
2628 accidentals are added for all sharp or flat tones specified by the
2629 key signature, except if the note is immediately repeated.
2631 @lilypond[quote,staffsize=18]
2635 cis''8 fis, bes4 <a cis>8 f bis4 |
2649 \voiceTwo \relative {
2650 <fis a cis>8[ <fis a cis>
2653 \change Staff = down
2658 \change Staff = down
2659 <fis, a cis>4 gis <f a d>2 |
2666 \context Staff = "up" {
2668 \accidentalStyle teaching
2671 \context Staff = "down" {
2673 \accidentalStyle teaching
2684 @cindex accidental style, no reset
2685 @cindex no reset accidental style
2689 This is the same as @code{default} but with accidentals lasting
2690 @q{forever} and not only within the same measure:
2696 cis''8 fis, bes4 <a cis>8 f bis4 |
2710 \voiceTwo \relative {
2711 <fis a cis>8[ <fis a cis>
2714 \change Staff = down
2719 \change Staff = down
2720 <fis, a cis>4 gis <f a d>2 |
2727 \context Staff = "up" {
2728 \accidentalStyle no-reset
2731 \context Staff = "down" {
2732 \accidentalStyle no-reset
2741 @cindex forget accidental style
2742 @cindex accidental style, forget
2746 This is the opposite of @code{no-reset}: Accidentals are not
2747 remembered at all -- and hence all accidentals are typeset
2748 relative to the key signature, regardless of what came before in
2755 cis''8 fis, bes4 <a cis>8 f bis4 |
2769 \voiceTwo \relative {
2770 <fis a cis>8[ <fis a cis>
2773 \change Staff = down
2778 \change Staff = down
2779 <fis, a cis>4 gis <f a d>2 |
2786 \context Staff = "up" {
2787 \accidentalStyle forget
2790 \context Staff = "down" {
2791 \accidentalStyle forget
2803 Internals Reference:
2804 @rinternals{Accidental},
2805 @rinternals{Accidental_engraver},
2806 @rinternals{GrandStaff},
2807 @rinternals{PianoStaff},
2809 @rinternals{AccidentalSuggestion},
2810 @rinternals{AccidentalPlacement},
2811 @rinternals{accidental-suggestion-interface}.
2813 @cindex accidentals and simultaneous notes
2814 @cindex simultaneous notes and accidentals
2815 @cindex accidentals in chords
2816 @cindex chords, accidentals in
2819 Simultaneous notes are not considered in the automatic
2820 determination of accidentals; only previous notes and the key
2821 signature are considered. Forcing accidentals with@tie{}@code{!}
2822 or@tie{}@code{?} may be required when the same note name occurs
2823 simultaneously with different alterations, as in @samp{<f! fis!>}.
2825 Cautionary cancellation of accidentals is done by looking at previous measure.
2826 However, in the @code{\alternative} block following a @code{\repeat volta N}
2827 section, one would expect the cancellation being calculated using the previous
2828 @emph{played} measure, not previous @emph{printed} measure.
2829 In the following example, the natural @code{c} in the second alternative does
2830 not need a natural sign:
2834 \accidentalStyle modern
2846 The following work-around can be used: define a function that locally changes
2847 the accidental style to @code{forget}:
2849 @lilypond[verbatim,quote]
2850 forget = #(define-music-function (parser location music) (ly:music?) #{
2851 \accidentalStyle forget
2853 \accidentalStyle modern
2856 \accidentalStyle modern
2870 @unnumberedsubsubsec Ambitus
2873 @cindex range of pitches
2876 The term @notation{ambitus} (pl. ambitus) denotes a range of
2877 pitches for a given voice in a part of music. It may also denote
2878 the pitch range that a musical instrument is capable of playing.
2879 Ambitus are printed on vocal parts so that performers can easily
2880 determine if it matches their capabilities.
2882 Ambitus are denoted at the beginning of a piece near the initial
2883 clef. The range is graphically specified by two note heads that
2884 represent the lowest and highest pitches. Accidentals are only
2885 printed if they are not part of the key signature.
2887 @lilypond[verbatim,quote]
2891 \consists "Ambitus_engraver"
2904 @lilypondfile[verbatim,quote,texidoc,doctitle]
2905 {adding-ambitus-per-voice.ly}
2907 @lilypondfile[verbatim,quote,texidoc,doctitle]
2908 {ambitus-with-multiple-voices.ly}
2910 @lilypondfile[verbatim,quote,texidoc,doctitle]
2911 {changing-the-ambitus-gap.ly}
2920 Internals Reference:
2921 @rinternals{Ambitus_engraver},
2924 @rinternals{Ambitus},
2925 @rinternals{AmbitusAccidental},
2926 @rinternals{AmbitusLine},
2927 @rinternals{AmbitusNoteHead},
2928 @rinternals{ambitus-interface}.
2931 There is no collision handling in the case of multiple per-voice
2936 @subsection Note heads
2938 This section suggests ways of altering note heads.
2941 * Special note heads::
2942 * Easy notation note heads::
2943 * Shape note heads::
2947 @node Special note heads
2948 @unnumberedsubsubsec Special note heads
2950 @cindex note heads, special
2951 @cindex note heads, cross
2952 @cindex note heads, diamond
2953 @cindex note heads, parlato
2954 @cindex note heads, harmonic
2955 @cindex note heads, guitar
2956 @cindex special note heads
2957 @cindex cross note heads
2958 @cindex diamond note heads
2959 @cindex parlato note heads
2960 @cindex harmonic note heads
2961 @cindex guitar note heads
2962 @cindex note head styles
2963 @cindex styles, note heads
2967 The appearance of note heads may be altered:
2969 @lilypond[verbatim,quote,relative=2]
2971 \override NoteHead.style = #'cross
2973 \revert NoteHead.style
2975 \override NoteHead.style = #'harmonic
2977 \revert NoteHead.style
2981 To see all note head styles, see @ref{Note head styles}.
2983 The @code{cross} style is used to represent a variety of musical
2984 intentions. The following generic predefined commands modify the
2985 note head in both staff and tablature contexts and can be used to
2986 represent any musical meaning:
2988 @lilypond[verbatim,quote,relative=2]
2996 The music function form of this predefined command may be used
2997 inside and outside chords to generate crossed note heads in both
2998 staff and tablature contexts:
3000 @lilypond[verbatim,quote,relative=2]
3003 c b < g \xNote c f > b
3006 As synonyms for @code{\xNote}, @code{\xNotesOn} and @code{\xNotesOff},
3007 @code{\deadNote}, @code{\deadNotesOn} and @code{\deadNotesOff} can
3008 be used. The term @notation{dead note} is commonly used by guitarists.
3010 There is also a similar shorthand for diamond shapes:
3012 @lilypond[verbatim,quote,relative=2]
3013 <c f\harmonic>2 <d a'\harmonic>4 <c g'\harmonic> f\harmonic
3028 @ref{Note head styles},
3029 @ref{Chorded notes},
3030 @ref{Indicating harmonics and dampened notes}.
3032 Internals Reference:
3033 @rinternals{note-event},
3034 @rinternals{Note_heads_engraver},
3035 @rinternals{Ledger_line_engraver},
3036 @rinternals{NoteHead},
3037 @rinternals{LedgerLineSpanner},
3038 @rinternals{note-head-interface},
3039 @rinternals{ledger-line-spanner-interface}.
3042 @node Easy notation note heads
3043 @unnumberedsubsubsec Easy notation note heads
3045 @cindex note heads, practice
3046 @cindex practice note heads
3047 @cindex note heads, easy notation
3048 @cindex easy notation
3049 @cindex beginners' music
3050 @cindex music, beginners'
3051 @cindex easy play note heads
3052 @cindex note heads, easy play
3054 @funindex \easyHeadsOn
3055 @funindex easyHeadsOn
3056 @funindex \easyHeadsOff
3057 @funindex easyHeadsOff
3059 The @q{easy play} note head includes a note name inside the head.
3060 It is used in music for beginners. To make the letters readable,
3061 it should be printed in a large font size. To print with a larger
3062 font, see @ref{Setting the staff size}.
3064 @lilypond[verbatim,quote]
3065 #(set-global-staff-size 26)
3077 @code{\easyHeadsOn},
3078 @code{\easyHeadsOff}.
3084 @lilypondfile[verbatim,quote,texidoc,doctitle]
3085 {numbers-as-easy-note-heads.ly}
3089 @ref{Setting the staff size}.
3094 Internals Reference:
3095 @rinternals{note-event},
3096 @rinternals{Note_heads_engraver},
3097 @rinternals{NoteHead},
3098 @rinternals{note-head-interface}.
3101 @node Shape note heads
3102 @unnumberedsubsubsec Shape note heads
3104 @cindex note heads, shape
3105 @cindex note heads, Aiken
3106 @cindex note heads, sacred harp
3108 @cindex Aiken shape note heads
3109 @cindex sacred harp note heads
3110 @cindex note heads, Southern Harmony
3111 @cindex Southern Harmony note heads
3112 @cindex Funk shape note heads
3113 @cindex note heads, Funk
3114 @cindex note heads, Harmonica Sacra
3115 @cindex Harmonica Sacra note heads
3116 @cindex Christian Harmony note heads
3117 @cindex note heads, Christian Harmony
3118 @cindex Walker shape note heads
3119 @cindex note heads, Walker
3121 @funindex \aikenHeads
3122 @funindex aikenHeads
3123 @funindex \sacredHarpHeads
3124 @funindex sacredHarpHeads
3125 @funindex \southernHarmonyHeads
3126 @funindex southernHarmonyHeads
3127 @funindex \funkHeads
3129 @funindex \walkerHeads
3130 @funindex walkerHeads
3132 In shape note head notation, the shape of the note head
3133 corresponds to the harmonic function of a note in the scale. This
3134 notation was popular in nineteenth-century American song books.
3135 Shape note heads can be produced in Sacred Harp, Southern Harmony,
3136 Funk (Harmonica Sacra), Walker, and Aiken (Christian Harmony) styles:
3138 @lilypond[verbatim,quote,relative=2]
3140 c, d e f g2 a b1 c \break
3142 c,4 d e f g2 a b1 c \break
3143 \southernHarmonyHeads
3144 c,4 d e f g2 a b1 c \break
3146 c,4 d e f g2 a b1 c \break
3148 c,4 d e f g2 a b1 c \break
3153 @funindex \aikenHeadsMinor
3154 @funindex aikenHeadsMinor
3155 @funindex \sacredHarpHeadsMinor
3156 @funindex sacredHarpHeadsMinor
3157 @funindex \southernHarmonyHeadsMinor
3158 @funindex southernHarmonyHeadsMinor
3159 @funindex \funkHeadsMinor
3160 @funindex funkHeadsMinor
3161 @funindex \walkerHeadsMinor
3162 @funindex walkerHeadsMinor
3164 Shapes are typeset according to the step in the scale, where the base
3165 of the scale is determined by the @code{\key} command. When writing
3166 in a minor key, the scale step can be determined from the relative
3169 @lilypond[verbatim,quote,relative=2]
3172 a b c d e2 f g1 a \break
3174 a,4 b c d e2 f g1 a \break
3175 \sacredHarpHeadsMinor
3177 \southernHarmonyHeadsMinor
3189 @code{\aikenHeadsMinor},
3191 @code{\funkHeadsMinor},
3192 @code{\sacredHarpHeads},
3193 @code{\sacredHarpHeadsMinor},
3194 @code{\southernHarmonyHeads},
3195 @code{\southernHarmonyHeadsMinor},
3196 @code{\walkerHeads},
3197 @code{\walkerHeadsMinor}.
3203 @lilypondfile[verbatim,quote,texidoc,doctitle]
3204 {applying-note-head-styles-depending-on-the-step-of-the-scale.ly}
3206 To see all note head styles, see @ref{Note head styles}.
3213 @ref{Note head styles}.
3215 Internals Reference:
3216 @rinternals{note-event},
3217 @rinternals{Note_heads_engraver},
3218 @rinternals{NoteHead},
3219 @rinternals{note-head-interface}.
3223 @unnumberedsubsubsec Improvisation
3225 @cindex improvisation
3226 @cindex slashed note heads
3227 @cindex note heads, improvisation
3228 @cindex note heads, slashed
3230 @funindex \improvisationOn
3231 @funindex improvisationOn
3232 @funindex \improvisationOff
3233 @funindex improvisationOff
3235 Improvisation is sometimes denoted with slashed note heads, where
3236 the performer may choose any pitch but should play the specified
3237 rhythm. Such note heads can be created:
3239 @lilypond[verbatim,quote,relative=2]
3241 \consists "Pitch_squash_engraver"
3243 e8 e g a a16( bes) a8 g
3254 @code{\improvisationOn},
3255 @code{\improvisationOff}.
3262 Internals Reference:
3263 @rinternals{Pitch_squash_engraver},
3265 @rinternals{RhythmicStaff}.