]> git.donarmstrong.com Git - lilypond.git/blob - input/regression/flags-default.ly
Change flag creation to use the 'flag prop (function returning the stencil)
[lilypond.git] / input / regression / flags-default.ly
1 \version "2.11.57"
2
3 \header {
4   texidoc = "Default flag styles: '(), 'mensural and 'no-flag.
5   Compare all three methods to print them (C++ default implementation, 
6   Scheme implementation using the 'flag-style grob property and 
7   setting the 'flag property explicitly to the desired Scheme function.
8   All three lines should be absolutely identical."
9 }
10
11
12 % test notes, which will be shown in different style:
13 testnotes = { \autoBeamOff c'8 d'16 c'32 d'64 \acciaccatura {c'8} d'64 c''8 d''16 c''32 d''64 \acciaccatura {c''8} d''64  }
14
15 {
16   \override Score.RehearsalMark #'self-alignment-X = #LEFT
17   \time 2/4
18   s2 \break
19
20   % Old settings: default, 'mensural, 'no-flag
21   \mark "Default flags (C++)"
22   \testnotes
23
24   \mark "Symbol: 'mensural (C++)"
25   \override Stem #'flag-style = #'mensural
26   \testnotes
27
28   \mark "Symbol: 'no-flag (C++)"
29   \override Stem #'flag-style = #'no-flag
30   \testnotes
31
32   \break
33
34   % The same, but with the Scheme implementation of default-flag
35   \override Stem #'flag = #default-flag
36   \revert Stem #'flag-style
37   \mark "Default flags (Scheme)"
38   \testnotes
39
40   \mark "Symbol: 'mensural (Scheme)"
41   \override Stem #'flag-style = #'mensural
42   \testnotes
43
44   \mark "Symbol: 'no-flag (Scheme)"
45   \override Stem #'flag-style = #'no-flag
46   \testnotes
47
48   \break
49
50   % New settings: no settings, normal-flag, mensural-flag, no-flag
51   \mark "Function: normal-flag"
52   \override Stem #'flag = #normal-flag
53   \testnotes
54
55   \mark "Function: mensural-flag"
56   \override Stem #'flag = #mensural-flag
57   \testnotes
58
59   \mark "Function: no-flag"
60   \override Stem #'flag = #no-flag
61   \testnotes
62 }