lilypond-user
[Top][All Lists]
Advanced

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

Re: I would like to move the sustainOff


From: Lukas-Fabian Moser
Subject: Re: I would like to move the sustainOff
Date: Sun, 19 Sep 2021 23:11:19 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0

Hi,

Am 19.09.21 um 21:31 schrieb Knute Snortum:
SustainOff after a chord comes before the chord, as it shows in the
manual

I'm used to and would like it to be after the chord.
Is there a way to do that?
You could do it with a tweak, but you'd have to do once for each \sustainOff.

%%%
\version "2.22.1"

\relative {
   c'1 \sustainOn | c \tweak X-offset 2 \sustainOff
}
%%%

LilyPond is even flexible enough to accept

sustainOff = \tweak X-offset 2 \sustainOff

to make the tweak stick.

But I think it's usually better to represent the music semantically correct: A \sustainOff after the note means that the pedal should be released only _after_ the chord is played. For this, David Kastrup's \after function is highly useful:

%%%
\version "2.22.1"

after =
#(define-music-function (delay ev main) (ly:duration? ly:music? ly:music?)
   #{ \context Bottom << { s$delay <> $ev } #main >> #})

\relative {
  % For vertical alignment:
  \override Score.SustainPedal.Y-offset = -3

  c'1 \sustainOn | \after 2 \sustainOff c
}
%%%

Lukas




reply via email to

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