lilypond-user
[Top][All Lists]
Advanced

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

Re: Staff Change Line


From: Lukas-Fabian Moser
Subject: Re: Staff Change Line
Date: Sun, 31 Mar 2019 15:07:16 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1

Am 31.03.19 um 14:43 schrieb Erwinstein:
Forgive me for sending multiple messages but the code snippet in my previous
message didn't make it in the email. Sorry, I used the raw tag in the nabble
forum and it was stripped in the email sent to the mailing list. Sorry for
not knowing that will happen.

By the way, here is the code of that measure:

\version "2.18.2"

\new PianoStaff <<
   \new Staff {
     \time 4/4
     \clef "treble"
     \relative c' {
       \key g \major
       << { e2~ e8 d d4 } \\ { <c g>4. c8 c4 <c g>4 } >> |
     }
   }
   \new Staff {
     \time 4/4
     \clef "bass"
     \relative c, {
       \key g \major
       << { r8 e'8 e2 } \\ { g,2. \stemUp <e' d,>4 } >> \stemNeutral |
     }
   }

(There's a >> missing.)

One simple solution would be:

\version "2.18.2"

\new PianoStaff <<
  \new Staff = "upper" {
    \time 4/4
    \clef "treble"
    \relative c' {
      \key g \major
      << { e2~ e8 d d4 } \\ { <c g>4. s8 s4 <c g>4 } >> |
    }
  }
  \new Staff {
    \time 4/4
    \clef "bass"
    \relative c, {
      \key g \major
      << { r8 e'8 e2*1/4\glissando \change Staff = "upper" \voiceTwo c'8 c4 } \\ { g,2. \oneVoice <e' d,>4 } >> |
    }
  }
>>

Note that I removed your usage of \stemXXX commands; their use is generally discouraged since there's more difference between upper and lower voices in a staff than just the stem direction. It's almost always better to use \voiceOne, \voiceTwo etc. and \oneVoice (except for situations where you really want to influene the stem direction _only_).

Best
Lukas




reply via email to

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