Guide, node Updating translation committishes..
@end ignore
-@c \version "2.13.46"
+@c \version "2.15.16"
@node Fretted string instruments
@section Fretted string instruments
@snippets
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{controlling-the-placement-of-chord-fingerings.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{allowing-fingerings-to-be-printed-inside-the-staff.ly}
@cindex tablature and harmonic indications
@cindex slides in tablature notation
@cindex tablature and slides
+@cindex chord glissandi
+@funindex \harmonic
+@funindex \harmonicByFret
+@funindex \harmonicByRatio
+
+Harmonic indications can be added to tablature notation as sounding
+pitches:
+
+@lilypond[verbatim,quote]
+firstHarmonic = {
+ <d'\4\harmonic>4
+ <g'\3\harmonic>4
+ <b'\2\harmonic>2
+}
+\score {
+ <<
+ \new Staff { \firstHarmonic }
+ \new TabStaff { \firstHarmonic }
+ >>
+}
+@end lilypond
+
+Note that the command @code{\harmonic} must always be defined
+inside a chord construct. It only makes sense for open-string harmonics
+in the 12th fret. All other harmonics should be calculated by LilyPond.
+This can be achieved by indicating the fret where a finger of the
+fretting hand should touch a string.
+
+@lilypond[verbatim,quote]
+fretHarmonics = {
+ \harmonicByFret #5 d16\4
+ \harmonicByFret #4 d16\4
+ \harmonicByFret #3 d8\4
+ \harmonicByFret #5 <g\3 b\2>2.
+}
+\score {
+ <<
+ \new Staff { \fretHarmonics }
+ \new TabStaff { \fretHarmonics }
+ >>
+}
+@end lilypond
-Harmonic indications and slides can be added to tablature
-notation.
+Alternatively, harmonics can be computed by defining the ratio of
+string lengths above and below the harmonic fingering.
-@lilypond[verbatim, quote, relative=1]
-\new TabStaff {
- \new TabVoice {
- <c g'\harmonic>4 d\2\glissando e\2
- }
+@lilypond[verbatim,quote]
+ratioHarmonics = {
+ \harmonicByRatio #1/2 <g\3 b\2 e'\1>4
+ \harmonicByRatio #1/3 <g\3 b\2 e'\1>4
+ \harmonicByRatio #1/4 { g8\3 b8\2 e'4\1 }
+}
+\score {
+ <<
+ \new Staff { \ratioHarmonics }
+ \new TabStaff { \ratioHarmonics }
+ >>
}
@end lilypond
@snippets
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{stem-and-beam-behavior-in-tablature.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{polyphony-in-tablature.ly}
+@lilypondfile[verbatim,quote,texidoc,doctitle]
+{open-string-harmonics-in-tablature.ly}
+
+@lilypondfile[verbatim,quote,texidoc,doctitle]
+{fretted-string-harmonics-in-tablature.ly}
+
+@lilypondfile[verbatim,quote,texidoc,doctitle]
+{slides-in-tablature.ly}
+
+@lilypondfile[verbatim,quote,texidoc,doctitle]
+{chord-glissando-in-tablature.ly}
+
@seealso
Notation Reference:
-@ref{Stems}.
+@ref{Stems},
+@ref{Harmonics},
+@ref{Glissando}.
Snippets:
@rlsr{Fretted strings}.
@cindex tablature, bass
@cindex tablature, double bass
-@funindex StringTunings
+@funindex stringTunings
LilyPond tablature automatically calculates the fret for
a note based on the string to which the note is assigned.
@code{banjo-open-g-tuning}. The predefined string tunings
are found in @file{ly/string-tuning-init.ly}.
-@funindex contextStringTunings
-@funindex \contextStringTunings
+@funindex stringTuning
+@funindex \stringTuning
@cindex tablature, custom string tunings
@cindex custom string tunings
Any desired string tuning can be created. The
-@code{\contextStringTuning} function can be
-used to define a string tuning and set it as the
-@code{stringTunings} for the current context.
-@code{\contextStringTuning} takes two arguments: the
-symbol in which the string tuning will be stored,
-and a chord construct
-that defines the pitches of each string in the tuning.
+@code{\stringTuning} function can be
+used to define a string tuning which can be used
+to set @code{stringTunings} for the current context.
+
+Its argument is a chord construct
+defining the pitches of each string in the tuning.
The chord construct must be in absolute octave mode,
see @ref{Absolute octave entry}. The string
with the highest number (generally the lowest string) must
\mynotes
}
\new TabStaff {
- \contextStringTuning #'custom-tuning <c' g' d'' a''>
+ \set stringTunings = \stringTuning <c' g' d'' a''>
\mynotes
}
>>
The @code{stringTunings} property is also used by
@code{FretBoards} to calculate automatic fret diagrams.
-@funindex makeStringTuning
-@funindex \makeStringTuning
-
String tunings are used as part of the hash key
for predefined fret diagrams
-(see @ref{Predefined fret diagrams}). The @code{\makeStringTuning}
-function is used to create a string tuning without setting the
-@code{stringTunings} property in the current context. The
-arguments to @code{\makeStringTuning} are the symbol to be
-used for the new string tuning and a chord construct used
-to define the tuning.
+(see @ref{Predefined fret diagrams}).
+
The previous example could also be written as follows:
@lilypond[quote,verbatim]
-\makeStringTuning #'custom-tuning <c' g' d'' a''>
+"custom-tuning" = \stringTuning <c' g' d'' a''>
mynotes = {
c'4 e' g' c'' |
object. Pitch objects are created with the Scheme function
@code{ly:make-pitch} (see @ref{Scheme functions}).
-If desired, a string tuning can be created as a Scheme
-literal. The example below recreates the examples above,
-but the string tuning is not saved as a separate object:
-
-@lilypond[quote,verbatim]
-mynotes = {
- c'4 e' g' c'' |
- e''4 g'' b'' c'''
-}
-
-<<
- \new Staff {
- \clef treble
- \mynotes
- }
- \new TabStaff {
- \set TabStaff.stringTunings = #`(,(ly:make-pitch 1 5 0)
- ,(ly:make-pitch 1 1 0)
- ,(ly:make-pitch 0 4 0)
- ,(ly:make-pitch 0 0 0))
- \mynotes
- }
->>
-@end lilypond
+@code{\stringTuning} creates such an object from chord input.
LilyPond automatically calculates the number of lines in the
@code{TabStaff} and the number of strings in an automatically
calculated @code{FretBoard} as the number of elements
in @code{stringTunings}.
+To let all TabStaff contexts use the same custom tuning by default,
+you can use
+
+@example
+\layout @{
+ \context @{
+ \TabStaff
+ stringTunings = \stringTuning \notemode @{ <c' g' d'' a''> @}
+ @}
+@}
+@end example
+
+
@cindex moderntab clef
@cindex clef, moderntab
@cindex clef, tab
@snippets
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{changing-fret-orientations.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{customizing-markup-fret-diagrams.ly}
@seealso
@cindex fret diagrams
@cindex fret diagrams, ukulele
+@cindex fret diagrams, mandolin
@cindex chord diagrams
@funindex FretBoards
}
@end lilypond
+Fret diagrams for the mandolin are contained in the file
+@file{predefined-mandolin-fretboards.ly}.
+
+@lilypond[verbatim, ragged-right, quote]
+\include "predefined-mandolin-fretboards.ly"
+
+myChords = \chordmode { c1 c:m7.5- c:aug }
+
+\new ChordNames {
+ \myChords
+}
+
+\new FretBoards {
+ \set stringTunings = #mandolin-tuning
+ \myChords
+}
+@end lilypond
+
Chord pitches can be entered
either as simultaneous music or using chord mode (see
@ref{Chord mode overview}).
@snippets
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{customizing-fretboard-fret-diagrams.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{defining-predefined-fretboards-for-other-instruments.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{chordchanges-for-fretboards.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{fretboards-alternate-tables.ly}
Installed Files:
@file{ly/predefined-guitar-fretboards.ly},
@file{ly/predefined-guitar-ninth-fretboards.ly},
-@file{ly/predefined-ukulele-fretboards.ly}.
+@file{ly/predefined-ukulele-fretboards.ly},
+@file{ly/predefined-mandolin-fretboards.ly}.
Snippets:
@rlsr{Fretted strings}.
@snippets
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{placement-of-right-hand-fingerings.ly}
-@lilypondfile[verbatim,lilyquote,texidoc,doctitle]
+@lilypondfile[verbatim,quote,texidoc,doctitle]
{fingerings,-string-indications,-and-right-hand-fingerings.ly}
@funindex banjo-open-dm-tuning
@funindex four-string-banjo
-A number of common tunings for banjo are predefined in LilyPond:
+A number of common tunings for the five-string banjo are predefined:
@code{banjo-c-tuning} (gCGBD), @code{banjo-modal-tuning} (gDGCD),
@code{banjo-open-d-tuning} (aDF#AD) and @code{banjo-open-dm-tuning}
(aDFAD).
-These tunings may be converted to four-string banjo tunings using the
+These may be converted to four-string tunings using the
@code{four-string-banjo} function:
@example
\set TabStaff.stringTunings = #(four-string-banjo banjo-c-tuning)
@end example
-
@seealso
Snippets:
@rlsr{Fretted strings}.
Installed Files:
-@file{scm/output-lib.scm} contains predefined banjo tunings.
+@file{ly/string-tunings-init.ly}