X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=Documentation%2Fsnippets%2Fcreating-real-parenthesized-dynamics.ly;h=5fbbe1f34f958566b46d3c9b1fa8f03097fd4318;hb=958e95822083954cad00e0a598eb9f12ceba67b9;hp=34361c8067ca539357535d8f4220beefc9babb9b;hpb=1efdabf3b2349ea7fa3183dca5bba5104c347c36;p=lilypond.git diff --git a/Documentation/snippets/creating-real-parenthesized-dynamics.ly b/Documentation/snippets/creating-real-parenthesized-dynamics.ly index 34361c8067..5fbbe1f34f 100644 --- a/Documentation/snippets/creating-real-parenthesized-dynamics.ly +++ b/Documentation/snippets/creating-real-parenthesized-dynamics.ly @@ -1,29 +1,13 @@ -%% Do not edit this file; it is automatically -%% generated from LSR http://lsr.dsi.unimi.it +%% DO NOT EDIT this file manually; it is automatically +%% generated from LSR http://lsr.di.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.13.4" +\version "2.19.22" \header { - lsrtags = "expressive-marks, text" - -%% Translation of GIT committish: b2d4318d6c53df8469dfa4da09b27c15a374d0ca - texidoces = " -Aunque la manera más fácil de añadir paréntesis a una indicación -de dinámica es utilizar un bloque @code{\\markup}, este método -tiene un inconveniente: los objetos que se crean se comportarán -como elementos de marcado de texto y no como indicaciones -dinámicas. - -Sin embargo, es posible crear un objeto similar utilizando el -código de Scheme equivalente (como se explica en \"Interfaz del -programador de elementos de marcado\"), en combinación con la -función @code{make-dynamic-script}. De esta forma, el elemento de -marcado se tratará como una indicación dinámica, y por tanto -seguirá siendo compatible con instrucciones como -@code{\\dynamicUp} o @code{\\dynamicDown}. - -" - doctitlees = "Crear indicaciones dinámicas \"verdaderas\" entre paréntesis" + lsrtags = "expressive-marks, text, workaround" texidoc = " Although the easiest way to add parentheses to a dynamic mark is to use @@ -42,11 +26,16 @@ commands such as @code{\\dynamicUp} or @code{\\dynamicDown}. doctitle = "Creating \"real\" parenthesized dynamics" } % begin verbatim -parenF = #(make-dynamic-script (markup #:line (#:normal-text #:italic - #:fontsize 2 "(" #:hspace -0.8 #:dynamic "f" #:normal-text - #:italic #:fontsize 2 ")"))) +paren = +#(define-event-function (dyn) (ly:event?) + (make-dynamic-script + #{ \markup \concat { + \normal-text \italic \fontsize #2 ( + \pad-x #0.2 #(ly:music-property dyn 'text) + \normal-text \italic \fontsize #2 ) + } + #})) \relative c'' { - c4\parenF c c \dynamicUp c\parenF + c4\paren\f c c \dynamicUp c\paren\p } -