Update .ly files.
[lilypond.git] / input / new / defining-predefined-fretboards-for-other-instruments.ly
blobf38d4a2fbe0db04ddc883c76bf65e20d9984048e
1 \version "2.12.0"
2 \header {
3 lsrtags = "fretted-strings"
4 texidoc = "Predefined fret diagrams can be added for new instruments
5 in addition to the standards used for guitar. This file shows how
6 this is done by defining a new string-tuning and a few predefined
7 fretboards for the Venezuelan cuatro.
9 This file also shows how fingerings can be included in the chords
10 used as reference points for the chord lookup, and displayed in
11 the fret diagram and the @code{TabStaff}, but not the music.
13 These fretboards are not transposable because they contain string
14 information. This is planned to be corrected in the future.
17 doctitle = "Defining predefined fretboards for other instruments"
20 %LSR: Thanks to Jesus Guillermo Andrade for the string-tuning
21 %LSR: and fretboard information.
23 % add FretBoards for the Cuatro
24 % Note: This section could be put into a separate file
25 % predefined-cuatro-fretboards.ly
26 % and \included into each of your compositions
28 cuatroTuning = #'(11 18 14 9)
30 dSix = { <a\4 b\1 d\3 fis\2> }
31 dMajor = { <a\4 d\1 d\3 fis \2> }
32 aMajSeven = { <a\4 cis\1 e\3 g\2> }
33 dMajSeven = { <a\4 c\1 d\3 fis\2> }
34 gMajor = { <b\4 b\1 d\3 g\2> }
36 \storePredefinedDiagram \dSix
37 #cuatroTuning
38 #"o;o;o;o;"
39 \storePredefinedDiagram \dMajor
40 #cuatroTuning
41 #"o;o;o;3-3;"
42 \storePredefinedDiagram \aMajSeven
43 #cuatroTuning
44 #"o;2-2;1-1;2-3;"
45 \storePredefinedDiagram \dMajSeven
46 #cuatroTuning
47 #"o;o;o;1-1;"
48 \storePredefinedDiagram \gMajor
49 #cuatroTuning
50 #"2-2;o;1-1;o;"
52 % end of potential include file /predefined-cuatro-fretboards.ly
55 #(set-global-staff-size 16)
57 primerosNames = \chordmode {
58 d:6 d a:maj7 d:maj7
61 primeros = {
62 \dSix \dMajor \aMajSeven \dMajSeven
63 \gMajor
66 \score {
68 \new ChordNames {
69 \set chordChanges = ##t
70 \primerosNames
73 \new Staff {
74 \new Voice \with {
75 \remove "New_fingering_engraver"
77 \relative c'' {
78 \primeros
82 \new FretBoards {
83 \set stringTunings = #cuatroTuning
84 \override FretBoard
85 #'(fret-diagram-details string-count) = #'4
86 \override FretBoard
87 #'(fret-diagram-details finger-code) = #'in-dot
88 \primeros
91 \new TabStaff \relative c'' {
92 \set TabStaff.stringTunings = #cuatroTuning
93 \primeros
98 \layout {
99 \context {
100 \Score
101 \override SpacingSpanner
102 #'base-shortest-duration = #(ly:make-moment 1 16)
105 \midi { }