Hi Arno, On Sat, Mar 23, 2013 at 8:59 AM, Arno Rog <arno....@gmail.com> wrote:
> Arno Rog <arno.rog <at> gmail.com> writes: > > > > Below a MWE of what I am trying to achieve (mind the wordwrap) > I hope someone has a solution to automatically place it at the end > of the staff, irrespective of the width of the staff. > > I'd like to have the last barline exactly at the end of the last staff > without having to trial and error with the extra offset paramater. > The following override still uses 'extra-offset, but the values are set automatically: \override Staff.BarLine #'extra-offset = #(lambda (grob) (let* ((refp (ly:grob-system grob)) (blot (ly:output-def-lookup (ly:grob-layout grob) 'blot-diameter)) (staff (ly:grob-object grob 'staff-symbol)) (staff-X (ly:grob-extent staff staff X)) (bar-extent-X (ly:grob-extent grob grob X)) (current-X (ly:grob-relative-coordinate grob refp X))) (cons (- (cdr staff-X) current-X (interval-length bar-extent-X) (- blot)) 0))) HTH, David
_______________________________________________ lilypond-user mailing list lilypond-user@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-user