[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: doc modification
From: |
James |
Subject: |
Re: doc modification |
Date: |
Thu, 26 Jun 2014 22:14:39 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 |
On 26/06/14 13:57, David Nalesnik wrote:
>
>
>
> On Thu, Jun 26, 2014 at 7:49 AM, David Nalesnik
>
> Not sure why. Attached is my result, where the tie is there
> (Win7, 64-bit).
>
>
> In any case, the altered code is equivalent to
>
> \alterBroken extra-offset #'((0 . 0) (-2 . 5)) Tie
>
> so I can't understand why it wouldn't work as expected.
>
> --David
>
Hmm..
What I have found is that if you use lilypond-book (which is what the
documentation uses) I don't get the expected output but with lilypond in
a *.ly file I do.
If you are unfamiliar with how doc works in that sense, create a file
called foo.tely and it has the content of
--snip--
\input texinfo @node Top
@top
@lilypond[ragged-right,quote]
#(define (my-callback grob)
(let* (
;; have we been split?
(orig (ly:grob-original grob))
;; if yes, get the split pieces (our siblings)
(siblings (if (ly:grob? orig)
(ly:spanner-broken-into orig)
'())))
(if (and (>= (length siblings) 2)
(eq? (car (last-pair siblings)) grob))
'(-2 . 5))))
\relative c'' {
\override Tie.extra-offset = #my-callback
c1 ~ \break
c2 ~ c
}
@end lilypond
@bye
--snip--
Then run
lilypond-book --pdf foo.tely && texi2pdf foo.texi && evince foo.pdf
I use this to check and create simple examples, snippets and the like.
James
Re: doc modification, James, 2014/06/26