[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: scheme function for staccato
From: |
Mats Bengtsson |
Subject: |
Re: scheme function for staccato |
Date: |
Tue, 22 Apr 2008 23:58:23 +0200 |
User-agent: |
Internet Messaging Program (IMP) H3 (4.0.5) |
Quoting Valentin Villenave <address@hidden>:
> % To modify a sequence of notes, it's easiest to use a filter:
This approach seems to differ from
http://lsr.dsi.unimi.it/LSR/Item?id=82
Reminder to Mats: Always check in LSR first! ;-)
Mats, Reinhold, can you give us some explanations about these
differences? Which one is the best? The simplest? The most reliable?
Should I edit the LSR snippet? Add a new snippet? etc.
The solution in LSR is more or less equivalent to Reinhold's proposal,
but is divided three separate functions instead of two, whereof two are
generic and can be used for any articulation.
However, it turns out that the solution shares the same problem as
Reinhold's solution, which you can see if you replace the score by
\score {
\relative c'' {
a b \addStacc { c, c } }
\layout{ ragged-right = ##t }
}
The same fix that I proposed can be used also here, i.e. to replace the
definition of add-script by
#(define (add-script m x)
(if
(equal? (ly:music-property m 'name) 'EventChord)
(set! (ly:music-property m 'elements)
(append (ly:music-property m 'elements)
(list (make-script x)))))
m)
/Mats
Cheers,
Valentin