Am So., 22. März 2020 um 16:39 Uhr schrieb Sami Amiris <sami.ami...@gmail.com>: > > > > Instead of manually applying X-offset-overrides you may try: > > > > #(define end-of-line-right-aligned-sencil > > (lambda (grob) > > (let* ((break-dir (ly:item-break-dir grob)) > > (basic-props (ly:grob-basic-properties grob)) > > (stil-proc (assoc-get 'stencil (reverse basic-props))) > > (stil > > (if (procedure? stil-proc) > > (stil-proc grob) > > point-stencil))) > > > > (if (negative? break-dir) > > (ly:stencil-aligned-to stil X RIGHT) > > stil)))) > > > > > > \layout { > > \context { > > \Score > > \override SpanBar.stencil = #end-of-line-right-aligned-sencil > > } > > \context { > > \Staff > > \override BarLine.stencil = #end-of-line-right-aligned-sencil > > } > > } > > > > Should do the trick in most cases. > > > > Cheers, > > Harm > > Thank you very much! > > Do I understand correctly that you make it count from the right at the end > of the staff system, but in all other cases it does what it usually does?
I'm not exactly sure what you mean with "count from the right" Though, usually compound BarLines are build from a certain point of the X-axis, for now let us call said point ZERO. Other stuff is usually added to the RIGHT. Example for "|||": "|" is placed at ZERO, next "|" is palced to the RIGHT, third "|" is placed to the RIGHT. Always taking 'kern' into account. So _all_ BarLines are aligned to said ZERO. Exceptions are made for ":" in repeat-bar-lines (sometimes added to the LEFT) and those with the segno-sign (sometimes overlying other stuff, p.e "||"). So most Barlines have an extent like '(0 . <some-positive-number>), little different for some repeat Barlines. The right border of the BarLine is finally aligned to the StaffSymbol. This works nicely if the "Default_bar_line_engraver" is in Score-context. Alas, you moved said engraver (similar could be done adhoc by setting the whichBar-property). In either case it is then possible to use different BarLines for different Staffs. Ofcourse now the <some-positive-number> is different. My provided overrides reset the extent, _if_ the BarLines is printed at line-end. Example: (0.0 . 1.2) becomes (-1.2 . 0.0) And all BarLines are right-aligned (at line-end). > Whatever it may have at that point, barline, spanline, whatever? Well, makes little sense to apply 'end-of-line-right-aligned-stencil' to other grobs than BarLine and SpanBar, I'd say... Btw, there was a typo end-of-line-right-aligned-sencil should read: end-of-line-right-aligned-stencil > Thank you very, very much! That will probably end the problem for good > then!! Regrettable, nope. Try those segne-bar-lines... Cheers, Harm