Hi, Does anyone remember how to align markup relative to the *center* of the parent notehead? I engineered a solution to exactly this question in a thread from September 2006 between me and Markus Schneider ...
http://lists.gnu.org/archive/html/lilypond-user/2006-09/msg00088.html ... and, in fact, attached a PNG of exactly what I was looking for. That PNG is reattached here as notehead-centering.png. But, alas, the old code, from 2.9.16, no longer appears to work. Here it is: %%% BEGIN X-PARENT CENTERING SNIPPET %%% \version "2.9.16" textScriptCenterOnParent = \override TextScript #'X-offset = #(ly:make-simple-closure `(,+ ,(ly:make-simple-closure (list ly:self-alignment-interface::x-aligned-on-self)) ,(ly:make-simple-closure (list ly:self-alignment-interface::centered-on-x-parent)))) \new Staff { \textScriptCenterOnParent \override TextScript #'self-alignment-X = #left c'4_\markup { MMM } \override TextScript #'self-alignment-X = #center c'4_\markup { MMM } \override TextScript #'self-alignment-X = #right c'4_\markup { MMM } } %%% END X-PARENT SNIPPET %%% The result of running that bit of code under 2.12.2 is attached as weird-notehead-centering.png. Odd, yes? So does anyone know what's going on? (FWIW I've tried running convert-ly but convert-ly is currently finding the wrong version of Python on my system and refusing to start, which is frustrating since I've been using 2.5 forever; I haven't yet had time to figure out what to tell lilylib.require_python_version() to make it happy.) Trevor. -- Trevor Bača trevorb...@gmail.com
<<attachment: notehead-centering.png>>
<<attachment: weird-notehead-centering.png>>
_______________________________________________ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user