Hi Valentin,
The solutions you provided worked great, I just had to tweak the arpeggio's spacing. The configured dashed bars are also working perfectly.
No. 3:
Apologies for not having provided the code in my first email. I have attached code based on an excerpt from a 9-page score I am working on, and minimized its contents as much as possible. Considering how seemingly random its behavior is, I don't know how to simplify the ossia staves for easier inspection. Code posted below, kindly check the "vOssiaLeft" staff for some instructions.
Thanks in advance!
Hans
================================
\version "2.22.1"
\language "english"
treble = \clef treble
bass = \clef bass
vGlobal = {
\key a \minor
\time 2/4
}
vOssiaRight = \relative c''' {
\vGlobal
<< { \ottava #1 f8-! } \\ { a, } >> \ottava #0 a,32( g f e) d8-!\noBeam \ottava #1 <f'' a f'>8-! |
<d b' d>-!\noBeam \ottava #0 d,,32( c b a) g8-! \ottava #1 << { g'''32( f e d) } \\ { g,8 } >> |
<< { e'8-! } \\ { g, } >> \ottava #0 g,32( f e d) c8-!\noBeam \ottava #1 e''32( g c e) \ottava #0 | \break
}
% Problem here
vOssiaLeft = \relative c' {
\vGlobal
\treble <d f d'>8-!\noBeam \bass a32( g f e) \once \stemDown d8-!\noBeam \treble <f' d'>16-. <e c'>-. |
<d b'>8-!\noBeam \bass \stemUp <d, f>16^. <c e>16^. \stemNeutral << { <b d>8-! } \\ { g } >> \treble <g' d' b'>8-! | %\stopStaff
<c e c'>-!\noBeam \bass g32( f e d) \once \stemDown c8-!\noBeam \treble <c' g' e'>8-! |
% first observe the |. barline after bar 6.
% remove bar 3 of this staff and uncomment 2nd bar \stopStaff.
% notice no difference.
% but then also entirely remove the 2nd bar,
% leaving only 1 bar in this staff.
% notice final barline is fixed.
}
\score {
\new StaffGroup \with {
\override SpanBar.glyph-name = #"!"
\remove System_start_delimiter_engraver } <<
\new PianoStaff \with {
\override SpanBar.glyph-name = #"|"
\override BarLine.staff-space = #1
} <<
\new Staff = "vOssiaRight" \with {
\consists "Span_arpeggio_engraver"
\RemoveAllEmptyStaves
fontSize = #-3
\override StaffSymbol.staff-space = #(magstep -3)
} \vOssiaRight
\new Staff = "vOssiaLeft" \with {
\consists "Span_arpeggio_engraver"
\RemoveAllEmptyStaves
fontSize = #-3
\override StaffSymbol.staff-space = #(magstep -3)
} { \bass \vOssiaLeft }
>>
\new PianoStaff \with {
\override SpanBar.glyph-name = #"|" } <<
\new Staff = "vRight" \relative c'' { \vGlobal c2 c c c c c \once \override StaffGroup.SpanBar.glyph-name = #"|." \bar "|." }
\new Staff = "vLeft" \relative c' { \vGlobal \bass a a a a a a }
>>
>>
}