Customized Italian-style chords: Difference between revisions

Make snippet readable (more or less)
mNo edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
This snippet implement a personalized way to write chords (in Italian) using a command called <code>\AccordiMio</code>, which can be used in <code>\lyricsmode</code>. The format is:
This snippet implement a personalized way to write chords (in Italian) using a command called <code>\AccordiMio</code>, which can be used in <code>\lyricsmode</code>. A single chord has the following format (to be written without spaces between the elements); except <var>root</var>, all elements are optional.


<code><var>root</var> <var>root-alteration</var>
<var>root</var>
<var>root-modifier<var> <var>root-other</var>
<var>root-alteration</var>
_
<var>root-modifier<var>
<var>bass</var> <var>bass-alteration</var>
<var>root-other</var>
.
_
<var>duration</var> [<var>dots</var>]
<var>bass</var>
[* <var>ratio-numerator</var> / <var>ratio-denominator</var>]
<var>bass-alteration</var>
</code>
.
<var>duration</var>
 
Example: <code>soldd-7_rebb.4</code>


* Chords must be written in a long string.
* Chords must be written in a long string.
* Note names and alterations must be written in Italian.
* Note names and alterations must be written in Italian.
* Correspondences between alteration codes and engraved symbols are: d→sharp, dd→double sharp, b→flat, bb→double flat (you can change them in the snippet).
* For convenience, <code>s</code> is also recognized as a value of <var>root</var>, indicating a skip.
* Correspondences between modifier codes and engraved symbols are: "-" (minor)→en dash, "dim" (diminished)→"o", "semidim" (half diminished)→"ø" (you can change them in the snippet).
* Correspondences between alteration codes and engraved symbols are: <code>d</code>→sharp, <code>dd</code>→double sharp, <code>b</code>→flat, <code>bb</code>→double flat (you can change them in the snippet).
* <var>root other</var> is free text.
* Correspondences between modifier codes and engraved symbols are: <code>-</code> (minor)→en dash, <code>dim</code> (diminished)→“o”, <code>semidim</code> (half diminished)→“ø” (you can change them in the snippet).
* The chord duration follows the standard LilyPond format, you can also add dots and a fraction for the ratio multiplier.
* <var>root-other</var> is free text.
* If a bass is present, the chord is written in fractional form with numerator=root and denominator=bass (like Italian style music sheets).
* <var>duration</var> follows the standard LilyPond format, you can also add dots and a fraction for the ratio multiplier.
* If <var>bass</var> is present, the chord is written in fractional form with numerator=root and denominator=bass (like Italian-style music sheets).


<lilypond version="2.24">
<lilypond version="2.24">
Line 329: Line 333:


Accordi = \new Lyrics { \override LyricText.font-name = "JazzChords"
Accordi = \new Lyrics { \override LyricText.font-name = "JazzChords"
     \lyricmode { \AccordiMio {
     \lyricmode { \AccordiMio { "
        "  soldd-7_rebb.4   s.8 do  
      soldd-7_rebb.4
redim7 misemidim7"
      s.8
    }
      do  
      redim7
      misemidim7
    " }
   }
   }
}
}
Line 343: Line 350:
   \Parole
   \Parole
>>
>>
\layout {
  line-width = 12\cm
  ragged-right = ##f
}
</lilypond>
</lilypond>