%% Generated by lilypond-book
%% Options: [exampleindent=10.16\mm,indent=0\mm,line-width=160\mm,paper-height=845.047\pt,paper-width=597.508\pt,papersize='(cons (* 597.508 pt) (* 845.047 pt))]
\include "lilypond-book-preamble.ly"


% ****************************************************************
% Start cut-&-pastable-section
% ****************************************************************

#(ly:set-option 'eps-box-padding 3.000000)



\paper {
  #(set-paper-size '(cons (* 597.508 pt) (* 845.047 pt)))
  indent = 0\mm
  line-width = 160\mm
  % offset the left padding, also add 1mm as lilypond creates cropped
  % images with a little space on the right
  line-width = #(- line-width (* mm  3.000000) (* mm 1))
}

\layout {
  
}




% ****************************************************************
% ly snippet:
% ****************************************************************
\sourcefilename "/lilypond-2.26.0/input/regression/volta-bracket-grace-synchronization-negative.ly"
\sourcefileline 0
\version "2.25.32"

\header {
  texidoc = "Volta brackets for alternatives beginning with different lengths of
grace notes are not merged if they pertain to different volte.

In the shared staff, the brackets created for the grace notes of part@tie{}B
should end prematurely where part@tie{}A enters.
"
}

#(ly:set-option 'warning-as-error #t)

#(ly:expect-warning
  (ly:translate-cpp-warning-scheme
   "already have a VoltaBracket; ending it prematurely"))
#(ly:expect-warning
  (ly:translate-cpp-warning-scheme
   "already have a VoltaBracket; ending it prematurely"))
#(ly:expect-warning
  (ly:translate-cpp-warning-scheme
   "already have a VoltaBracket; ending it prematurely"))
#(ly:expect-warning
  (ly:translate-cpp-warning-scheme
   "already have a VoltaBracket; ending it prematurely"))
#(ly:expect-warning
  (ly:translate-cpp-warning-scheme
   "already have a VoltaBracket; ending it prematurely"))

voiceA = \fixed c' {
  \repeat volta 3 {
    c'1
    \alternative {
      \volta 1 c'1
      \volta 2 c'1
      \volta 3 c'1
    }
    %% Additional material after \alternative avoids entangling this case with
    %% repeat bar lines.
    c'1
  }
}

voiceB = \fixed c' {
  \repeat volta 6 {
    a1
    \alternative {
      \volta 1,2 { \grace { d16 e f g } a1 }
      \volta 3,4 { \grace { d16 e f g } a1 }
      \volta 5,6 { \grace { d16 e f g } a1 }
    }
    %% Additional material after \alternative avoids entangling this case with
    %% repeat bar lines.
    \grace { d16 e f g } a1
  }
}

shared = << \voiceA \\ \voiceB >>

\score { \new Staff \with { instrumentName = "A" } \voiceA }
\score { \new Staff \with { instrumentName = "B" } \voiceB }
\score {
  \new Staff \with { instrumentName = \markup \column { A B } } \shared
}



% ****************************************************************
% end ly snippet
% ****************************************************************
