]> git.donarmstrong.com Git - lilypond.git/blobdiff - Documentation/snippets/horizontally-aligning-custom-dynamics-e.g.-sempre-pp,-piu-f,-subito-p.ly
Removes '-signs from vectors
[lilypond.git] / Documentation / snippets / horizontally-aligning-custom-dynamics-e.g.-sempre-pp,-piu-f,-subito-p.ly
index 0457dcfcb0b6d8b2f79b5e316889f3ddfe80d385..483692c6db549e732e7039dbacfaaa5d89ffe420 100644 (file)
@@ -1,19 +1,23 @@
-%% Do not edit this file; it is auto-generated from LSR http://lsr.dsi.unimi.it
+%% 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.
 %% This file is in the public domain.
-\version "2.13.1"
+\version "2.17.6"
 
 \header {
 
 \header {
-  lsrtags = "expressive-marks, tweaks-and-overrides"
+  lsrtags = "correction-wanted, expressive-marks, tweaks-and-overrides, version-specific"
 
   texidoc = "
 
   texidoc = "
-Some dynamic expressions involve additional text, like \"sempre pp\".
-Since lilypond aligns all dynamics centered on the note, the \\pp would
-be displayed way after the note it applies to.
+Some dynamic expressions involve additional text, like @qq{sempre pp}.
+Since dynamics are usually centered under the note, the \\pp would be
+displayed way after the note it applies to.
 
 
-To correctly align the \"sempre \\pp\" horizontally, so that it is
+To correctly align the @qq{sempre pp} horizontally, so that it is
 aligned as if it were only the \\pp, there are several approaches:
 
 aligned as if it were only the \\pp, there are several approaches:
 
-* Simply use @code{\\once\\override DynamicText #'X-offset = #-9.2}
+* Simply use @code{\\once\\override DynamicText.X-offset = #-9.2}
 before the note with the dynamics to manually shift it to the correct
 position. Drawback: This has to be done manually each time you use that
 dynamic markup... * Add some padding (@code{#:hspace 7.1}) into the
 before the note with the dynamics to manually shift it to the correct
 position. Drawback: This has to be done manually each time you use that
 dynamic markup... * Add some padding (@code{#:hspace 7.1}) into the
@@ -26,9 +30,9 @@ or dynamics to be shown in that position.
 Drawback: @code{\\once\\override} is needed for every invocation!
 
 * Set the dimensions of the additional text to 0 (using
 Drawback: @code{\\once\\override} is needed for every invocation!
 
 * Set the dimensions of the additional text to 0 (using
-@code{#:with-dimensions '(0 . 0) '(0 . 0)}). Drawback: To lilypond
-\"sempre\" has no extent, so it might put other stuff there and create
-collisions (which are not detected by the collision dection!). Also,
+@code{#:with-dimensions '(0 . 0) '(0 . 0)}). Drawback: To LilyPond
+@qq{sempre} has no extent, so it might put other stuff there and create
+collisions (which are not detected by the collision detection!). Also,
 there seems to be some spacing, so it's not exactly the same alignment
 as without the additional text
 
 there seems to be some spacing, so it's not exactly the same alignment
 as without the additional text
 
@@ -45,9 +49,10 @@ not at the center of pp.
 
 
 "
 
 
 "
-  doctitle = "Horizontally aligning custom dynamics (e.g. \"sempre pp\", \"piu f\", \"subito p\")"
+  doctitle = "Horizontally aligning custom dynamics (e.g. \"sempre pp\" \"piu f\" \"subito p\")"
 } % begin verbatim
 
 } % begin verbatim
 
+
 \header { title = "Horizontally aligning custom dynamics" }
 
 \paper { ragged-right = ##f }
 \header { title = "Horizontally aligning custom dynamics" }
 
 \paper { ragged-right = ##f }
@@ -63,9 +68,9 @@ semppMarkup = \markup { \halign #1.4 \italic "sempre" \dynamic "pp" }
 semppK =
 #(make-dynamic-script
   (markup #:line
 semppK =
 #(make-dynamic-script
   (markup #:line
-         (#:normal-text
-          #:italic "sempre"
-          #:dynamic "pp")))
+          (#:normal-text
+           #:italic "sempre"
+           #:dynamic "pp")))
 
 % Solution 3: Padding the dynamic script so the center-alignment
 %             puts it at the correct position
 
 % Solution 3: Padding the dynamic script so the center-alignment
 %             puts it at the correct position
@@ -73,10 +78,10 @@ semppK =
 semppT =
 #(make-dynamic-script
   (markup #:line
 semppT =
 #(make-dynamic-script
   (markup #:line
-         (#:normal-text
-          #:italic "sempre"
-          #:dynamic "pp"
-          #:hspace 7.1)))
+          (#:normal-text
+           #:italic "sempre"
+           #:dynamic "pp"
+           #:hspace 7.1)))
 
 % Solution 4: Dynamic, setting the dimensions of the additional text to 0
 % Drawback: To lilypond "sempre" has no extent, so it might put
 
 % Solution 4: Dynamic, setting the dimensions of the additional text to 0
 % Drawback: To lilypond "sempre" has no extent, so it might put
@@ -85,26 +90,37 @@ semppT =
 %           same alignment as without the additional text
 semppM =
 #(make-dynamic-script
 %           same alignment as without the additional text
 semppM =
 #(make-dynamic-script
-  (markup #:line (#:with-dimensions '(0 . 0) '(0 . 0)
-   #:right-align #:normal-text #:italic "sempre" #:dynamic "pp")))
+  (markup #:line
+          (#:with-dimensions '(0 . 0) '(0 . 0)
+                             #:right-align
+                             #:normal-text
+                             #:italic "sempre"
+                             #:dynamic "pp")))
 
 % Solution 5: Dynamic with explicit shifting inside the scheme function
 semppG =
 #(make-dynamic-script
 
 % Solution 5: Dynamic with explicit shifting inside the scheme function
 semppG =
 #(make-dynamic-script
-  (markup
-    #:hspace 0 #:translate '(-18.85 . 0)
-    #:line( #:normal-text #:italic "sempre" #:dynamic "pp")))
-
-% Solution 6: Dynamic with explicit alignment. This has only effect, if one sets X-offset!
+  (markup #:hspace 0
+          #:translate '(-18.85 . 0)
+          #:line (#:normal-text
+                  #:italic "sempre"
+                  #:dynamic "pp")))
+
+% Solution 6: Dynamic with explicit alignment. This has only effect
+%             if one sets X-offset!
 % Drawback: One needs to set DynamicText #'X-offset!
 % Drawback: One needs to set DynamicText #'X-offset!
-% Drawback: Aligned at the right edge of the additional text, not at the center of pp
+% Drawback: Aligned at the right edge of the additional text,
+%           not at the center of pp
 semppMII =
 semppMII =
-#(make-dynamic-script (markup #:line(#:right-align 
-  #:normal-text #:italic "sempre" #:dynamic "pp")))
+#(make-dynamic-script
+  (markup #:line (#:right-align
+                  #:normal-text
+                  #:italic "sempre"
+                  #:dynamic "pp")))
 
 \context StaffGroup <<
   \context Staff = "s" <<
 
 \context StaffGroup <<
   \context Staff = "s" <<
-    \set Staff.instrumentName = "Normal"
+    \set Staff.instrumentName = #"Normal"
     \relative c'' {
       \key es \major
       c4\pp c\p c c | c\ff c c\pp c
     \relative c'' {
       \key es \major
       c4\pp c\p c c | c\ff c c\pp c
@@ -121,10 +137,10 @@ semppMII =
     \set Staff.instrumentName = \markup \column { Explicit shifting }
     \relative c'' {
       \key es \major
     \set Staff.instrumentName = \markup \column { Explicit shifting }
     \relative c'' {
       \key es \major
-      \once \override DynamicText #'X-offset = #-9.2
+      \once \override DynamicText.X-offset = #-9.2
       c4\semppK c\p c c
       c4\ff c
       c4\semppK c\p c c
       c4\ff c
-      \once \override DynamicText #'X-offset = #-9.2
+      \once \override DynamicText.X-offset = #-9.2
       c4\semppK c
     }
   >>
       c4\semppK c
     }
   >>
@@ -154,7 +170,7 @@ semppMII =
     \relative c'' {
       \key es \major
       % Setting to ##f (false) gives the same result
     \relative c'' {
       \key es \major
       % Setting to ##f (false) gives the same result
-      \override DynamicText #'X-offset = #0
+      \override DynamicText.X-offset = #0
       c4\semppMII c\p c c | c\ff c c\semppMII c
     }
   >>
       c4\semppMII c\p c c | c\ff c c\semppMII c
     }
   >>