]> git.donarmstrong.com Git - lilypond.git/blob - mf/feta-beugel.mf
release: 1.1.9
[lilypond.git] / mf / feta-beugel.mf
1 input feta-macros;
2 input feta-params;
3
4 save code;
5 code :=0;
6
7
8 def draw_brace( expr height_sharp, width_sharp) = 
9         save pendir, height, width, thin, thick;
10         save penangle;
11         height# := height_sharp;
12         width#  := width_sharp;
13
14         beginchar(incr code, width#, height#/2, height#/2);
15  
16         define_pixels (height, width);
17         thin = 2 stafflinethickness;
18         thick = .5 interline;
19         
20         z2 = .5 [z1, z3];
21         y3 = y1 + height/2;
22         x3 = x1 + width;
23         y1 =0;
24         x3 = - width / 2;
25
26         pair pendir;
27         pendir = unitvector(x3 - x1, y3/6 - y1);
28         penangle = angle pendir - 90;
29         penpos3(thin, penangle);
30         penpos2(thick, angle(z3 -z1) -90 );
31         penpos1(2/3 thin, penangle);
32         
33         penlabels(1,2,3);
34         fill z2r ..  simple_serif (z3r, z3l, 90)
35                 .. z2l .. simple_serif (z1l, z1r, 90) ..cycle;
36
37         addto currentpicture also currentpicture yscaled -1;
38 endchar;
39 enddef;
40
41
42 for h :=  2 staffsize#  step 1 pt# until (7 * staffsize#):
43         draw_brace(h, interline# );
44 endfor