lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

fingering and addfingering


From: Gianmaria Lari
Subject: fingering and addfingering
Date: Thu, 3 May 2018 12:05:47 +0200

I have short music exercises (for accordion) that I would like to engrave with alternate fingering like in the following example:

\version "2.19.81"
\fixed c' {c-2 d-3 e-2 f-3 g-2 a-3 b-4 c'-5}
\fixed c' {c-1 d-2 e-3 f-4 g-2 a-3 b-4 c'-5}
\fixed c' {c-1 d-2 e-3 f-4 g-2 a\3 b-4 c'\5}

and this is the result:



This is ok, but because it is only the fingering that change it is better to separate music from fingering. I do it with "addFingering" snippet here:

http://lsr.di.unimi.it/LSR/Item?id=768

Using this snippet the previous code can be rewritten like this

\version "2.19.81"
\include "fingering.ly"
music = \fixed c' {c d e f g a b c'}

{\addFingering \music "23232345"}
{\addFingering \music "12342345"}
{\addStringNumber \addFingering \music "12342x4x" "xxxxx3x5"}

This is very nice, except the last line of code. 
Lets see just the problematic thing. Here it is the engrave of the last notes

And this is the code without snippet

\version "2.19.81"
\fixed c' {a\3 b-4 c'\5}

and this the same using the snippet:

\version "2.19.81"
\include "fingering.ly"
music = \fixed c' {a b c'}
{\addStringNumber \addFingering \music "x4x" "3x5"}


The problem is because there are two different functions to use. 
The first one add a finger number (\addFinger) while the other one add a circled finger number (\addStringNumber). It would be great if the snippet would be able to recognize a prefix in front of the number (for example "a3") so that in that case it circle the number. 
If that was the case  this 

{\addStringNumber \addFingering \music "x4x" "3x5"}

could be written as

{\addFingering \music "a34a5"}

Maybe someone had a similar problem and already solved it? I don't need to use this specific snippet if there are other solution.

Thank you, g.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]