I am creating a LilyPond piano/vocal score starting with the Template A.3.2 Piano and melody with lyrics. In my piece, there will be several bars of instrumental introduction before the vocal line comes in, and I would like the staff for the vocal to be omitted for that part.
The template produces this:
What I have been doing is:
- Pad the start of the vocal line with sufficient rests to cover the duration of the introduction.
- Change the
\RemoveEmptyStaves
option inside the\layout
block to\RemoveAllEmptyStaves
, since\RemoveEmptyStaves
will not affect the first system in a score. - Include a
\break
on the vocal line after the last measure of the introduction to force the change from 2 staves to 3 to occur at the right point.
I now realize that I could also do this:
- Store the notes expressions for the piano intro in separate variables, (say
upperIntro = { }
andlowerIntro = { }
- Include two top-level
\score
blocks (one with 2 staves for the intro and one with 3 staves for the remainder).
Or, as indirectly suggested by Lazy's answer:
- Put the 2-staff intro and 3-staff main part into their own
<<
...>>
blocks. (This does not seem to work inside a\score
block– it throws an error and only outputs the intro part.)
As far as I can tell, the only visual difference is that the version with a single \score
block and break justifies the output for each section:
while the version with two \score
blocks (or two <<
... >>
blocks) left-aligns both sections:
Is there any other reason to prefer one method over the others, i.e. are there any side-effects to the choice that impact flexibility, modularity, appearance, etc.?
Are there other, better ways to accomplish the same thing?