]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/broken-crescendo-hairpin.ly
Doc-es: Oops; fix bad xref.
[lilypond.git] / Documentation / snippets / broken-crescendo-hairpin.ly
1 % DO NOT EDIT this file manually; it is automatically
2 % generated from Documentation/snippets/new
3 % Make any changes in Documentation/snippets/new/
4 % and then run scripts/auxiliar/makelsr.py
5 %
6 % This file is in the public domain.
7 %% Note: this file works from version 2.17.27
8 \version "2.17.27"
9
10 \header {
11   lsrtags = "contemporary-notation, expressive-marks, symbols-and-glyphs"
12
13   texidoc = "
14 In order to make parts of a crescendo hairpin invisible, the following
15 method is used: A white rectangle is drawn on top of the respective
16 part of the crescendo hairpin, making it invisible.
17
18 The markup command @code{with-dimensions} tells LilyPond to consider only
19 the bottom edge of the rectangle when spacing it against the hairpin.
20 The property @code{staff-padding} prevents the rectangle from fitting
21 between the hairpin and staff.
22
23 Make sure to put the hairpin in a lower layer than the text markup to
24 draw the rectangle over the hairpin.
25
26 "
27   doctitle = "Broken Crescendo Hairpin"
28 } % begin verbatim
29
30
31 \relative c' {
32   <<
33     {
34       \dynamicUp
35       r2 r16 c'8.\pp r4
36     }
37     \\
38     {
39       \override DynamicLineSpanner.layer = #0
40       des,2\mf\< ~
41       \override TextScript.layer = #2
42       \once\override TextScript.staff-padding = #6
43       \once\override TextScript.vertical-skylines = #'()
44       des16_\markup \with-dimensions #'(2 . 7) #'(0 . 0)
45                     \with-color #white
46                     \filled-box #'(2 . 7) #'(0 . 2) #0
47       r8. des4 ~ des16->\sff
48     }
49   >>
50 }