bug-lilypond
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Dead contexts keep making an influence to the end of the line


From: Graham Percival
Subject: Re: Dead contexts keep making an influence to the end of the line
Date: Fri, 27 Oct 2006 15:02:45 -0700
User-agent: Thunderbird 1.5.0.7 (Macintosh/20060909)

Thanks, this has (finally) been added as
http://code.google.com/p/lilypond/issues/detail?id=127

- Graham

Mats Bengtsson wrote:
Hi,

Related to Anthony's troubles, I noticed an issue with trying to reinstantiate
a Lyrics context that has "died" earlier on the same score line.

Consider the following example
\version "2.8.0"
musicwithlyrics = <<
 \relative c'{c d e f}
 \context Lyrics =mylyrics \lyricmode {Here is some text }
 >>
\score{
\relative c'{ c1 \musicwithlyrics c1 \musicwithlyrics }
}

After the first \musicwithlyrics, the mylyrics context dies, since there
are no musical events in that context directly following. However,
LilyPonds still remembers that there was a context there, so the next
time the new incarnation of the same context is created, it is placed
further from the stave. I know that this is normal behaviour if there
are different Lyrics contexts, but I here I tried to avoid this problem
by explicitly naming the context to get the same one again, but it doesn't help.
Of course, one solution is to keep the context alive over the full piece,
\score{
<<
\relative c'{ c1 \musicwithlyrics c1 \musicwithlyrics }
\context Lyrics = mylyrics {s1*4}
 >>
}
but such solutions are inconvenient to say the least.

Actually, in a way it would be more intuitive if LilyPond never
reserved the vertical space of a dead context to the end of the line,
so that for example
\repeat unfold 3 \new Staff { c'1}
ended up on a single line instead of the current stair case result.
For the few cases where you really want the current behaviour,
it's not hard to add spacer notes to keep contexts alive.


  /Mats






reply via email to

[Prev in Thread] Current Thread [Next in Thread]