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. See TRANSLATION for details.
12 @section Staff notation
14 @lilypondfile[quote]{staff-headword.ly}
16 This section explains how to influence the staff appearance, print
17 scores with more than one staff, and how to apply specific
18 performance marks to single staves.
22 * Modifying single staves::
27 @node Displaying staves
28 @subsection Displaying staves
30 This section shows the different possibilities to create and group
31 staves into groups, which can be marked in the beginning of each
32 line with either a bracket or a brace.
35 * Instantiating new staves::
37 * Deeper nested staff groups::
40 @node Instantiating new staves
41 @unnumberedsubsubsec Instantiating new staves
44 @cindex staff initiation
45 @cindex staff instantiation
49 @cindex percussion staff
50 @cindex Gregorian transcription staff
51 @cindex rhythmic staff
55 Staves (sg. staff) are created with the @code{\new} or
56 @code{\context} commands. For an explanation on these commands,
57 see @ref{Creating contexts}.
59 There are different predefined staff contexts available in
64 The default is @code{Staff}:
66 @lilypond[verbatim,quote,relative=2]
67 \new Staff { c4 d e f }
71 @code{DrumStaff} creates a five line staff set up for a typical
72 drum set. It uses different names for each instrument. The
73 instrument names have to be set using the @code{drummode}. See
74 @ref{Percussion staves}.
76 @lilypond[verbatim,quote]
78 \drummode { cymc hh ss tomh }
82 @c FIXME: remove when mentioned in NR 2.8
84 @code{GregorianTranscriptionStaff} sets up a staff to notate
85 modern Gregorian chant. It does not show bar lines.
87 @lilypond[verbatim,quote,relative=2]
88 \new GregorianTranscriptionStaff { c4 d e f }
92 @code{RhythmicStaff} can be used to show the rhythm of some music.
93 The notes are printed on one line regardless of their pitch, but
94 the duration is preserved. See @ref{Showing melody rhythms}.
96 @lilypond[verbatim,quote,relative=2]
97 \new RhythmicStaff { c4 d e f }
101 @code{TabStaff} creates by default a tablature with six strings in
102 standard guitar tuning. See @ref{Default tablatures}.
104 @lilypond[verbatim,quote,relative=2]
105 \new TabStaff { c4 d e f }
111 Besides these staves there are two staff contexts specific for the
112 notation of ancient music: @code{MensuralStaff} and
113 @code{VaticanaStaff}. They are described in @ref{Pre-defined
116 Once a staff is instantiated it can be started or stopped at every
117 point in the score. This is done with the commands
118 @code{\startStaff} and @code{\stopStaff}. How to use it is
119 explained in @ref{Staff symbol}.
129 @ref{Creating contexts},
130 @ref{Percussion staves},
131 @ref{Default tablatures},
132 @ref{Gregorian chant contexts},
133 @ref{Mensural contexts},
135 @ref{Pre-defined contexts},
136 @ref{Showing melody rhythms}.
139 @rlsr{Staff notation}.
143 @rinternals{DrumStaff},
144 @rinternals{GregorianTranscriptionStaff},
145 @rinternals{RhythmicStaff},
146 @rinternals{TabStaff},
147 @rinternals{MensuralStaff},
148 @rinternals{VaticanaStaff},
149 @rinternals{StaffSymbol}.
152 @node Grouping staves
153 @unnumberedsubsubsec Grouping staves
155 @cindex start of system
156 @cindex staff, multiple
157 @cindex staves, multiple
158 @cindex system start delimiters
159 @cindex bracket, vertical
160 @cindex brace, vertical
168 LilyPond provides different types of contexts to group single
169 staves together. These contexts influence in the first place the
170 appearance of the system start delimiter, but they have also
171 influence on the behavior of the bar lines.
175 If no context is specified, the default properties for the score
176 will be used: the group is started with a vertical line, and the
177 bar lines are not connected. The name of the beginning bar line
178 grob is @code{SystemStartBar}.
180 @lilypond[verbatim,quote,relative=2]
188 In a @code{StaffGroup}, the bar lines will be drawn through all
189 the staves, and the group is started with a bracket.
191 @lilypond[verbatim,quote,relative=2]
199 In a @code{ChoirStaff}, the group is started with a bracket, but
200 bar lines are not connected.
202 @lilypond[verbatim,quote,relative=2]
210 In a @code{GrandStaff}, the group is started with a brace at the
211 left, and bar lines are connected between the staves.
213 @lilypond[verbatim,quote,relative=2]
221 The @code{PianoStaff} behaves almost as the @code{GrandStaff} but
222 is optimized for setting piano music. In particular it supports
223 the printing of an instrument name directly, see @ref{Instrument
226 @lilypond[verbatim,quote,relative=2]
235 Each staff group context sets the property
236 @code{systemStartDelimiter} to one of the values
237 @code{SystemStartBar}, @code{SystemStartBrace}, and
238 @code{SystemStartBracket}. A fourth delimiter,
239 @code{systemStartSquare}, is also available, but must be
240 instantiated manually. The usage of this last delimiter is shown
241 further down in the snippet section.
243 According to classic engraver rules an orchestral score consists
244 of staves connected only with a single line at the beginning of
245 the system. In LilyPond this is produced grouping the
246 @code{Staff} contexts with @code{<< ... >>}.
248 Each instrument family is grouped inside of a @code{StaffGroup}
249 with a starting bracket. A group of same instruments or an
250 instrument using more than one staff is grouped with braces in a
253 As the context names tell, @code{PianoStaff} is used for notating
254 piano music and @code{ChoirStaff} for all kind of vocal ensemble
260 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
261 {use-square-bracket-at-the-start-of-a-staff-group.ly}
263 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
264 {display-bracket-with-only-one-staff-in-a-system.ly}
266 @cindex mensurstriche layout
267 @cindex renaissance music
268 @cindex transcription of mensural music
269 @cindex mensural music, transcription of
271 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
272 {mensurstriche-layout-bar-lines-between-the-staves.ly}
273 @c FIXME: move to NR 2.8.x when sectioning is ready
284 @ref{Instrument names}.
287 @rlsr{Staff notation}.
291 @rinternals{ChoirStaff},
292 @rinternals{GrandStaff},
293 @rinternals{PianoStaff},
294 @rinternals{StaffGroup},
295 @rinternals{systemStartDelimiter},
296 @rinternals{SystemStartBar},
297 @rinternals{SystemStartBrace},
298 @rinternals{SystemStartBracket},
299 @rinternals{systemStartSquare}.
302 @node Deeper nested staff groups
303 @unnumberedsubsubsec Deeper nested staff groups
305 There are also two inner staff contexts named
306 @code{InnerStaffGroup} and @code{InnerChoirStaffGroup} besides the
307 grouping contexts mentioned in @ref{Grouping staves}. They behave
308 in the same way as their simple counterparts, except that they are
309 contained in another staff grouping context, thus producing one
310 more bracket on top of the existing one. Note that
311 @code{GrandStaff} and @code{PianoStaff} do not have any inner
312 grouping contexts. They can both be inside any other staff
313 context, including inner staff groups, though.
315 Here is an example of an orchestral score using groupings and
316 nesting of these groupings. Note that the instrument names are
317 omitted from the source code, for instructions how to set them see
318 @ref{Instrument names}.
320 @cindex staff, nested
321 @cindex staves, nested
322 @cindex nesting of staves
323 @cindex system start delimiters, nested
324 @cindex nested staff brackets
325 @cindex brackets, nesting of
326 @cindex braces, nesting of
327 @cindex inner staff group
328 @cindex inner choir staff group
333 \new StaffGroup %woodwinds
335 \new Staff @{ c1 d @} %flute
336 \new InnerStaffGroup <<
337 \new Staff @{ c1 d @} %sax
338 \new Staff @{ c1 d @} %oboe
339 \new Staff @{ c1 d @} %English horn
341 \new Staff @{ \clef bass c,1 d @} %bassoon
343 \new StaffGroup %the brass group
345 \new Staff @{ c'1 d @} %trumpet
346 \new Staff @{ \clef bass c,1 d @} %trombone
347 \new GrandStaff %the horns need a GrandStaff (same instrument)
349 \new Staff @{ c'1 d @}
350 \new Staff @{ \clef bass c,1 d @}
353 \new ChoirStaff %for setting vocal music
355 \new Staff @{ c'1 d @}
356 \new InnerChoirStaff <<
357 \new Staff @{ c1 d @}
358 \new Staff @{ c1 d @}
360 \new Staff @{ c1 d @}
362 \new PianoStaff %for the piano
364 \new Staff @{ c1 d @}
365 \new Staff @{ \clef bass c,1 d @}
370 @c no verbatim so instrument names are only in the music
374 \new StaffGroup %woodwinds
376 \new Staff { \set Staff.instrumentName = "fl" c1 d } %flute
377 \new InnerStaffGroup <<
378 \new Staff { \set Staff.instrumentName = "sax" c1 d } %sax 1
379 \new Staff { \set Staff.instrumentName = "ob" c1 d } %sax 2
380 \new Staff { \set Staff.instrumentName = "ca" c1 d }
382 \new Staff { \set Staff.instrumentName = "bs" \clef bass c,1 d } %bassoon
384 \new StaffGroup %the brass group
386 \new Staff { \set Staff.instrumentName = "tr" c'1 d } %trumpet
387 \new Staff { \set Staff.instrumentName = "tb" \clef bass c,1 d } %trombone
388 \new GrandStaff %the horns need a GrandStaff (same instrument)
390 \new Staff { \set Staff.instrumentName = "cor1" c'1 d }
391 \new Staff { \set Staff.instrumentName = "cor2" \clef bass c,1 d }
394 \new ChoirStaff %for setting vocal music
396 \new Staff { \set Staff.instrumentName = "S" c'1 d }
397 \new InnerChoirStaff <<
398 \new Staff { \set Staff.instrumentName = "A1" c1 d }
399 \new Staff { \set Staff.instrumentName = "A2" c1 d }
401 \new Staff { \set Staff.instrumentName = "T" c1 d }
403 \new PianoStaff %for the piano
406 \new Staff { \clef bass c,1 d }
414 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
421 @rlsr{Staff notation}.
424 @ref{Grouping staves},
425 @ref{Instrument names}.
428 @rinternals{InnerChoirStaffGroup},
429 @rinternals{InnerStaffGroup},
430 @rinternals{SystemStartBar},
431 @rinternals{SystemStartBrace},
432 @rinternals{SystemStartBracket},
433 @rinternals{systemStartDelimiterHierarchy}.
436 @node Modifying single staves
437 @subsection Modifying single staves
439 This section explains how to change specific attributes of one
440 staff like the staff lines, starting and stopping of staves,
441 sizing of staves, and setting ossia sections.
450 @unnumberedsubsubsec Staff symbol
452 @cindex adjusting staff symbol
453 @cindex drawing staff symbol
454 @cindex staff symbol, setting of
455 @cindex stop staff lines
456 @cindex start staff lines
457 @cindex staff lines, amount of
458 @cindex staff lines, number of
459 @cindex staff line, thickness of
460 @cindex amount of staff lines
461 @cindex thickness of staff lines
462 @cindex ledger lines, setting
463 @cindex setting of ledger lines
464 @cindex spacing of ledger lines
465 @cindex number of staff lines
467 The layout object which draws the lines of a staff is called
468 @code{staff symbol}. The staff symbol may be tuned in number,
469 thickness and distance of lines, using properties. It may also be
470 started and stopped at every point in the score.
474 Changing the number of staff lines is done by overriding
475 @code{line-count}. You may need to adjust the clef position and
476 the position of the middle C to fit to the new staff. For an
477 explanation, see the snippet section in @ref{Displaying pitches}.
479 @lilypond[verbatim,quote,relative=2]
481 \override Staff.StaffSymbol #'line-count = #3
487 The placement and amount of the staff lines can also set totally
488 manually by defining their positions explicitly. The middle of
489 the staff has the value of 0, each half staff space up and down
490 adds an integer. The default values are 4 2 0 -2 -4. Bar lines
491 are drawn according to the calculated width of the system, but
492 they are always centered. As the example shows, the positions of
493 the notes are not influenced by the position of the staff lines.
495 @lilypond[verbatim,quote,relative=1]
497 \override StaffSymbol #'line-positions = #'(7 3 0 -4 -6 -7)
503 The staff line thickness can be set by overriding the
504 @code{thickness} property. Note that it gets applied also to
505 ledger lines and stems, since they depend on the staff line
506 thickness. The argument of @code{thickness} is a factor of
507 @code{line-thickness} which defaults to the normal staff line
510 @lilypond[verbatim,quote,relative=1]
512 \override StaffSymbol #'thickness = #3
518 The thickness of the ledger lines can also be set independent of
519 the settings for staff lines. The setting is calculated from a
520 pair of values which will be added for the final thickness. The
521 first value is the staff line thickness multiplied by a factor,
522 the second is the staff space multiplied by a factor. In the
523 example the ledger lines get their thickness from one staff line
524 thickness plus 1/5 staff space, so they are heavier than a normal
527 @lilypond[verbatim,quote,relative=1]
529 \override StaffSymbol #'ledger-line-thickness = #'(1 . 0.2)
535 The distance of the stafflines can be changed with the
536 @code{staff-space} property. Its argument is the amount of staff
537 spaces that should be inserted between the lines. The default
538 value is 1. Setting the distance has influence on the staff lines
539 as well as on ledger lines.
541 @lilypond[verbatim,quote,relative=1]
543 \override StaffSymbol #'staff-space = #1.5
549 The length of the staff line can also be adjusted manually. The
550 unit is one staff space. Spacing of the objects inside the staff
551 does not get influenced by this setting.
553 @lilypond[verbatim,quote,relative=1]
555 \override StaffSymbol #'width = #23
562 These properties can only be set before instantiating the staff
563 symbol. But it is possible to start and stop staves in the middle
564 of a score, so each new setting will be applied to the newly
567 @lilypond[verbatim,quote,relative=2]
569 %Set here the overrides for the staff
570 \override Staff.StaffSymbol #'line-count = 2
571 \stopStaff \startStaff
573 %Revert to the default
574 \revert Staff.StaffSymbol #'line-count
575 \stopStaff \startStaff
582 @funindex \startStaff
590 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
591 {making-some-staff-lines-thicker-than-the-others.ly}
601 @ref{Displaying pitches}.
604 @rinternals{StaffSymbol}.
608 When setting staff lines manually, bar lines are always drawn
609 centered on the position 0, so the maximum distance of the bar
610 lines in either direction must be equal.
614 @unnumberedsubsubsec Ossia staves
616 @cindex staff, Frenched
618 @cindex Frenched staves
619 @cindex staff, resizing of
620 @cindex resizing of staves
622 Tweaking the staff object allows to resize the staff:
624 @lilypond[verbatim,quote]
627 \override StaffSymbol #'staff-space = #(magstep -3)
628 \override StaffSymbol #'thickness = #(magstep -3)
637 This involves shrinking the staff spaces, the staff lines and the
638 font size by the factor 3. You find a more precise explanation in
639 @ref{Setting the staff size}.
641 The @emph{ossia} section in the next example are just put parallel
642 to the main staff with @code{<<} and @code{>>} brackets. The
643 @emph{ossia} staff is stopped and started explicitely and white
644 space is inserted with the @code{\skip} command.
646 @lilypond[verbatim,quote]
650 %No time signature in the ossia staff
651 \remove "Time_signature_engraver"
653 \override StaffSymbol #'staff-space = #(magstep -3)
654 \override StaffSymbol #'thickness = #(magstep -3)
663 bes8[^"ossia" g bes g]
671 \new Staff \relative c'' {
681 @c @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
682 @c {making-some-staff-lines-thicker-than-the-others.ly}
691 @rglos{Frenched staff}.
694 @ref{Setting the staff size}.
697 @rlsr{Staff notation}.
700 @rinternals{StaffSymbol}.
704 @unnumberedsubsubsec Hiding staves
706 @cindex Frenched scores
707 @cindex staff, hiding
709 @cindex hiding of staves
711 @cindex Frenched staves
713 In orchestral scores, staff lines that only have rests are usually
714 removed; this saves some space. This style is called @q{French
715 Score}. For the @code{Lyrics}, @code{ChordNames}, and
716 @code{FiguredBass} contexts, this is switched on by default. When
717 the lines of these contexts turn out empty after the line-breaking
718 process, they are removed.
720 For normal staves this behaviour is called with the
721 @code{\RemoveEmptyStaffContext} command. It is set in the
722 @code{\layout} block. As a result staves containing nothing or
723 whole mesure rests are removed after a line break.
725 @lilypond[verbatim,quote]
728 \RemoveEmptyStaffContext
733 \new Staff { e4 f g a \break c1 }
734 \new Staff { c4 d e f \break R1 }
739 To remove other types of contexts, use
740 @code{\AncientRemoveEmptyStaffContext} or
741 @code{\RemoveEmptyRhythmicStaffContext}.
745 Another application of the @code{\RemoveEmptyStaffContext} is to
746 make ossia sections, i.e., alternative melodies on a separate
747 piece of staff, with help of a Frenched staff. See
750 You can make the staff lines invisible by removing the
751 @code{Staff_symbol_engraver} from the @code{Staff} context.
753 @lilypond[verbatim,quote]
755 \new Staff \relative c'' { c8 c c16 c c c }
759 \remove Staff_symbol_engraver
768 The first empty staff can also be removed from the score with a
769 setting in the @code{VerticalAxisGroup} property. This can be
770 done globally inside the @code{\layout} block, or locally inside
771 the specific staff that should be removed. In the latter case, you
772 have to specify the context (@code{Staff} applies only to the
773 current staff) in front of the property.
775 The lower staff of the second staff group is not removed, because
776 the setting applies only to the specific staff inside of which it
779 @lilypond[verbatim,quote]
782 \RemoveEmptyStaffContext
783 %To use the setting globally, uncomment the following line:
784 %\override VerticalAxisGroup #'remove-first = ##t
792 %To use the setting globally, comment this line, uncomment the line above
793 \override Staff.VerticalAxisGroup #'remove-first = ##t
798 \new Staff { e4 f g a \break c1 }
799 \new Staff { R \break R1 }
803 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
804 {removing-the-first-empty-line.ly}
809 @funindex \RemoveEmptyStaffContext
810 @code{\RemoveEmptyStaffContext},
811 @funindex \AncientRemoveEmptyStaffContext
812 @code{\AncientRemoveEmptyStaffContext},
813 @funindex \RemoveEmptyRhythmicStaffContext
814 @code{\RemoveEmptyRhythmicStaffContext}.
824 @rlsr{Staff notation}.
827 @rinternals{ChordNames},
828 @rinternals{FiguredBass},
831 @rinternals{VerticalAxisGroup}.
835 @subsection Writing parts
840 * Quoting other voices::
841 * Formatting cue notes::
845 @node Metronome marks
846 @unnumberedsubsubsec Metronome marks
849 @cindex beats per minute
850 @cindex metronome marking
852 Metronome settings can be entered as follows
855 \tempo @var{duration} = @var{per-minute}
858 In the MIDI output, they are interpreted as a tempo change. In
859 the layout output, a metronome marking is printed
863 @lilypond[verbatim,quote,relative=2]
871 To change the tempo in the MIDI output without printing anything,
872 make the metronome marking invisible @example \once \override
873 Score.MetronomeMark #'transparent = ##t @end example
875 To print other metronome markings, use these markup commands
876 @lilypond[verbatim,quote,relative=1]
879 \smaller \general-align #Y #DOWN \note #"16." #1
881 \smaller \general-align #Y #DOWN \note #"8" #1
886 For more details, see @ref{Formatting text}.
893 @rglos{metronomic indication},
894 @rglos{tempo indication},
895 @rglos{metronome mark}.
898 @ref{Formatting text}.
901 @rlsr{Staff notation}.
904 @rinternals{MetronomeMark},
910 Collisions are not checked. If you have notes above the top line
911 of the staff (or notes with articulations, slurs, text, etc), then
912 the metronome marking may be printed on top of musical symbols.
913 If this occurs, increase the padding of the metronome mark to
914 place it further away from the staff.
917 \override Score.MetronomeMark #'padding = #2.5
920 @c perhaps also an example of how to move it horizontally?
923 @node Instrument names
924 @unnumberedsubsubsec Instrument names
926 @cindex instrument names
927 @cindex instrument names, short
929 In an orchestral score, instrument names are printed at the left
932 This can be achieved by setting @code{Staff}.@code{instrumentName}
933 and @code{Staff}.@code{shortInstrumentName}, or
934 @code{PianoStaff}.@code{instrumentName} and
935 @code{PianoStaff}.@code{shortInstrumentName}. This will print
936 text before the start of the staff. For the first staff,
937 @code{instrumentName} is used. If set, @code{shortInstrumentName}
938 is used for the following staves.
940 @lilypond[verbatim,quote,relative=1]
941 \set Staff.instrumentName = "Ploink "
942 \set Staff.shortInstrumentName = "Plk "
948 You can also use markup texts to construct more complicated
949 instrument names, for example
951 @lilypond[verbatim,quote,relative=2]
952 \set Staff.instrumentName = \markup {
953 \column { "Clarinetti"
954 \line { "in B" \smaller \flat } } }
958 @cindex instrument names, centering
960 As instrument names are centered by default, multi line names are
961 better entered using @code{\center-align}:
963 @lilypond[verbatim,quote,relative=2]
966 \set Staff.instrumentName = \markup \center-align {
968 \line { "in B" \smaller \flat }
973 \set Staff.instrumentName = "Vibraphone"
979 For longer instrument names, it may be useful to increase the
980 @code{indent} setting in the @code{\layout} block.
982 Short instrument names, printed before the systems following the
983 first one, are also centered by default, in a space which width is
984 given by the @code{short-indent} variable of the @code{\layout}
987 To add instrument names to other contexts (such as
988 @code{GrandStaff}, @code{ChoirStaff}, or @code{StaffGroup}), the
989 engraver must be added to that context.
993 \context @{\GrandStaff \consists "Instrument_name_engraver"@}
998 More information about adding and removing engravers can be found
999 in @ref{Modifying context plug-ins}.
1001 @cindex instrument names, changing
1003 Instrument names may be changed in the middle of a piece,
1005 @lilypond[verbatim,quote,relative=1]
1006 \set Staff.instrumentName = "First"
1007 \set Staff.shortInstrumentName = "one"
1010 \set Staff.instrumentName = "Second"
1011 \set Staff.shortInstrumentName = "two"
1020 @ref{Modifying context plug-ins}.
1023 @rlsr{Staff notation}.
1025 Internals Reference:
1026 @rinternals{InstrumentName},
1027 @rinternals{PianoStaff},
1031 @node Quoting other voices
1032 @unnumberedsubsubsec Quoting other voices
1035 @cindex quoting other voices
1039 With quotations, fragments of other parts can be inserted into a
1040 part directly. Before a part can be quoted, it must be marked
1041 especially as quotable. This is done with the @code{\addQuote}
1045 \addQuote @var{name} @var{music}
1049 Here, @var{name} is an identifying string. The @var{music} is any
1050 kind of music. Here is an example of @code{\addQuote}
1053 \addQuote clarinet \relative c' @{
1058 This command must be entered at toplevel, i.e., outside any music
1059 blocks. Typically, one would use an already defined music event
1063 clarinet = \relative c' @{
1066 \addQuote clarinet @{ \clarinet @}
1069 After calling @code{\addQuote}, the quotation may then be done
1070 with @code{\quoteDuring} or @code{\cueDuring},
1073 \quoteDuring #@var{name} @var{music}
1076 During a part, a piece of music can be quoted with the
1077 @code{\quoteDuring} command.
1080 \quoteDuring #"clarinet" @{ s2. @}
1083 This would cite three quarter notes (the duration of @code{s2.})
1084 of the previously added @code{clarinet} voice.
1086 More precisely, it takes the current time-step of the part being
1087 printed, and extracts the notes at the corresponding point of the
1088 @code{\addQuote}d voice. Therefore, the argument to
1089 @code{\addQuote} should be the entire part of the voice to be
1090 quoted, including any rests at the beginning.
1092 It is possible to use another music expression instead of
1093 @code{s}, thus creating a polyphonic section, but this may not
1094 always give the desired result.
1096 Quotations take into account the transposition of both source and
1097 target instruments, if they are specified using the
1098 @code{\transposition} command.
1100 @lilypond[verbatim,quote,relative=1]
1108 e8 f8 \quoteDuring #"clarinet" { s2 }
1112 The type of events that are present in the quoted music can be
1113 trimmed with the @code{quotedEventTypes} property. The default
1114 value is @code{(note-event rest-event)}, which means that only
1115 notes and rests of the quoted voice end up in the
1116 @code{\quoteDuring}. Setting
1119 \set Staff.quotedEventTypes =
1120 #'(note-event articulation-event dynamic-event)
1124 will quote notes (but no rests), together with scripts and
1131 @ref{Instrument transpositions}.
1134 @rlsr{Staff notation}.
1136 Internals Reference:
1137 @rinternals{QuoteMusic},
1143 Only the contents of the first @code{Voice} occurring in an
1144 @code{\addQuote} command will be considered for quotation, so
1145 @var{music} can not contain @code{\new} and @code{\context Voice}
1146 statements that would switch to a different Voice.
1148 Quoting grace notes is broken and can even cause LilyPond to
1151 Quoting nested triplets may result in poor notation.
1153 In earlier versions of LilyPond (pre 2.11), @code{addQuote} was
1154 written entirely in lower-case letters: @code{\addquote}.
1157 @node Formatting cue notes
1158 @unnumberedsubsubsec Formatting cue notes
1162 @cindex cue notes, formatting
1164 @cindex quoting other voices
1165 @cindex cues, formatting
1167 The previous section deals with inserting notes from another
1168 voice. There is a more advanced music function called
1169 @code{\cueDuring}, which makes formatting cue notes easier.
1174 \cueDuring #@var{name} #@var{updown} @var{music}
1177 This will insert notes from the part @var{name} into a
1178 @code{Voice} called @code{cue}. This happens simultaneously with
1179 @var{music}, which usually is a rest. When the cue notes start,
1180 the staff in effect becomes polyphonic for a moment. The argument
1181 @var{updown} determines whether the cue notes should be notated as
1182 a first or second voice.
1187 \override Stem #'length-fraction = #0.8
1188 \override Beam #'thickness = #0.384
1189 \override Beam #'length-fraction = #0.8
1198 \new Staff \relative c' <<
1200 % setup a context for cue notes.
1201 \new Voice = "cue" { \smaller \skip 1*21 }
1203 \set Score.skipBars = ##t
1207 \cueDuring #"clarinet" #UP {
1215 Here are a couple of hints for successful cue notes:
1219 Cue notes have smaller font sizes.
1222 The cued part is marked with the instrument playing the cue.
1225 When the original part takes over again, this should be marked
1226 with the name of the original instrument.
1229 Any other changes introduced by the cued part should also be
1230 undone. For example, if the cued instrument plays in a different
1231 clef, the original clef should be stated once again.
1235 The macro @code{\transposedCueDuring} is useful to add cues to
1236 instruments which use a completely different octave range (for
1237 example, having a cue of a piccolo flute within a contra bassoon
1240 @lilypond[verbatim,quote]
1241 picc = \relative c''' {
1247 \addQuote "picc" { \picc }
1249 cbsn = \relative c, {
1252 \transposedCueDuring #"picc" #UP c,, { R1 } |
1257 \new Staff = "picc" \picc
1258 \new Staff = "cbsn" \cbsn
1266 @rlsr{Staff notation}.
1268 Internals Reference: