Setting the control points of a slur manually: Difference between revisions
Appearance
Import snippet from LSR |
m Replace version="2.24.0" with version="2.24" now that the LilyWiki extension supports auto-selecting the latest release in a stable series |
||
| Line 5: | Line 5: | ||
Adjusting slurs with <code>\shape</code> should be the last editing step; there are high chances that layout changes also alter the shape of slurs. | Adjusting slurs with <code>\shape</code> should be the last editing step; there are high chances that layout changes also alter the shape of slurs. | ||
<lilypond version="2.24 | <lilypond version="2.24"> | ||
%% http://lsr.di.unimi.it/LSR/Item?id=134 | %% http://lsr.di.unimi.it/LSR/Item?id=134 | ||
Revision as of 18:56, 16 November 2025
If necessary you can resort to manually adjusting the control points of a slur. This example demonstrates the use of \vshape, visualizing the control points as an aid to adjust the slur's shape. After the adjustment is done, simply replace \vshape with \shape.
The \shape command also supports shaping of slurs broken by a line break, which is explained in LilyPond's Notation reference.
Adjusting slurs with \shape should be the last editing step; there are high chances that layout changes also alter the shape of slurs.
\version "2.24"
%% http://lsr.di.unimi.it/LSR/Item?id=134
\score {
\new PianoStaff
<<
\context Staff = "up" {
\clef bass
s1 * 4
}
\context Staff = "down" \relative c
<<
s1*4
{
\clef bass
r4 r8
\vshape #'((-0.5 . -3) (10 . 2) (-25 . -20) (-0.5 . -6)) Slur
c8( as' f c' as
% line breaks will mess up this example
\noBreak
f f,, as'' f
\change Staff = up
\clef treble
c' as f' c
\noBreak
as' f c' as
f' c as' f c'4)
}
>>
>>
\layout { }
}