Dear Valentin,

Thank you for your time in replying to my appeal for help, and your advice.


I have altered the code within \layout so as to affect only the \ChoirStaff 
rather than \Score as you suggested, and indeed this removes the repeated brace 
in the \PianoStaff.


I tried replacing the replicate-stil code with your version, but the whole code 
does not now seem to compile, giving the message 
> “Guile signaled an error for the expression beginning here
> #(let ((book-handler (if (defined? 'default-toplevel-book-handler)
> 
> Unbound variable: ly:paper-column::break-
> 
> Exited with return code 1."
> 
> 

Should I infer from your point (3) that it is impossible to start a new system 
after replicateDelims?


And would it be correct to deduce that this is something which is simply (in 
all respects) impossible to achieve in Lilypond? 


Or is there perhaps another (less automatic) method whereby the mid-staff 
bracket and the initial barline maybe "drawn in” empirically as some kind of 
zero-dimension graphic? I can work out how to draw the barline, but the bracket 
is a bit more complicated - I’m willing to spend time trying to work out the 
correct parameters, but I have no idea where to start with the bracket stencil!


If there is another method that would work in some way, I’d be really pleased 
to hear about it.


Many thanks again,


Alex Voice
 





> On Jul 23, 2023, at 11:08 PM, Valentin Petzel <[email protected]> wrote:
> 
> 
> The trick is simply to not override the stencil for these cases.
> 
> 
> But before you invest huge amounts of effort remember this code does not 
> handle 
> breaks exactly well. Back then I spent a significant amount of time to get my 
> solution to work well with any configuration of breaks, it is quite a pain to 
> handle the breaking behaviour here.
> 
> 
> The issues here:
> 1) If you have a break in the place the replication happens you get a 
> replication at the end of the line. This should probably include a check if 
> the line is broken.
> 
> 
> 2) When you have a break so that in a line no columns replicate you get an 
> issue. This can probably be solved like this:
> 
> 
> #(define replicate-stil
> (grob-transformer
> 'stencil
> (lambda (grob original)
> (let* ((replicate (ly:grob-object grob 'replicate-on-cols))
> (replicate (if (ly:grob-array? replicate) (ly:grob-array->list 
> replicate) '()))
> (left (ly:spanner-bound grob LEFT))
> (own (interval-start (ly:paper-column::break-align-width left 
> 'clef)))
> (sts (map (lambda (col)
> (let ((tr (interval-start (ly:paper-column::break-
> align-width col 'clef))))
> (ly:stencil-outline
> (ly:stencil-translate-axis original (- tr own) X)
> empty-stencil)))
> replicate)))
> (if (null? replicate)
> original
> (apply ly:stencil-add (cons original sts)))))))
> 
> 
> 3) When the line is broken so that the staff is stopped at the begin of the 
> line no initial delimters will be created. Thus also nothing will be 
> replicated.
> 
> 
> Cheers,
> Valentin
> 
> 
> Am Sonntag, 23. Juli 2023, 21:06:05 CEST schrieb Alex Voice:
>> 
>> 
>> I should like, if possible,
>> the Piano Staff at the bottom not to have its brace reinstated,
>> to lose the SpanBar between ChoirStaff and PianoStaff (that’s probably the
>> easy bit - I’ve just forgotten how!)
>> 
> 

Reply via email to