Hello Jan-Peter,
thank you very much.
This seems to solve the problem. Maybe it's not perfectly robust, though.
The function now works when the number of lists exactly matches the
number of slur fragments. I'm not sure if this has been the case earlier
or if it had been a little bit more 'generous'.
For the project at hand I can live with that anyway.
Best ans many thanks
Urs
Am 27.04.2012 10:28, schrieb Jan-Peter Voigt:
Hello Urs,
yes there was a syntax change:
you might try
shapeSlur = #(define-music-function (parser location offsets)(list?)
#{
\once \override Slur #'control-points = $(shape-slur offsets)
#})
Variables in musicfunctions now are available by there name without
the preceding $.
The $-sign now introduces a scheme-expression and returns the result
directly ... now here should be more explanation, that I am not able
to put in words right now ;-)
HTH
Cheers, Jan-Peter
On 27.04.2012 10:11, Urs Liska wrote:
Hi list,
the shapeSlur function from the LSR
(http://lsr.dsi.unimi.it/LSR/Snippet?id=777) doesn't seem to work
anymore (at least for me).
That's the 'entrance' function:
shapeSlur =
#(define-music-function (parser location offsets)
(list?)
#{
\once \override Slur #'control-points = #(shape-slur $offsets)
#})
When calling this function I get the error:
Fehler: GUILE signalisierte einen Fehler für den hier beginnenden
Ausdruck
\once \override Slur #'control-points = #
(shape-slur $offsets)
then
Warnung: Typprüfung für »control-points« gescheitert; Wert
»#<unspecified>« muss vom Typ »list« sein
and finally
Unbound variable: $offsets
From what I see I assume that this is due to some change in syntax at
some point (the last time I recall using this function was with 2.14.0).
But as you know I'm still quite lost with Scheme, so I can't neither
verify nor fix this, and so I'd be gracious for any advice. Of course
I can't be sure that this type check at the calling of the 'main'
function is all there is to it, but lilyPond doesn't even get to call
shape-slur ...
Best
Urs
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user