[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Point and click in music-function
From: |
David Kastrup |
Subject: |
Re: Point and click in music-function |
Date: |
Mon, 04 Feb 2013 21:26:34 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) |
Helge Kruse <address@hidden> writes:
> I wrote a small helper to set tuplets that are wide spreaded over the
> score. It gives a compact source. But the PDF file includes
> point-and-click information that points to the function and not the
> actual notes that I entered. As a workaround I can click at the
> triplet number to get approximately to the correct position.
>
> How can I change the behavior so that a click goes directly to the
> note in the source?
>
> % abbreviation for a triplet, \times 2/3 { ... } would be a bit annoying
> tr = #(define-music-function (parser location p1 p2 p3)
> (ly:pitch? ly:pitch? ly:pitch?)
> #{
> \times 2/3 { $p1 8 [ $p2 $p3 ] }
> #})
[...]
I have created
<URL:http://code.google.com/p/lilypond/issues/detail?id=3153> which will
let all the music created within #{ ... #} point to \tr. That's pretty
much the best you can hope to do with reasonable effort. A more precise
solution would only be possible by tacking source information onto
_every_ music function argument and tracing its progress in expressions,
quite more expensive and actually also ill-defined: what is the
point-and-click location for the note generated by $p1 8 ? What is the
location for the beam?
--
David Kastrup