|
From: | Pierre Perol-Schneider |
Subject: | Re: how to automatically left-align rehearsal marks at the beginning of a line |
Date: | Thu, 16 Oct 2014 07:08:20 +0200 |
how about:
\version "2.19.13"
\layout {
\context {
\Score
\override RehearsalMark.self-alignment-X =
#(lambda (grob)
(let* ((break-dir (ly:item-break-dir grob)))
(case break-dir
((-1) RIGHT) ;; end-of-line -> right alignedd
((1) LEFT) ;; begin-of-line -> left-aligned
(else CENTER) ;; otherwise -> center-aligned
)))
}
}
\relative c'' {
c1
\tweak break-visibility #end-of-line-visible
\mark "this should be right aligned" |
\break
c1
\mark "this should be center aligned"
c1
\mark "this should be left aligned" |
\break
c1
}
[Prev in Thread] | Current Thread | [Next in Thread] |