lilypond-user
[Top][All Lists]
Advanced

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

Re: Bar lines at beginning of a line


From: Robin Bannister
Subject: Re: Bar lines at beginning of a line
Date: Tue, 28 Apr 2009 18:28:00 +0200

Boris Lau wrote:
I thought it would be quite natural if this would do the job:
\override Staff.BarLine #'break-visibility = #'#(#t #t #t)
but it doesn't.

Certainly a reasonable expectation. This is normally #'#(#t #t #f), but there are cases when Lilypond switches over to #'#(#t #t #t) automatically, as when a \repeat volta follows a \break. This ensures that the repeat's "|:" gets printed on the left.

But convention doesn't want regular barlines on the left, and
Lilypond provides them with a sort of aptosis; they are automatically zapped before they even reach the break-visibility filter.

A simple method would be to make the stencil ignore all that:
#(define (always-single-print grob) (set! (ly:grob-property grob 'glyph-name) "|")
    (ly:bar-line::print  grob))
and then \override Staff.BarLine #'stencil = #always-single-print But this ignores repeats, etc too, so maybe it's too simple. Another approach for barlines on the left is to banish the aptosis. This is what the attached was-empty.ly tries to do. It is rather cumbersome and inflexible, but at least it leaves the other barline types unharmed.

Cheers,
Robin

Attachment: was-empty.ly
Description: Text Data


reply via email to

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