On 2020-04-12 3:50 am, Thomas Morley wrote:
Hi,

consider the following code:


mus = \new Staff { R1 \break R \stopStaff s \startStaff R \break R \break R }

\new StaffGroup
  \with {
      systemStartDelimiterHierarchy =
        #'(SystemStartBracket (SystemStartBrace a b c))
  }
  << \mus \mus \mus >>


The SystemStartBrace vanishes after stop/startStaff.
I'm at a loss here, it does not work out of the box for every version
from 2.12.3 up to master.

Any chance to get the additional SystemStartBrace back?

Yes, but it might have side-effects:

%%%%
systemStartDelimiterHierarchy =
  #'(SystemStartBracket
      (SystemStartBrace a b c)
      (SystemStartBrace a b c))
%%%%

Since \stopStaff and \startStaff create new StaffSymbols, it appears the System_start_delimiter_engraver thinks that these are extra staves in parallel, so your hierarchy says to do this:

   ( / =====
   < | =====
   ( | =====
     | =====
     | =====
     \ =====

Of course, the StaffSymbols never appear at the same time, because they are meant to be replacements. But the SystemStartBrace only spans the first three staves, so it does not apply in the latter part of the score.

Knowing that a duplicate set of staves will appear at some point, you can lie about the hierarchy as my hack above does. This allows the second set of StaffSymbols to be grouped as desired.

Ultimately, System_start_delimiter_engraver needs to be watching for \stopStaff and \startStaff events so it can clean up and rebuild its StaffSymbol collection rather than just append to the existing one.


-- Aaron Hill

_______________________________________________
bug-lilypond mailing list
bug-lilypond@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-lilypond

Reply via email to