Re: Crescendo hairpin colliding with repeat bar line

Werner LEMBERG <[email protected]>
Newsgroups gmane.comp.gnu.lilypond.general
Message-ID <[email protected]>
>> AFAICS this is a bug: The right side of the hairpin gets apparently
>> aligned to the right side of the '|.:' compound barline, not taking
>> into account the actual horizontal width of the compound bar line.
> 
> I'd agree that it would be nice if LilyPond would do this without us
> having to ask for it.
> 
> No idea whether this is reasonably documented [...] but there's a
> proper setting for this behaviour, namely
> Hairpin.endpoint-alignments.

Thanks for checking this.

> [...] But what one could do is this:
> 
> \layout {
>   \override Hairpin.endpoint-alignments =
>   #(lambda (hairpin)
>      (let ((right-bound (ly:spanner-bound hairpin RIGHT)))
>        (if (and (grob::has-interface right-bound 'bar-line-interface)
>                 (not (equal? (ly:grob-property right-bound 'glyph "|")
>                              "|")))
>            (cons LEFT LEFT)
>            (cons LEFT RIGHT))))
> }
> 
> This changes the alignment behaviour at the right end of all Hairpins
> that end at bar lines which are not "|".

Nice!  I think we should provide a proper callback function within
LilyPond to fix this.  What exactly is your reason to handle `|`
differently?


    Werner
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.