lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Subscripted text and centering of TextSpanner line


From: Nick Payne
Subject: Subscripted text and centering of TextSpanner line
Date: Fri, 08 Oct 2010 16:25:37 +1100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.9) Gecko/20100915 Thunderbird/3.1.4

If I have text characters at the left end of a TextSpanner, and some of those characters are subscripted, then the centering of the TextSpanner line seems to be calculated using the total height of both the main and subscripted text, which puts the line at the bottom of the main text rather than being centered on it. While this makes some sort of sense, I think that asking for the line to be centered means that I'm asking for it to be centered on the main text.

%===========================================
\version "2.13.35"

#(set-global-staff-size 30)

\relative c'' {
\once \override TextSpanner #'bound-details #'left #'text = \markup { \concat { CII " " } }
    \once \override TextSpanner #'style = #'line
    \once \override TextSpanner #'font-shape = #'upright
    \once \override TextSpanner #'direction = #UP
    \once \override TextSpanner #'bound-details #'right #'text =
        \markup { \draw-line #'(0 . -0.5) }
\once \override TextSpanner #'bound-details #'left #'stencil-align-dir-y = #CENTER
    gis16\startTextSpan b e b' e e, b' e\stopTextSpan
    \once \override TextSpanner #'bound-details #'left #'text =
        \markup { \concat { "CII" \sub 3 " " } }
    \once \override TextSpanner #'style = #'line
    \once \override TextSpanner #'font-shape = #'upright
    \once \override TextSpanner #'direction = #UP
    \once \override TextSpanner #'bound-details #'right #'text =
        \markup { \draw-line #'(0 . -0.5) }
\once \override TextSpanner #'bound-details #'left #'stencil-align-dir-y = #CENTER
    gis,,\startTextSpan b e b' e e, b' e\stopTextSpan
}
%===========================================

Nick

Attachment: test.preview.png
Description: PNG image


reply via email to

[Prev in Thread] Current Thread [Next in Thread]