]> git.donarmstrong.com Git - lilypond.git/blob - input/regression/beam-quant-standard.ly
4bf8cdfda79c6722e575a20333b1470fa443e3f5
[lilypond.git] / input / regression / beam-quant-standard.ly
1 \header {
2
3     texidoc = "This file tests a few standard beam quants."
4     
5 }
6
7
8 %
9 % todo: make the check-quant function throw an error for incorrect quants
10 %
11
12 \paper  { raggedright = ##t }
13
14
15
16 % #(ly:set-option 'debug-beam #t)
17
18 assertquant =
19 #(def-music-function (location l r) (pair? pair?)
20   (let* ((f (check-quant-callbacks l r)))
21    
22    #{
23    \override Beam #'position-callbacks = $f
24    #}
25    
26 ))
27   
28
29 \relative {
30     \assertquant #'(1 . 0)  #'(1 . 0)
31     e8[ e]
32     e4 
33     e4 
34     \assertquant #'(2 . -1)  #'(2 . -1)
35     f8[ f]
36     e4 
37     e4 
38     \assertquant #'(2 . 0)  #'(2 . 0)
39     g8[ g]
40     e4 
41     e4 
42     \assertquant #'(2 . 1)  #'(2 . 1)
43     a8[ a]
44     e4 e4 e4
45     \once \override Beam #'inspect-quants = #'(2.2 . 2.2)
46     a8[ a]
47     e4 
48     e4 
49
50     \assertquant #'(0 . 1)  #'(1 . 0)
51     d8[ e]
52     e4 
53     e4 
54     \assertquant #'(1 . 0)  #'(1 . 1)
55     e8[ f]
56     e4 
57     e4 
58     \assertquant #'(2 . -1)  #'(2 . 0)
59     f8[ g]
60     e4 
61     e4 
62     \assertquant #'(2 . 0)  #'(2 . 1)
63     g8[ a]
64     e4 
65     e4 
66     }