lilypond-user
[Top][All Lists]
Advanced

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

Re: Combine staves


From: Andrew Hawryluk
Subject: Re: Combine staves
Date: Sun, 19 Oct 2008 20:25:09 -0600

Yes. Replace "\layout {}" with "\layout { \context{
\RemoveEmptyStaffContext}}" and the empty staff disappears. You can
also place the \break in the "csu" command to make it easier to use.
Maybe you could even add a \tag so this only takes effect in the full
score and the individual instrumental parts are unaffected by the
staff switch or the forced line breaks.

Andrew

\version "2.11.62"

csu = {\change Staff = up \break}

up = \relative c'' {
 \repeat unfold 3 { c4 d e d | }
 \voiceOne c4 d e d
}

down = \relative c' {
 \repeat unfold 2 { c4 d e d |}
 c8 d e f g f g a16 b |
 \csu \voiceTwo c4 d e d
}

\score {
 \new StaffGroup <<
   \new Staff = "up" <<
     \up
   >>
   \new Staff = "down" <<
     \down
   >>
 >>
 \layout { \context{ \RemoveEmptyStaffContext}}
 \midi {}
}


On Sun, Oct 19, 2008 at 5:34 PM, Jonathan Kulp <address@hidden> wrote:
> I created a short example doing this with the staff-change command and it
> gets the lower voice into the upper staff just fine, with the noteheads
> merged and the stems going opposite directions, but the vacated staff
> doesn't disappear like I think Stefan wanted.  Is this the sort of thing you
> envisioned, Andrew?
>
>
> \version "2.11.62"
>
> csu = \change Staff = up
>
> up = \relative c'' {
>  \repeat unfold 3 { c4 d e d | }
>  \break
>  \voiceOne c4 d e d
> }
>
> down = \relative c' {
>  \repeat unfold 2 { c4 d e d |}
>  c8 d e f g f g a16 b |
>  \csu \voiceTwo c4 d e d
> }
>
> \score {
>  \new StaffGroup <<
>    \new Staff = "up" <<
>      \up
>    >>
>    \new Staff = "down" <<
>      \down
>    >>
>  >>
>  \layout {}
>  \midi {}
> }
>
>
> Andrew Hawryluk wrote:
>>
>> This could be nice occasion to use the \chage Staff = "..." command,
>> which is explained in the section of keyboard music (where it is
>> indidpensible), but it can be used on any named staves in your score.
>> You can also change the instrument name manually at this point.
>>
>> Note that you will need to make sure that the change happens at a line
>> break so the score makes sense. I guess you could wait to the end when
>> you know where the line breaks are. Does anyone know of a more elegant
>> solution?
>>
>> Andrew
>>
>> On Sun, Oct 19, 2008 at 2:32 PM, Jonathan Kulp <address@hidden>
>> wrote:
>>>
>>> Well, it's easy enough to put two voices on the same staff and make their
>>> stems go in opposite directions.  See the docs where they discuss
>>> single-staff polyphony (Learning Manual section 2.3.5 for version 2.11.62
>>> or
>>> later), and depending on how you do the single-staff polyphony, you may
>>> need
>>> \voiceOne, \voiceTwo, and so forth.
>>>
>>> If you leave the second staff empty in spots where the first staff has
>>> both
>>> voices (by empty I mean having skips or full-measure rests), then I
>>> *think*
>>> it is hidden by default.
>>>
>>> HTH,
>>>
>>> Jon
>>>
>>> Stefan Slapeta wrote:
>>>>
>>>> Hi all,
>>>>
>>>> is it possible to combine two staves temporarily in the score? The
>>>> reason
>>>> behind it is that two voices have identical notes in this section, and I
>>>> would like to print them in one single staff (stem up and down). It
>>>> would be
>>>> nice if this also reflects to the instrument names...
>>>>
>>>> Thanks!
>>>>
>>>> Stefan
>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> lilypond-user mailing list
>>>> address@hidden
>>>> http://lists.gnu.org/mailman/listinfo/lilypond-user
>>>>
>>> --
>>> Jonathan Kulp
>>> http://www.jonathankulp.com
>>>
>>>
>>> _______________________________________________
>>> lilypond-user mailing list
>>> address@hidden
>>> http://lists.gnu.org/mailman/listinfo/lilypond-user
>>>
>>
>
> --
> Jonathan Kulp
> http://www.jonathankulp.com
>




reply via email to

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