lilypond-user
[Top][All Lists]
Advanced

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

Re: NullVoice lyrics alignment error


From: David Wright
Subject: Re: NullVoice lyrics alignment error
Date: Thu, 21 Sep 2017 17:43:22 -0500
User-agent: Mutt/1.5.21 (2010-09-15)

On Thu 21 Sep 2017 at 13:58:47 (-0400), Pierre-Luc Gauthier wrote:
> 2017-09-21 13:21 GMT-04:00 David Wright <address@hidden>:
> > I think you're exceeding the capabilities of NullVoice.
> > It will passively follow the position of timing points
> > set by other voices and thereby give \lyricsto the
> > position and alignment information it needs for setting
> > the lyrics, but it doesn't actively set the positions
> > of the notes.
> 
> I see. Thanks for the explanation.
> 
> > Could you try using Voice with \hideNotes?
> 
> Yes it does work.
> I will try in more complex situations but, then again,
> If adding "\hideNotes" fills the purpose of NullVoice, why is it there?
> Obviously, it is far more semantically correct to use NullVoice rather
> than hiding stuff manually as it *is* the purpose of NullVoice; if am
> assuming correctly?

Say I'm setting a typical Anglican (Episcopal) hymn in four parts on
two staves with the words in between them. The voice parts will have
passing notes etc. at different times, each of which necessitates a
left-alignment of that syllable and an appropriate lyric extender.

Before NullVoice came along, the lyrics would be full of \vs \va \vt
and \vb (shorthand for \set associatedVoice = "vsoprano" etc) and there
would be a separate context for the lyric position in the system
(because the lower parts' notes appear after the lyrics).

Now all I do is duplicate the most moving part as a NullVoice, then
subdivide its non-moving notes to correspond with any part(s) moving
at that point. Setting the lyrics to the NullVoice now does everything
automatically, with the odd exception. (For example, the moving part
might have a note displaced by the neighbouring voice being only a
(semi-)tone away.)

> For example, I'm pretty sure the \hideNotes technique won't work for
> adding lyrics to a \partcombine part which I use extensively.

Being English, I've hardly used \partcombine except in the odd
keyboard reduction (which I loathe doing; but US players seem
to protest more strongly about playing from open scores than
UK ones). I've read here that certain things are fragile.

> Here is the \hideNotes version :
> 
> \version "2.21.0"
> 
> displayedMusic = {R1}
> 
> lyricsMusic = {r16 c''}
> 
> verse = \lyricmode {Lyrics}
> % Somehow ^this line breaks Frescobaldi indentation.
> 
> \new Staff <<
>   \new Voice \displayedMusic
>   %\new NullVoice = "nullVoice" \lyricsMusic
>   %\new Lyrics \lyricsto "nullVoice" \verse
>   \new Voice = "hiddenVoice" <<\hideNotes \lyricsMusic>>
>   \new Lyrics \lyricsto "hiddenVoice" \verse
> >>
> 
> I'm still curious as to why it doesn't work though.
> I read the :
> http://lilypond.org/doc/v2.19/Documentation/internals/nullvoice
> documentation.
> Isn't a NullVoice context one that basically sets most stencils to false?
> So am-I correct to assume the notes are still there?

I'm just rationalising from what I've observed, but it would appear
that \hideNotes is the one that just blanks the stencils, so the notes
are still there, the lyrics have to lie under them, and so the measure
gets expanded appropriately.

> Is the problematic lyric being attached to a note *behind* the G clef
> (as seen in my initial example)?
> I know the problem in my example comes from the fact that an MMR is
> not "timed"(<-what would be the correct word here?) it is just
> "centered" in the measure.
> I suppose that the lyrics has no "timed" stuff to align to.

My observations (again without knowing what the code actually does)
suggest that because no X-space is required to set anything¹, the
positions of the timing "anchors" produced by NullVoice have a
zero-point near to the beginning of the line. If you set (and then
hide) something, a rest or a note, then a collision with the clef
and signatures has to be avoided, so the zero-point of time gets
pushed rightwards to a position after them.

¹the MMR is far enough rightwards to be uninvolved.

Cheers,
David.



reply via email to

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