Am 11.08.2016 um 13:29 schrieb Malte Meyn:
Am 11.08.2016 um 13:00 schrieb Urs Liska:
After some experimentation I have the impression this is related to a
phenomenon I see in the attached file. The three functions all return
the original music, but somewhat differently. The point I'm wondering
about is: why does the point-and-click link sometimes (expectedly) point
to the music but sometimes to the function invocation?
I had a similar “problem” some days ago when I was arranging some music
and had conditionals for testing different versions: The following code
sets point-and-click links to the opening parenthesis of the #(if …).
Can this be changed using (*parser*) and (*location*) somehow?
\version "2.19.46"
#(define foo #t)
\relative {
f' f f f e2 e
#(if foo
#{ g4 g g g c,1 #}
#{ d4 d d d c1 #})
}
Nevermind. I just had an idea which works as expected. Sorry for the noise.
%%%%%%%
\version "2.19.46"
#(define foo #f)
altMusic =
#(define-music-function
(sym alt1 alt2)
(symbol? ly:music? ly:music?)
(if foo alt1 alt2))
\relative {
f' f f f e2 e
\altMusic #'foo
{ g4 g g g c,1 }
{ d4 d d d c1 }
}
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user