X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Documentation%2Fsnippets%2Fvertically-aligned-dynamics-and-textscripts.ly;fp=Documentation%2Fsnippets%2Fvertically-aligned-dynamics-and-textscripts.ly;h=82a609c12ff66ab2af1f3ff5dab4e56d575198fb;hb=0ac07f31e0f95fc18e5916ce756b9c746af7cc58;hp=31ec39112c2f7495ddc2934d95c125ace22db13a;hpb=2f1263e2ccdddcac2eb9f7d8ce2ed92867d3d160;p=lilypond.git diff --git a/Documentation/snippets/vertically-aligned-dynamics-and-textscripts.ly b/Documentation/snippets/vertically-aligned-dynamics-and-textscripts.ly index 31ec39112c..82a609c12f 100644 --- a/Documentation/snippets/vertically-aligned-dynamics-and-textscripts.ly +++ b/Documentation/snippets/vertically-aligned-dynamics-and-textscripts.ly @@ -1,27 +1,30 @@ -%% DO NOT EDIT this file manually; it is automatically -%% generated from LSR http://lsr.dsi.unimi.it -%% Make any changes in LSR itself, or in Documentation/snippets/new/ , -%% and then run scripts/auxiliar/makelsr.py -%% -%% This file is in the public domain. -\version "2.16.0" +% DO NOT EDIT this file manually; it is automatically +% generated from Documentation/snippets/new +% Make any changes in Documentation/snippets/new/ +% and then run scripts/auxiliar/makelsr.py +% +% This file is in the public domain. +%% Note: this file works from version 2.17.27 +\version "2.17.27" \header { lsrtags = "spacing, tweaks-and-overrides, workaround" texidoc = " -By setting the @code{'Y-extent} property to a suitable value, all -@code{DynamicLineSpanner} objects (hairpins and dynamic texts) can be -aligned to a common reference point, regardless of their actual extent. -This way, every element will be vertically aligned, thus producing a -more pleasing output. +All @code{DynamicLineSpanner} objects (hairpins and dynamic texts) are +placed with their reference line at least @code{'staff-padding} from +the staff, unless other notation forces them to be farther. +Setting @code{'staff-padding} to a sufficiently large value aligns the +dynamics. -The same idea is used to align the text scripts along their baseline. +The same idea, together with @code{\\textLengthOn}, is used to align +the text scripts along their baseline. " doctitle = "Vertically aligned dynamics and textscripts" } % begin verbatim +\markup \vspace #1 %avoid LSR-bug music = \relative c' { a'2\p b\f @@ -32,8 +35,8 @@ music = \relative c' { { \music \break - \override DynamicLineSpanner #'staff-padding = #2.0 - \override DynamicLineSpanner #'Y-extent = #'(-1.5 . 1.5) - \override TextScript #'Y-extent = #'(-1.5 . 1.5) + \override DynamicLineSpanner.staff-padding = #3 + \textLengthOn + \override TextScript.staff-padding = #1 \music }