]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/dynamics-text-spanner-postfix.ly
Merge branch 'lilypond/translation' of ssh://jomand@git.sv.gnu.org/srv/git/lilypond
[lilypond.git] / Documentation / snippets / dynamics-text-spanner-postfix.ly
1 % Do not edit this file; it is automatically
2 % generated from Documentation/snippets/new
3 % This file is in the public domain.
4 %% Note: this file works from version 2.13.4
5 \version "2.13.4"
6
7 \header {
8   lsrtags = "expressive-marks, tweaks-and-overrides"
9   texidoc = "The \cresc, \dim and \decresc spanners can now be redefined as
10 postfix operators and produce one text spanner.  Defining custom spanners is
11 also easy.  Hairpin and text crescendi can be easily mixed. \< and \> produce
12 hairpins by default, \cresc etc. produce text spanners by default.
13 "
14   doctitle = "Dynamics text spanner postfix"
15 } % begin verbatim
16
17
18 % Some sample text dynamic spanners, to be used as postfix operators
19 crpoco = #(make-music 'CrescendoEvent 'span-direction START
20                       'span-type 'text 'span-text "cresc. poco a poco")
21 % Redefine the existing \cresc, \dim and \decresc commands to use postfix syntax
22 cresc = #(make-music 'CrescendoEvent 'span-direction START
23                      'span-type 'text 'span-text "cresc.")
24 dim = #(make-music 'DecrescendoEvent 'span-direction START
25                    'span-type 'text 'span-text "dim.")
26 decresc = #(make-music 'DecrescendoEvent 'span-direction START
27                        'span-type 'text 'span-text "decresc.")
28
29 \relative c' {
30   c4\cresc d4 e4 f4 |
31   g4 a4\! b4\crpoco c4 |
32   c4 d4 e4 f4 |
33   g4 a4\! b4\< c4 |
34   g4\dim a4 b4\decresc c4\!
35 }