]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/dynamics-custom-text-spanner-postfix.ly
Add '-dcrop' option to ps and svg backends
[lilypond.git] / Documentation / snippets / dynamics-custom-text-spanner-postfix.ly
1 %% DO NOT EDIT this file manually; it is automatically
2 %% generated from LSR http://lsr.di.unimi.it
3 %% Make any changes in LSR itself, or in Documentation/snippets/new/ ,
4 %% and then run scripts/auxiliar/makelsr.py
5 %%
6 %% This file is in the public domain.
7 \version "2.19.22"
8
9 \header {
10   lsrtags = "expressive-marks, tweaks-and-overrides"
11
12   texidoc = "
13 Postfix functions for custom crescendo text spanners.  The spanners
14 should start on the first note of the measure.  One has to use
15 -\\mycresc, otherwise the spanner start will rather be assigned to the
16 next note.
17
18 "
19   doctitle = "Dynamics custom text spanner postfix"
20 } % begin verbatim
21
22 % Two functions for (de)crescendo spanners where you can explicitly give the
23 % spanner text.
24 mycresc =
25 #(define-music-function (mymarkup) (markup?)
26    (make-music 'CrescendoEvent
27                'span-direction START
28                'span-type 'text
29                'span-text mymarkup))
30 mydecresc =
31 #(define-music-function (mymarkup) (markup?)
32    (make-music 'DecrescendoEvent
33                'span-direction START
34                'span-type 'text
35                'span-text mymarkup))
36
37 \relative c' {
38   c4-\mycresc "custom cresc" c4 c4 c4 |
39   c4 c4 c4 c4 |
40   c4-\mydecresc "custom decresc" c4 c4 c4 |
41   c4 c4\! c4 c4
42 }