"Mark Stephen Mrotek" <[email protected]> writes:

> Hello,
>
>  
>
> Using the documentation
>
> http://lilypond.org/doc/v2.18/Documentation/notation/piano
>
> I have "attached" the sustain commands to the "left" staff.
>
> When the lower voice moves to the "right" staff the sustain markings change
> style and location.
>
>  
>
> What must be done?

See

\version "2.18.0"

global = {
  \key c \major
  \time 4/4
}

right = \relative c'' {
  \global
  
  c'1 | c |
  
}

left = \relative c' {
  \global
  
  \set PianoStaff.pedalSustainStyle = #'bracket
  c,4\sustainOn e\sustainOff \sustainOn
  g\sustainOff \sustainOn c\sustainOff |
  \change Staff = "right"
  e\sustainOff \sustainOn g\sustainOff \sustainOn
  c\sustainOff \sustainOn g\sustainOff \sustainOn |
  
}

\score {
  \new PianoStaff <<
    \new Staff = "right" \right
    \new Staff = "left" { \clef bass \left }
  >>
  \layout {
    \context { \Staff
	       \remove "Piano_pedal_engraver"
	       \remove "Piano_pedal_align_engraver"
	     }
    \context { \PianoStaff
	       \consists "Piano_pedal_engraver"
	       \consists "Piano_pedal_align_engraver"
	     }
  }
}
Note that you still get a warning here, but that warning appears
warranted to me given the input.

-- 
David Kastrup
_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to