lilypond-user
[Top][All Lists]
Advanced

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

Re: text spanner for pedal


From: Stefan Thomas
Subject: Re: text spanner for pedal
Date: Fri, 29 Feb 2008 12:46:27 +0100

Dear lilypond-users,
I think I found a solution that works now. The new \pedal-command is, at least in the below quoted example, below the piano-sign, and a collision with the music in the staff below is avoided. As You can see, it can be terminated after a rest as well as an short-rest. The only thing missing is (but this isn't important for me), that it has no influence on midi.
Here the example:

\version "2.11.38"



pedal = {
   \textSpannerDown
   \once  \override TextSpanner #'bound-details #'left #'text = \markup { \musicglyph #"pedal.Ped" }
    \once \override TextSpanner #'style = #'dashed-line
   \once \override TextSpanner #'dash-period = #0.01
   \once \override TextSpanner #'bound-details #'right #'attach-dir = #1
   \once \override TextSpanner #'bound-details #'right #'text =\markup { \draw-line #'(0 . 1) }
   \once \override TextSpanner #'bound-details #'right #'padding = #-0.5
   }

%damit das klappt, musst Du danach noch "\start" und "\stopTextSpan" einfuegen, erst dann startet das Symbol!


\score    { <<
\new Staff \relative c {\pedal c1\p\startTextSpan c1\stopTextSpan
\pedal c1 \startTextSpan r1 \stopTextSpan
\pedal c1 \startTextSpan s1 \stopTextSpan
}

\new Staff {\clef bass
    \repeat "unfold" 3 {
g'1 b'} }>>
}




2008/2/29, Stefan Thomas <address@hidden>:
Dear Lilypond-users,
I want to create a text-spanner for the pedal sign. I hope  that I can avoid  problems with vertical collisions between pedal-signs and dynamic. Unfortunately the below quoted file doesn't work as expected. I can't see the "Ped" and the line goes down, although it should go up, and the text spanner is above the dynamic.
What can I do?

ped = {
   \textSpannerDown
   \once \override TextSpanner #'bound-details #'left #'text =
      \markup {\musicglyph #"pedal.Ped" } \once \override TextSpanner #'style =
         #'dashed-line
   \once \override TextSpanner #'dash-period = #0.01
   \once \override TextSpanner #'bound-details #'right #'attach-dir = #1
   \once \override TextSpanner #'bound-details #'right #'text =
      \markup { \draw-line #'(0 .-1}
   \once \override TextSpanner #'bound-details #'right #'padding = #-0.5
   }
   \score {\new Staff \relative {\ped g2 \startTextSpan g2 \stopTextSpan }}


reply via email to

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