Hi list !
I'm training some Scheme stuff, especially by rewriting basic Lily functions in Scheme. I'm now trying to create a function that increases by 1 the degree of the note argument. So I have to "catch" the second figure of the
'pitch
(ly:make-pitch a b c))
to add 1 to it.

The function begins with :

 increasedegree= #(define-music-function (parser location note)(ly:music?)
         "adds 1 to the second figure of the pitch"
(let ((result-note (ly:music-deep-copy note))) ;local copy of the note passed as argument ((result-pitch (ly:music-property (first (ly:music-property result-note 'elements)) 'pitch))) ;local copy of the pitch of result-note

How can I call for the second figure of the pitch?
This trick would be usefull for other functions I'm trying to write ! Maybe this trick is treated in the manual, but I haven't seen it...

have a good day !

JMarc
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to