thanks. So far no luck. I'm giving up for the night. Get back it
tomorrow. Here is what I have tried so far.
\version "2.24.2"
\language "english"
\layout {
indent = 0
\context {
\NullVoice
\RemoveAllEmptyStaves
}
\context {
\Score
\accepts NullVoice
}
\context {
\Staff
\accepts NullVoice
}
}
verseLyricsMelody = \relative c' {
c4 c c c~ | c c c c |
}
verseOneLyrics = \lyricmode {
one two three four five six seven eight
}
\new Score {
\new Staff
<<
<<
\new NullVoice = "verseA" { \break \verseLyricsMelody }
\new Lyrics \lyricsto "verseA" { \verseOneLyrics }
>>
>>
}
\new Score {
\new Staff
<<
<<
\new NullVoice = "verseB" { \break \verseLyricsMelody }
>>
\new Lyrics \lyricsto "verseB" { \verseOneLyrics }
>>
}
On 9/20/2024 7:51 PM, Saul Tobin wrote:
Another way to get the extra Staff not to appear is to add the
following to your \layout block:
\context {
\Score
\accepts NullVoice
}
As an aside directed more at the dev community: is there any good
reason not to make this the default behavior (and similar for
StaffGroup, etc.)? NullVoice is defined with both Staff and Voice as
aliases. I would have assumed this meant that it could be used
anywhere that Staff could be used.
Saul
On Fri, Sep 20, 2024 at 10:25 PM Saul Tobin
<[email protected]> wrote:
The easiest way to get the staff not to appear would be to put
NullVoice inside a Staff or similar context that you want to appear.
On Fri, Sep 20, 2024 at 8:19 PM Walt North <[email protected]>
wrote:
Thanks, that took care of the alignment.
However now I see an empty staff. Is it expected I would then
have to remove all empty staves? I tried that but may not
have it right
\version "2.24.2"
\language "english"
\layout {
indent = 0
\context {
\NullVoice
\RemoveAllEmptyStaves
}
}
verseLyricsMelody = \relative c' {
c4 c c c~ | c c c c |
}
verseOneLyrics = \lyricmode {
one two three four five six seven eight
}
\new Score {
<<
\new Voice = "verse" { \break \verseLyricsMelody }
\new Lyrics \lyricsto "verse" { \verseOneLyrics }
>>
<<
\new NullVoice = "verseB" { \break \verseLyricsMelody }
\new Lyrics \lyricsto "verseB" { \verseOneLyrics }
>>
}
On 9/20/2024 4:58 PM, Saul Tobin wrote:
My understanding is that Devnull is not intended for
alignment of lyrics because it does not have the necessary
engraver to create the invisible grobs used for alignment. It
appears to me in your example that actually the lyrics are
just being spaced evenly without alignment to anything.
Nullvoice is intended for your use case.
On Fri, Sep 20, 2024, 6:06 PM Walt North
<[email protected]> wrote:
Am I missing something? It seems like using devnull to
align lyrics to does pay attention to ties. Ties do seem
to be honored when using voice for alignment.
Below is a stripped down example with screenshot.
\version "2.24.2"
\language "english"
\layout {
indent = 0
}
verseLyricsMelody = \relative c' {
c4 c c c~ | c c c c |
}
verseOneLyrics = \lyricmode {
one two three four five six seven eight
}
\new Score {
<<
\new Voice = "verse" { \break \verseLyricsMelody }
\new Lyrics \lyricsto "verse" { \verseOneLyrics }
>>
<<
\new Devnull = "verseB" { \break \verseLyricsMelody }
\new Lyrics \lyricsto "verseB" { \verseOneLyrics }
>>
}