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.
9 @node Editorial annotations
10 @section Editorial annotations
12 @lilypondfile[quote]{editorial-headword.ly}
14 This section discusses the various ways to change the appearance of
15 notes and add analysis or educational emphasis.
23 @node Inside the staff
24 @subsection Inside the staff
26 This section discusses how to add emphasis to elements that are
30 * Selecting notation font size::
31 * Fingering instructions::
38 @node Selecting notation font size
39 @subsubsection Selecting notation font size
42 @cindex font size, selecting
43 @cindex selecting font size
45 The font size of notation elements may be altered. It does not
46 change the size of variable symbols, such as beams or slurs.
48 @lilypond[quote,fragment,relative=2,verbatim,ragged-right]
63 @cindex font size scaling
65 Internally, this sets the @code{fontSize} property. This in turns
66 causes the @code{font-size} property to be set in all layout
67 objects. The value of @code{font-size} is a number indicating the
68 size relative to the standard size for the current staff height.
69 Each step up is an increase of approximately 12% of the font size.
70 Six steps is exactly a factor two. The Scheme function
71 @code{magstep} converts a @code{font-size} number to a scaling
72 factor. The @code{font-size} property can also be set directly,
73 so that only certain layout objects are affected.
75 @lilypond[quote,fragment,relative=2,verbatim,ragged-right]
78 \override NoteHead #'font-size = #-4
80 \override Script #'font-size = #2
82 \override Stem #'font-size = #-5
86 @cindex standard font size
87 @cindex font size, standard
89 Font size changes are achieved by scaling the design size that is
90 closest to the desired size. The standard font size (for
91 @code{font-size} equals 0), depends on the standard staff height.
92 For a 20pt staff, a 10pt font is selected.
94 The @code{font-size} property can only be set on layout objects
95 that use fonts. These are the ones supporting the
96 @code{font-interface} layout interface.
104 @funindex \normalsize
115 Snippets: @lsrdir{Editorial,Editorial-annotations}.
117 Internals Reference: @internalsref{font-interface}.
120 @node Fingering instructions
121 @subsubsection Fingering instructions
124 @cindex finger change
126 Fingering instructions can be entered using
127 @var{note}-@var{digit}:
130 @lilypond[quote,verbatim,ragged-right,fragment,relative=2]
134 Use markup texts for finger changes.
136 @lilypond[quote,verbatim,ragged-right,fragment,relative=2]
137 c4-1 d-2 f-4 c^\markup { \finger "2 - 3" }
142 You can use the thumb-script (e.g., in cello music)to indicate that a
143 note should be played with the thumb.
145 @lilypond[quote,verbatim,ragged-right,fragment,relative=2]
146 <a_\thumb a'-3>2 <b_\thumb b'-3>
149 @cindex fingering chords
150 @cindex chords, fingering
152 Fingerings for chords can also be added to individual notes of the
153 chord by adding them after the pitches.
155 @lilypond[quote,verbatim,ragged-right,fragment,relative=2]
156 < c-1 e-2 g-3 b-5 >2 < d-1 f-2 a-3 c-5 >
159 Fingering instructions may be manually placed above or below the
160 staff, see @ref{Controlling direction and placement}.
164 @code{fingeringOrientations} are used to control where the fingering
167 @lilypond[quote,verbatim,ragged-right,fragment,relative=2]
168 \set fingeringOrientations = #'(left)
170 \set fingeringOrientations = #'(down)
172 \set fingeringOrientations = #'(right)
174 \set fingeringOrientations = #'(up)
176 \set fingeringOrientations = #'(left down)
178 \set fingeringOrientations = #'(up right down)
184 Notation Reference: @ref{Controlling direction and placement}
186 Snippets: @lsrdir{Editorial,Editorial-annotations}.
188 Internals Reference: @internalsref{Fingering}.
192 @subsubsection Hidden notes
195 @cindex Invisible notes
196 @cindex Transparent notes
198 @funindex \unHideNotes
200 Hidden (or invisible or transparent) notes can be useful in
201 preparing theory or composition exercises.
203 @lilypond[quote,ragged-right,verbatim,relative=2,fragment]
217 @code{\hideNotes}, @code{\unHideNotes}
221 Snippets: @lsrdir{Editorial,Editorial-annotations}.
224 @node Coloring objects
225 @subsubsection Coloring objects
227 @cindex colored objects
229 @cindex coloring objects
230 @cindex colored notes
231 @cindex coloring notes
232 @cindex notes, colored
234 Individual objects may be assigned colors. You may use the color
235 names listed in the @ref{List of colors}.
237 @lilypond[quote,ragged-right,verbatim,fragment,relative=2]
238 \override NoteHead #'color = #red
240 \override NoteHead #'color = #(x11-color 'LimeGreen)
242 \override Stem #'color = #blue
248 The full range of colors defined for X11 can be accessed by using
249 the Scheme function @code{x11-color}. The function takes one
250 argument; this can be a symbol in the form @var{'FooBar} or a
251 string in the form @var{"FooBar"}. The first form is quicker to
252 write and is more efficient. However, using the second form it is
253 possible to access X11 colors by the multi-word form of its name.
255 If @code{x11-color} cannot make sense of the parameter then the
256 color returned defaults to black.
258 @lilypond[quote,ragged-right,verbatim,fragment,relative=2]
259 \override Staff.StaffSymbol #'color = #(x11-color 'SlateBlue2)
260 \set Staff.instrumentName = \markup {
261 \with-color #(x11-color 'navy) "Clarinet"
265 \override Beam #'color = #(x11-color "medium turquoise")
267 \override Accidental #'color = #(x11-color 'DarkRed)
269 \override NoteHead #'color = #(x11-color "LimeGreen")
271 % this is deliberate nonsense; note that the stems remain black
272 \override Stem #'color = #(x11-color 'Boggle)
276 You can get exact RGB colors by specifying the rgb-color number.
278 @lilypond[quote,ragged-right,verbatim,fragment,relative=2]
279 \override Staff.StaffSymbol #'color = #(x11-color 'SlateBlue2)
280 \set Staff.instrumentName = \markup {
281 \with-color #(x11-color 'navy) "Clarinet"
285 \override Stem #'color = #(rgb-color 0 0 0)
288 \override Stem #'color = #(rgb-color 1 1 1)
291 \override Stem #'color = #(rgb-color 0 0 0.5)
297 Notation Reference: @ref{List of colors}, @ref{Objects connected to
300 Snippets: @lsrdir{Editorial,Editorial-annotations}.
303 An x11 color is not necessarily exactly the same shade as a
304 similarly named normal color.
306 Not all x11 colors are distinguishable in a web browser i.e. a web browser
307 might not display a difference between 'LimeGreen and 'ForestGreen. For
308 web use normal colors are recommended (i.e. #blue, #green, #red).
311 Notes in a chord cannot be colored with @code{\override}; use
312 @code{\tweak} instead, see @ref{Objects connected to the input}.
316 @subsubsection Parentheses
320 @cindex notes, parenthesized
323 Objects may be parenthesized by prefixing @code{\parenthesize} to
324 the music event. This only functions inside chords; to
325 parenthesize a single note it must be enclosed with @code{<>} as
328 @lilypond[quote,relative=2,fragment,verbatim,ragged-right]
329 c2 < \parenthesize d>
332 Non-note objects may be parenthesized as well.
334 @lilypond[quote,relative=2,fragment,verbatim,ragged-right]
335 < c d g >2-\parenthesize -. d
340 Snippets: @lsrdir{Editorial,Editorial-annotations}.
348 Whenever a note is found, a @code{Stem} object is created
349 automatically. For whole notes and rests, they are also created but
358 @funindex \stemNeutral
364 @cindex stem, direction
367 @cindex stem, neutral
369 To change the direction of stems on the center line of the staff, use
371 @lilypond[quote,ragged-right,fragment,relative=2,verbatim]
373 \override Stem #'neutral-direction = #up
375 \override Stem #'neutral-direction = #down
380 Notation Reference: @ref{Controlling direction and placement}.
382 Snippets: @lsrdir{Editorial,Editorial-annotations}.
385 @node Outside the staff
386 @subsection Outside the staff
388 This section discusses how to add emphasis to elements in the staff
389 from outside of the staff.
394 * Analysis brackets::
398 @subsubsection Balloon help
400 Elements of notation can be marked and named with the help of a
401 square balloon. The primary purpose of this feature is to explain
404 @lilypond[quote,verbatim,fragment,ragged-right,relative=2]
405 \new Voice \with { \consists "Balloon_engraver" }
407 \balloonGrobText #'Stem #'(3 . 4) \markup { "I'm a Stem" }
409 \balloonGrobText #'Rest #' (-4 . -4) \markup { "I'm a rest" }
411 <c, g'-\balloonText #'(-2 . -2) \markup { "I'm a note head" } c>2.
415 There are two music functions, @code{balloonGrobText} and
416 @code{balloonText}; The former is used like @code{\once \override} to
417 attach text to any grob, and the latter is used like @code{ \tweak},
418 typically within chords, to attach text to an individual note.
421 @cindex notation, explaining
425 Snippets: @lsrdir{Editorial,Editorial-annotations}.
427 Internals Reference: @internalsref{text-balloon-interface}.
431 @subsubsection Grid lines
433 Vertical lines can be drawn between staves synchronized with the
436 @lilypond[quote,verbatim,ragged-right]
441 \consists "Grid_point_engraver"
442 % this sets the grid interval to 1 quarternote (crotchet)
443 gridInterval = #(ly:make-moment 1 4)
448 %% by default this centers grid lines horizontally below and to the
449 % left side of the notehead, the grid lines extend from
450 % the middle lines of each staff
451 \consists "Grid_line_span_engraver"
473 To change the grid lines use \override.
475 @lilypond[quote,verbatim,ragged-right]
479 \consists "Grid_point_engraver"
480 gridInterval = #(ly:make-moment 1 4)
485 \consists "Grid_line_span_engraver"
486 % this moves them to the right half a staff space
487 \override NoteColumn #'X-offset = #-0.5
499 % this moves them up one staff space from the default position
500 \override Score.GridLine #'extra-offset = #'( 0.0 . 1.0 )
503 \once \override Score.GridLine #'thickness = #5.0
505 \once \override Score.GridLine #'thickness = #1.0
507 \once \override Score.GridLine #'thickness = #3.0
509 \once \override Score.GridLine #'thickness = #5.0
518 Snippets: @lsrdir{Editorial,Editorial-annotations}.
523 @node Analysis brackets
524 @subsubsection Analysis brackets
527 @cindex phrasing brackets
528 @cindex musicological analysis
529 @cindex note grouping bracket
531 Brackets are used in musical analysis to indicate structure in musical
532 pieces. LilyPond supports a simple form of horizontal brackets.
534 @lilypond[quote,verbatim,ragged-right]
537 \Staff \consists "Horizontal_bracket_engraver"
546 Analysis brackets may be nested.
548 @lilypond[quote,verbatim,ragged-right]
551 \Staff \consists "Horizontal_bracket_engraver"
555 c4\startGroup\startGroup
558 d4\stopGroup\stopGroup
564 Snippets: @lsrdir{Editorial,Editorial-annotations}.
566 Internals Reference: @internalsref{HorizontalBracket},
567 @internalsref{Horizontal_bracket_engraver}, @internalsref{Staff}.