\version "2.14.2" % Snippet to auto-merge rests \include "336.ily" \paper { ragged-right = ##t } notesone=\relative c'' { a4 b r b R1 a1 } notestwo=\relative c'{ f4 r r f R1 c1 } \layout { \context { \Staff \override RestCollision #'positioning-done = #merge-rests-on-positioning \override MultiMeasureRest #'Y-offset = #merge-multi-measure-rest-on-Y-offset } } \score { << \new Staff { \clef treble \time 4/4 \new Voice = "EmptyFirst" \relative c'' { R1 * 3 c1~ c1~ c1 } } \new Staff { \clef treble \time 4/4 << \new Voice = "VoiceOne" { \voiceOne \notesone \break \notesone } \new Voice = "VoiceTwo" { \voiceTwo \notestwo \notestwo } >> } >> \layout { indent = #0 \context { \RemoveEmptyStaffContext } \context { \Score \override VerticalAxisGroup #'remove-first = ##t } % for rest-merges to work, I need to write the following again %\context { % \Staff % \override RestCollision #'positioning-done = #merge-rests-on-positioning % \override MultiMeasureRest #'Y-offset = #merge-multi-measure-rest-on-Y-offset %} } }