lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Shapenote Repeats and Breaks


From: Leland Kusmer
Subject: Re: Shapenote Repeats and Breaks
Date: Mon, 22 Mar 2010 13:10:56 -0400

Hello!
 
Lilypond does this according to bar-glyph-alist, by calling calc-glyph-name from within the barline print routine.
But when you override the BarLine stencil like this, you are bypassing the barline print routine.

Gotcha. 

So try something (which calls calc-glyph-name) like

#(define (with-shapenote-repeats grob)  (let ((g-n (ly:grob-property grob 'glyph-name)))
  (cond      ((string=? g-n "|:") (dotFn grob))
    ((string=? g-n ":|") (barDotFn grob))
    (else (ly:bar-line::print grob)))))


Works like magic! 

 
And maybe the corresponding override doesn't need the \once ?

 \override Staff.BarLine #'stencil = #with-shapenote-repeats
 
Yup; this seems obvious, in retrospect.

Thanks very much!
-Leland


reply via email to

[Prev in Thread] Current Thread [Next in Thread]