]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/user/chords.itely
indent fix.
[lilypond.git] / Documentation / user / chords.itely
1 @c -*- coding: utf-8; mode: texinfo; -*-
2 @ignore
3     Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
4
5     When revising a translation, copy the HEAD committish of the
6     version that you are working on.  See TRANSLATION for details.
7 @end ignore
8
9 @c \version "2.11.51"
10
11
12 @node Chord notation
13 @section Chord notation
14
15 @lilypondfile[quote]{chords-headword.ly}
16
17 Chords can be entered in chord mode, which recognizes some traditional European chord naming conventions.  Chord names can also
18 be displayed.  In addition, figured bass notation can be displayed.
19
20 @menu
21 * Chord mode::
22 * Displaying chords::
23 * Figured bass::
24 @end menu
25
26
27 @node Chord mode
28 @subsection Chord mode
29
30 @cindex chord chords
31
32 Chord mode is used to enter chords using an indicator of the chord
33 structure, rather than the chord pitches.
34
35 @menu
36 * Chord mode overview::
37 * Common chords::
38 * Extended and altered chords::
39 @end menu
40
41 @node Chord mode overview
42 @unnumberedsubsubsec Chord mode overview
43
44 @cindex chord names
45 @cindex chord mode
46
47 Chords can be entered as simultaneous music, as discussed in
48 @ref{Chorded notes}.
49
50 Chords can also be entered in @qq{chord mode}, which is an input
51 mode that focuses on the structures of chords in traditional
52 European music, rather than on specific pitches.  This is
53 convenient for those who are familiar with using chord names to
54 describe chords.  More information on different input modes can be
55 found at @ref{Input modes}.
56
57 @lilypond[verbatim,quote,ragged-right,relative=1]
58 \chordmode { c1 g a g c }
59 @end lilypond
60
61 Chords entered using chord mode are music elements, and can be
62 transposed just like chords entered using simultaneous music.
63
64 Chord mode and note mode can be mixed in sequential music:
65
66 @lilypond[verbatim,quote,ragged-right,relative=1]
67 <c e g>2 < g b d >
68 \chordmode { c2 f}
69 < c e g > < g' b d >
70 \chordmode { f g}
71 @end lilypond
72
73
74 @seealso
75
76 Music Glossary:
77 @rglos{chord}.
78
79 Notation Reference:
80 @ref{Chorded notes},
81 @ref{Input modes}.
82
83 Snippets:
84 @rlsr{Chords}
85
86 @knownissues
87
88 When chord mode and note mode are mixed in sequential music, and
89 chord mode comes first, the note mode will create a new @code{Staff}
90 context.
91
92 @lilypond[verbatim,quote,ragged-right,relative=1]
93 \chordmode { c2 f}
94 < c e g > < g' b d >
95 @end lilypond
96
97 To avoid this behavior, explicitly create the @code{Staff} context:
98
99 @lilypond[verbatim,quote,ragged-right,relative=1]
100 \new Staff {
101   \chordmode { c2 f}
102   < c e g > < g' b d >
103 }
104 @end lilypond
105
106 @node Common chords
107 @unnumberedsubsubsec Common chords
108
109 @cindex triads
110 @cindex seventh chords
111 @cindex root of chord
112 @cindex modifiers, in chords.
113 @cindex chord quality
114
115 Major triads are entered by including the root and an
116 optional duration:
117
118 @lilypond[verbatim,quote,relative=1,ragged-right]
119 \chordmode { c2 f4 g }
120 @end lilypond
121
122 Minor, augmented, and diminished triads are entered by placing
123 @code{:} and a quality modifier string after the duration:
124
125 @lilypond[verbatim,quote,ragged-right,relative=1]
126 \chordmode { c2:m f4:aug g:dim }
127 @end lilypond
128
129 Seventh chords can be created:
130
131 @lilypond[quote,ragged-right,fragment,verbatim,relative=1]
132 \chordmode { c1:7 c:m7 c:maj7 c:dim7 c:aug7 }
133 @end lilypond
134
135 @funindex aug
136 @funindex dim
137 @funindex maj
138 @funindex m
139
140 The table belows shows the actions of the quality modifiers on
141 triads and seventh chords.  A more complete table of modifier usage
142 is found at @ref{Common chord modifiers}.
143
144 @c @table @code
145 @multitable @columnfractions .2 .4 .3
146
147 @item
148 @b{Modifier}
149 @tab
150 @b{Action}
151 @tab
152 @b{Example}
153
154 @item
155 None
156 @tab
157 The default action; produces a major triad.
158 @tab
159 @lilypond[line-width=4\cm, noragged-right]
160 \chordmode {
161   \override Staff.TimeSignature #'stencil = ##f
162   c1
163 }
164 @end lilypond
165
166 @item 
167 m, m7
168 @tab
169 The minor chord.  This modifier lowers the 3rd and (if present) the
170 7th step.
171 @tab
172 @lilypond[line-width=4\cm, noragged-right]
173 \chordmode {
174   \override Staff.TimeSignature #'stencil = ##f
175   c1:m c:m7
176 }
177 @end lilypond
178
179
180 @item 
181 dim, dim7
182 @tab
183 The diminished chord.  This modifier lowers the 3rd, 5th and (if
184 present) the 7th step.
185 @tab
186 @lilypond[line-width=4\cm, noragged-right]
187 \chordmode {
188   \override Staff.TimeSignature #'stencil = ##f
189   c1:dim c:dim7
190 }
191 @end lilypond
192
193 @item 
194 aug
195 @tab
196 The augmented chord.  This modifier raises the 5th step.
197 @tab
198 @lilypond[line-width=4\cm, noragged-right]
199 \chordmode {
200   \override Staff.TimeSignature #'stencil = ##f
201   c1:aug
202 }
203 @end lilypond
204
205 @item 
206 maj, maj7
207 @tab
208 The major 7th chord.  This modifier adds a raised 7th step.  The
209 @code{7} following @code{maj} is optional.  Do NOT use this modifier
210 to create a major triad.
211 @tab
212 @lilypond[line-width=4\cm, noragged-right]
213 \chordmode {
214   \override Staff.TimeSignature #'stencil = ##f
215   c1:maj c:maj7
216 }
217 @end lilypond
218
219 @end multitable
220
221
222 @seealso
223
224 Notation Reference:
225 @ref{Common chord modifiers}.
226
227 Snippets:
228 @rlsr{Chords}.
229
230 @node Extended and altered chords
231 @unnumberedsubsubsec Extended and altered chords
232
233 @cindex extended chords
234 @cindex altered chords
235
236 Chord structures of arbitrary complexity can be created in chord
237 mode.  The modifier string can be used to extend a chord, add or
238 remove chord steps, raise or lower chord steps, and add a bass note
239 or create an inversion.
240
241 The first number following the @code{:} is taken to be the extent
242 of the chord.  The chord is constructed by sequentially adding
243 thirds to the root until the specified number has been reached.
244 If the extent is not a third (e.g., 6), thirds are added up to the
245 highest third below the extent, and then the step of the extent is
246 added.  The largest possible value for the extent is 13.  Any
247 larger value is interpreted as 13.
248
249 @lilypond[quote,ragged-right,fragment,verbatim,relative=1]
250 \chordmode {
251   c1:2 c:3 c:4 c:5
252   c:6 c:7 c:8 c:9
253   c:10 c:11 c:12 c:13
254   c:14
255 }
256 @end lilypond
257
258 @noindent
259 Note that both @code{c:5} and @code{c} produce a C major triad.
260
261 Since an unaltered 11 does not sound good when combined with an
262 unaltered 13, the 11 is removed from a @code{:13} chord (unless it
263 is added explicitly).
264
265 @lilypond[quote,ragged-right,fragment,verbatim,relative=1]
266 \chordmode {
267   c1:13 c:13.11 c:m13
268 }
269 @end lilypond
270
271 @cindex additions, in chords
272
273 Individual steps can be added to a chord.  Additions follow the
274 extent and are prefixed by a dot (@code{.}).
275
276 @lilypond[quote,verbatim,fragment,relative=1]
277 \chordmode {
278   c1:5.6 c:3.7.8 c:3.6.13
279 }
280 @end lilypond
281
282 Added steps can be as high as desired.
283
284 @lilypond[quote,verbatim,fragment,relative=1]
285 \chordmode {
286   c4:5.15 c:5.20 c:5.25 c:5.30
287 }
288 @end lilypond
289
290 @cindex chord steps, altering
291
292 Added chord steps can be altered by suffixing a @code{-} or @code{+}
293 sign to the number.  To alter a step that is automatically included
294 as part of the basic chode structure, add it as an altered step.
295
296 @lilypond[quote,verbatim,fragment,relative=1]
297 \chordmode {
298   c1:7+ c:5+.3- c:3-.5-.7-
299 }
300 @end lilypond
301
302 @cindex removals, in chords
303
304 @funindex ^
305
306 Following any steps to be added, a series of steps to be removed 
307 is introduced in a modifier string with a prefix of @code{^}.  
308 If more than one step is to be removed, the steps to be
309 removed are separated by @code{.} following the
310 initial @code{^}. 
311
312 @lilypond[quote,verbatim,fragment,relative=1]
313 \chordmode {
314   c1^3 c:7^5 c:9^3 c:9^3.5 c:13.11^3.7
315 }
316 @end lilypond
317
318 @funindex sus
319
320 The modifier @code{sus} can be added to the modifier string to
321 create suspended chords.  This removes the 3rd step from the chord.
322 Append either @code{2} or @code{4} to add the 2nd or 4th step to the
323 chord.  @code{sus} is equivalent to @code{^3}; @code{sus4} is
324 equivalent to @code{.4^3}.
325
326 @lilypond[quote,ragged-right,fragment,verbatim]
327 \chordmode {
328   c1:sus c:sus2 c:sus4 c:5.4^3
329 }
330 @end lilypond
331
332 @funindex /
333 @cindex chord inversions
334 @cindex bass note, for chords
335
336 Inversions (putting a pitch other than the root on the bottom of the
337 chord) and added bass notes can be specified by appending
338 @code{/}@var{pitch} to the chord.
339
340 @lilypond[quote,ragged-right,fragment,verbatim, relative=2]
341 \chordmode {
342   c1 c/g c/f
343 }
344 @end lilypond
345
346 @funindex /+
347
348 A bass note that is part of the chord can be added, instead of
349 moved as part of an inversion, by using @code{/+}@var{pitch}.
350
351 @lilypond[quote,ragged-right,fragment,verbatim]
352 \chordmode {
353   c1 c/g c/+g
354 }
355 @end lilypond
356
357 Chord modifiers that can be used to produce a variety of
358 standard chords are shown in 
359 @ref{Common chord modifiers}.
360
361 @seealso
362
363 Notation Reference:
364 @ref{Common chord modifiers}.
365
366 Snippets:
367 @rlsr{Chords}
368
369 @knownissues
370
371 Each step can only be present in a chord once.  The following
372 simply produces the augmented chord, since @code{5+} is
373 interpreted last.
374
375 @lilypond[quote,ragged-right,verbatim,fragment]
376 \chordmode { c1:5.5-.5+ }
377 @end lilypond
378
379 Only the second inversion can be created by adding a bass
380 note.  The first inversion requires changing the root of
381 the chord.
382
383 @lilypond[quote,ragged-right,verbatim,fragment]
384 \chordmode {
385   c'1: c':/g e:6-3-^5 e:m6-^5
386 }
387 @end lilypond
388
389 @node Displaying chords
390 @subsection Displaying chords
391
392 Chords can be displayed by name, in addition to the standard display
393 as notes on a staff.
394
395 @menu
396 * Printing chord names::
397 * Customizing chord names::
398 @end menu
399
400 @node Printing chord names
401 @unnumberedsubsubsec Printing chord names
402
403 @cindex printing chord names
404 @cindex chord names
405 @cindex chords
406
407 Chord names are printed in the @code{ChordNames} context:
408
409 @lilypond[verbatim,quote,relative=1,ragged-right]
410 \new ChordNames {
411   \chordmode {
412     c2 f4. g8
413   }
414 }
415 @end lilypond
416
417 Chords can be entered as simultaneous notes or through the use of
418 chord mode.  The displayed chord name will be the same, regardless
419 of the mode of entry, unless there are inversions or added bass notes:
420
421 @lilypond[verbatim,quote,relative=1]
422 <<
423   \new ChordNames {
424     <c e g>2  <f bes c>
425     <f c' e g>1
426     \chordmode {
427       c2 f:sus4 c1:/f
428     }
429   }
430   {
431     <c e g>2  <f bes c>
432     <f, c' e g>1
433     \chordmode {
434       c2 f:sus4 c1:/f
435     }
436   }
437 >>
438 @end lilypond
439
440 @funindex{\chords}
441
442 @code{\chords @{ ... @}} is a shortcut notation for
443 @code{\new ChordNames @{\chordmode @{ ... @}@}}.
444
445 @lilypond[verbatim,quote,ragged-right, relative=1]
446 \chords {
447   c2 f4.:m g8:maj7
448 }
449 @end lilypond
450
451 @lilypond[verbatim,quote,ragged-right, relative=1]
452 \new ChordNames {
453   \chordmode {
454     c2 f4.:m g8:maj7
455   }
456 }
457 @end lilypond
458
459 @snippets
460
461 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
462 {showing-chords-at-changes.ly}
463
464 @c @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
465 @c {adding-bar-lines-to-chordnames-context.ly}
466
467 @lilypondfile[verbatim,lilyquote,ragged-right,texidoc,doctitle]
468 {simple-lead-sheet.ly}
469
470
471 @seealso
472
473 Music Glossary:
474 @rglos{chord}.
475
476
477 Notation Reference:
478 @ref{Writing music in parallel}.
479
480
481 Snippets:
482 @rlsr{Chords}.
483
484 Internals Reference:
485 @rinternals{ChordNames},
486 @rinternals{Volta_engraver},
487 @rinternals{Bar_engraver}.
488
489 @knownissues
490
491 Chords containing inversions or altered bass notes are not named
492 properly if entered using simultaneous music.
493
494
495 @node Customizing chord names
496 @unnumberedsubsubsec Customizing chord names
497
498 @cindex customizing chord names
499
500 There is no unique system for naming chords.  Different musical
501 traditions use different names for the same set of chords.  There
502 are also different symbols displayed for a given chord name.   The
503 names and symbols displayed for chord names are customizable.
504
505 @cindex Banter
506 @cindex jazz chords
507 @cindex chords, jazz
508
509 The default chord name layout is a system for Jazz music, proposed
510 by Klaus Ignatzek (see @ref{Literature list}).  There are also two
511 other chord name schemes implemented: an alternate Jazz chord
512 notation, and a systematic scheme called Banter chords.  The
513 alternate Jazz notation is also shown on the chart in @ref{Chord
514 name chart}.
515
516 @c TODO --  Change this so we don't have a non-verbatim example.
517 @c  Make short example in docs, then move longer example to
518 @c  appendix, where the length of the snippet won't matter.
519
520 In addition to the different naming systems, different note names
521 are used for the root in different languages.  The predefined
522 variables @code{\germanChords}, @code{\semiGermanChords},
523 @code{\italianChords} and @code{\frenchChords} set these variables.
524 The effect is demonstrated here:
525
526 @lilypondfile[ragged-right]{chord-names-languages.ly}
527
528 If none of the default settings give the desired output, the chord
529 name display can be tuned through the following properties.
530
531 @table @code
532
533 @funindex chordRootNamer
534
535 @item chordRootNamer
536
537 The chord name is usually printed as a letter for the root with an
538 optional alteration.  The transformation from pitch to letter is
539 done by this function.  Special note names (for example, the German
540 @q{H} for a B-chord) can be produced by storing a new function in
541 this property.
542
543 @funindex majorSevenSymbol
544
545 @item majorSevenSymbol
546
547 This property contains the markup object used to follow the output
548 of @code{chordRootNamer} to dentify a major 7 chord. Predefined
549 options are @code{whiteTriangleMarkup} and
550 @code{blackTriangleMarkup}.
551
552 @funindex chordNoteNamer
553
554 @item chordNoteNamer
555
556 When the chord name contains additional pitches other than the root
557 (e.g., an added bass note), this function is used to print the
558 additional pitch.  By default the pitch is printed using
559 @code{chordRootNamer}. The @code{chordNoteNamer} property can be set
560 to a specialized function to change this behavior.  For example, the
561 bass note can be printed in lower case.
562
563 @funindex chordNameSeparator
564
565 @item chordNameSeparator
566
567 Different parts of a chord name are normally separated by a slash.
568 By setting @code{chordNameSeparator}, you can use any desired markup
569 for a separator.
570
571 @funindex chordNameExceptions
572
573 @item chordNameExceptions
574
575 This property is a list of pairs.  The first item in each pair
576 is a set of pitches used to identify the steps present in the chord.
577 The second item is a markups that will follow the @code{chordRootNamer}
578 output to create the chord name.
579
580 @funindex chordPrefixSpacer
581 @item chordPrefixSpacer
582
583 The @q{m} for minor chords is usually printed immediately to the
584 right of the root of the chord.  By setting
585 @code{chordPrefixSpacer}, you can fix a spacer between the root
586 and @q{m}.  The spacer is not used when the root is altered.
587
588 @end table
589
590 @predefined
591
592 @funindex major seven symbols
593 @code{\whiteTriangleMarkup},
594 @code{\blackTriangleMarkup},
595 @funindex \germanChords
596 @code{\germanChords},
597 @funindex \semiGermanChords
598 @code{\semiGermanChords},
599 @funindex \italianChords
600 @code{\italianChords},
601 @funindex \frenchChords
602 @code{\frenchChords}.
603
604
605 @snippets
606
607 @cindex exceptions, chord names.
608 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
609 {chord-name-exceptions.ly}
610
611 @c TODO - tweak snippet to use \blackTriangleMarkup as well
612 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
613 {chord-name-major7.ly}
614
615 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
616 {adding-bar-lines-to-chordnames-context.ly}
617
618 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
619 {volta-below-chords.ly}
620
621 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
622 {changing-chord-separator.ly}
623
624
625 @seealso
626
627 Notation Reference:
628 @ref{Chord name chart},
629 @ref{Common chord modifiers}.
630
631 Installed Files:
632 @file{scm/@/chords@/-ignatzek@/.scm},
633 @file{scm/@/chord@/-entry@/.scm},
634 @file{ly/@/chord@/-modifier@/-init@/.ly}.
635
636 Snippets:
637 @rlsr{Chords}.
638
639 @c Internals Reference:
640 @c @r internals{}.
641
642 @knownissues
643
644 Chord names are determined from both the pitches that are present
645 in the chord and the information on the chord structure that may
646 have been entered in @code{\chordmode}.  If the simultaneous pitches
647 method of entering chords is used, undesired names result from
648 inversions or bass notes.
649
650 @lilypond[quote,ragged-right,verbatim]
651 myChords = \relative c' {
652   \chordmode{ c1 c/g c/f }
653   <c e g> <g c e> <f c' e g>
654 }
655 <<
656   \new ChordNames { \myChords }
657   \new Staff { \myChords }
658 >>
659 @end lilypond
660
661
662 @node Figured bass
663 @subsection Figured bass
664
665 @lilypondfile[quote]{figured-bass-headword.ly}
666
667 Figured bass notation can be displayed.
668
669 @menu
670 * Introduction to figured bass::
671 * Entering figured bass::
672 * Displaying figured bass::
673 @end menu
674
675 @node Introduction to figured bass
676 @unnumberedsubsubsec Introduction to figured bass
677
678 @cindex Basso continuo
679 @cindex Thorough bass
680 @cindex Figured bass
681 @cindex Bass, thorough
682 @cindex Bass, figured
683
684 @c TODO: musicological blurb about FB
685
686
687 LilyPond has support for figured bass, also called thorough bass
688 or basso continuo:
689
690 @lilypond[quote,ragged-right,verbatim,fragment]
691 <<
692   \new Voice { \clef bass dis4 c d ais g fis}
693   \new FiguredBass {
694     \figuremode {
695       < 6 >4 < 7\+ >8 < 6+ [_!] >
696       < 6 >4 <6 5 [3+] >
697       < _ >4 < 6 5/>4
698     }
699   }
700 >>
701 @end lilypond
702
703 The support for figured bass consists of two parts: there is an
704 input mode, introduced by @code{\figuremode}, that accepts
705 entry of bass figures, and there is a context named
706 @code{FiguredBass} that takes care of displaying
707 @code{BassFigure} objects.  Figured bass can also be displayed
708 in @code{Staff} contexts.
709
710 @code{\figures@{ ... @}} is a shortcut notation for
711 @code{\new FiguredBass @{\figuremode @{ ... @}@}}.
712
713
714 Although the support for figured bass may superficially resemble chord
715 support, it is much simpler.  @code{\figuremode} mode simply
716 stores the figures and the @code{FiguredBass} context prints them
717 as entered.  There is no conversion to pitches.
718
719 Figures are created as markup texts.  Any of the standard markup
720 properties can be used to modify the display of figures.  For
721 example, the vertical spacing of the figures may be set with
722 @code{baseline-skip}.
723
724 @seealso
725
726 Snippets:
727 @rlsr{Chords}
728
729
730 @node Entering figured bass
731 @unnumberedsubsubsec Entering figured bass
732
733 @code{\figuremode} is used to switch the input mode to figure mode.
734 More information on different input modes can be
735 found at @ref{Input modes}.
736
737 In figure mode, a group of bass figures is delimited by
738 @code{<} and @code{>}.  The duration is entered after the @code{>}.
739
740 @lilypond[verbatim,quote,ragged-right,fragment]
741 \new FiguredBass {
742   \figuremode {
743     <6 4>2
744   }
745 }
746 @end lilypond
747
748
749 Accidentals (including naturals) can be added to figures:
750
751 @lilypond[verbatim,quote,ragged-right,fragment]
752 \figures {
753   <7! 6+ 4-> <5++> <3-->
754 }
755 @end lilypond
756
757 Augmented and diminished steps can be indicated.
758
759 @lilypond[verbatim,quote,ragged-right,fragment]
760 \figures {
761   <6\+ 5/> <7/>
762 }
763 @end lilypond
764
765 A backward slash through a figure (typically used for raised
766 sixth steps) can be created.
767
768 @lilypond[verbatim,quote,ragged-right,fragment]
769 \figures {
770   <6>
771   <6\\>
772 }
773 @end lilypond
774
775 Vertical spaces and brackets can be be included in figures:
776
777 @lilypond[verbatim,quote,ragged-right,fragment]
778 \figures {
779   <[12 _!] 8 [6  4]>
780 }
781 @end lilypond
782
783 Any text markup can be inserted as a figure:
784
785 @lilypond[verbatim,quote,ragged-right,fragment]
786 \figures {
787   <  \markup{ \tiny \number 6 \super (1)} 5 >
788 }
789 @end lilypond
790
791 @c NOTE: We need to include notes any time we use extenders to
792 @c avoid extraneous staff creation due to Staff.use... in
793 @c \bassFigureExtendersOn
794
795 Continuation lines can be used to indicate repeated figures:
796
797 @lilypond[verbatim,quote,ragged-right,fragment]
798 <<
799   {
800     \clef bass
801     e d c b,
802     e d c b,
803   }
804   \figures {
805     \bassFigureExtendersOn
806     <6 4> <6 3> <7 3> <7 3>
807     \bassFigureExtendersOff
808     <6 4> <6 3> <7 3> <7 3>
809   }
810 >>
811 @end lilypond
812
813 @noindent
814 In this case, the extender lines replace existing figures,
815 unless the continuation lines have been explicitly terminated.
816
817 @lilypond[verbatim,quote,ragged-right,fragment]
818 <<
819   \figures {
820     \bassFigureExtendersOn
821     <6 4> <6 4> <6\! 4\!> <6 4>
822   }
823   {
824     \clef bass
825     d d c c
826   }
827 >>
828 @end lilypond
829
830 The table below summarizes the figure modifiers available.
831
832 @multitable @columnfractions .1 .5 .4
833
834 @item
835 @b{Modifier}
836 @tab
837 @b{Purpose}
838 @tab
839 @b{Example}
840
841 @item
842 +, -, !
843 @tab
844 Accidentals
845 @tab
846 @lilypond[line-width=4\cm]
847 \figures {
848   <7! 6+ 4-> <5++> <3-->
849 }
850 @end lilypond
851
852 @item
853 \+, /
854 @tab
855 Augmented and diminished steps
856 @tab
857 @lilypond[line-width=4\cm]
858 \figures {
859   <6\+ 5/> <7/>
860 }
861 @end lilypond
862
863 @item
864 \\
865 @tab
866 Raised sixth step
867 @tab
868 @lilypond[line-width=4\cm]
869 \figures {
870   <6\\>
871 }
872 @end lilypond
873
874 @item
875 \!
876 @tab
877 End of continuation line
878 @tab
879 @lilypond[line-width=1.5\cm]
880 <<
881   \figures {
882     \bassFigureExtendersOn
883     <6 4> <6 4> <6\! 4\!> <6 4>
884   }
885   {
886     \clef bass
887     d d c c
888   }
889 >>
890 @end lilypond
891
892 @end multitable
893
894
895
896 @predefined
897 @cindex figured bass extender lines
898 @code{\bassFigureExtendersOn},
899 @code{\bassFigureExtendersOff}.
900
901
902 @snippets
903 @lilypondfile[verbatim,lilyquote,texidoc,doctitle]
904 {changing-the-positions-of-figured-bass-alterations.ly}
905
906 @seealso
907 @c Music Glossary:
908 @c @rglos{}.
909
910 @c Learning Manual:
911 @c @rlearning{}.
912
913 @c Notation Reference:
914 @c @ruser{}.
915
916 @c Application Usage:
917 @c @rprogram{}.
918
919 @c Installed Files:
920 @c @file{}.
921
922 Snippets:
923 @rlsr{Chords}.
924
925 Internals Reference:
926 @rinternals{NewBassFigure},
927 @rinternals{BassFigureAlignment},
928 @rinternals{BassFigureLine},
929 @rinternals{BassFigureBracket},
930 @rinternals{BassFigureContinuation},
931 @rinternals{FiguredBass}.
932
933 @c @knownissues
934
935 @node Displaying figured bass
936 @unnumberedsubsubsec Displaying figured bass
937
938 Figured bass can be displayed using the @code{FiguredBass} context,
939 or in most staff contexts.
940
941 When displayed in a @code{FiguredBass} context, the vertical location
942 of the figures is independent of the notes on the staff.
943
944 @lilypond[verbatim,ragged-right,fragment,quote]
945 <<
946   \relative c'' {
947     c4 c'8 r8 c,4 c'
948   }
949   \new FiguredBass {
950     \figuremode {
951       <4>4 <10 6>8 s8
952       <6 4>4 <6 4>
953     }
954   }
955 >>
956 @end lilypond
957
958 @noindent
959 In the example above, the @code{FiguredBass} context must be
960 explicitly instantiated to avoid creating a second (empty) staff.
961
962
963 Figured bass can also be added to @code{Staff} contexts
964 directly.  In this case, the vertical position of the
965 figures is adjusted automatically.
966
967 @lilypond[verbatim,ragged-right,fragment,quote]
968 <<
969   \new Staff = myStaff
970   \figuremode {
971     <4>4 <10 6>8 s8
972     <6 4>4 <6 4>
973   }
974   %% Put notes on same Staff as figures
975   \context Staff = myStaff
976   {
977     \clef bass
978     c4 c'8 r8 c4 c'
979   }
980 >>
981 @end lilypond
982
983
984 When added in a Staff context, figured bass can be displayed above
985 or below the staff.
986
987 @lilypond[verbatim,ragged-right,fragment,quote]
988 <<
989   \new Staff = myStaff
990   \figuremode {
991     <4>4 <10 6>8 s8
992     \bassFigureStaffAlignmentDown
993     <6 4>4 <6 4>
994   }
995   %% Put notes on same Staff as figures
996   \context Staff = myStaff
997   {
998     \clef bass
999     c4 c'8 r8 c4 c'
1000   }
1001 >>
1002 @end lilypond
1003
1004
1005 @predefined
1006 @cindex figured bass alignment
1007 @code{\bassFigureStaffAlignmentDown},
1008 @code{\bassFigureStaffAlignmentUp},
1009 @code{\bassFigureStaffAlignmentNeutral}.
1010
1011 @c @snippets
1012
1013 @seealso
1014 @c Music Glossary:
1015 @c @rglos{}.
1016
1017 @c Learning Manual:
1018 @c @rlearning{}.
1019
1020 @c Notation Reference:
1021 @c @ruser{}.
1022
1023 @c Application Usage:
1024 @c @rprogram{}.
1025
1026 @c Installed Files:
1027 @c @file{}.
1028
1029 Snippets:
1030 @rlsr{Chords}.
1031
1032 Internals Reference:
1033 @rinternals{NewBassFigure},
1034 @rinternals{BassFigureAlignment},
1035 @rinternals{BassFigureLine},
1036 @rinternals{BassFigureBracket},
1037 @rinternals{BassFigureContinuation},
1038 @rinternals{FiguredBass}.
1039
1040 @knownissues
1041
1042 To ensure that continuation lines work properly, it is
1043 safest to use the same rhythm in the figure line as in
1044 the bass line.
1045
1046 @lilypond[verbatim,ragged-right,fragment,quote]
1047 <<
1048   {
1049     \clef bass
1050     \repeat unfold 4 {f16. g32} f8. es16 d8 es
1051   }
1052   \figures {
1053     \bassFigureExtendersOn
1054     % The extenders are correct here, with the same rhythm as the bass
1055     \repeat unfold 4 {<6 4->16. <6 4->32}
1056     <5>8. r16 <6>8 <6\! 5->
1057   }
1058 >>
1059 <<
1060   {
1061     \clef bass
1062     \repeat unfold 4 {f16. g32} f8. es16 d8 es
1063   }
1064   \figures {
1065     \bassFigureExtendersOn
1066     % The extenders are incorrect here, even though the timing is the same
1067     <6 4->4 <6 4->4
1068     <5>8. r16 <6>8 <6\! 5->
1069   }
1070 >>
1071 @end lilypond
1072
1073 When using extender lines, adjacent figures with the same number in
1074 a different figure location can cause the figure positions to invert.
1075
1076 @lilypond[verbatim,ragged-right,fragment,quote,relative=1]
1077 <<
1078  { fis g g, e' }
1079   \figures {
1080     \bassFigureExtendersOn
1081     <6 5> <5\! 4> < 5 _!> <6>
1082   }
1083 >>
1084 @end lilypond
1085
1086 To avoid this problem, simply turn on extenders after the figure that
1087 begins the extender line and turn them off at the end of the extender line.
1088
1089 @lilypond[verbatim,ragged-right,fragment,quote,relative=1]
1090 <<
1091  { fis g g, e' }
1092   \figures {
1093     <6 5> <5 4>
1094     \bassFigureExtendersOn
1095     < 5 _!> <6>
1096     \bassFigureExtendersOff
1097   }
1098 >>
1099 @end lilypond
1100