lilypond-user
[Top][All Lists]
Advanced

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

TextSpanner terminates too early


From: Nick Payne
Subject: TextSpanner terminates too early
Date: Thu, 19 Nov 2009 07:39:13 +1100
User-agent: Thunderbird 2.0.0.23 (Windows/20090812)

Following example shows a problem I have in a score with multiple voices where I want the TextSpanner for a barre to be two bars long. Because the actual notes in the two bars are split between the voices, I have the \stopTextSpan on the silent eighth note at the end of bar two in voiceOne, but it is terminating as if I had it on the B flat at the start of the bar. In fact there is no difference in the output between having the \stopTextSpan on the B flat or s8. Why is this?

%================================================================
\version "2.13.7"

barre = #(define-music-function (parser location fretnum dirn shorten adjBreak adjEnd)
   (string? number? pair? number? number?)
#{
   \once \override TextSpanner #'bound-details #'left #'text =
   \markup { \small { \concat { "C" "." $fretnum " " } } }
   \once \override TextSpanner #'style = #'line
   \once \override TextSpanner #'font-shape = #'upright
   \once \override TextSpanner #'direction = #$dirn
\once \override TextSpanner #'bound-details #'right #'text = \markup { \draw-line #(cons 0 (/ $dirn -1)) } \once \override TextSpanner #'bound-details #'left #'stencil-align-dir-y = #CENTER \once \override TextSpanner #'bound-details #'left #'padding = #(car $shorten) \once \override TextSpanner #'bound-details #'right #'padding = #(cdr $shorten) \once \override TextSpanner #'bound-details #'right-broken #'padding = #$adjEnd \once \override TextSpanner #'bound-details #'left-broken #'X = #$adjBreak
   \once \override TextSpanner #'bound-details #'left-broken #'text = ##f
   \once \override TextSpanner #'bound-details #'right-broken #'text = ##f
#})

\relative c' {
   \time 5/8
   \new Staff
   <<
   \new Voice = "first"
{ \voiceOne \barre "6" #UP #'(-0.5 . -1) #5 #1 bes8\startTextSpan f' aes d_( e) |
       bes'4 s4 s8\stopTextSpan |
   }
   \new Voice= "second"
   { \voiceTwo
       s2 s8 |
       bes f e aes, e' |
   }
   >>
}
%================================================================


Nick

PNG image


reply via email to

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