1 %!PS-Adobe-1.0: lily.ps
3 % 2 setlanguagelevel % hmm. auto_resize_dicts doesn't help either.
7 % scm/lily.scm should allow blank lines, now
9 /draw_beam % width slope thick
11 2 div /beam_thick exch def
14 beam_slope beam_wd mul /beam_ht exch def
15 0 beam_thick neg moveto
16 beam_wd beam_ht rlineto
17 0 beam_thick 2 mul rlineto
22 /draw_decrescendo % width height cons thick
29 cresc_wd cresc_cont moveto
32 cresc_wd cresc_cont neg moveto
37 /draw_crescendo % width height cons thick
45 cresc_wd cresc_ht lineto
47 0 cresc_cont neg moveto
48 cresc_wd cresc_ht neg lineto
54 1 copy mul exch 1 copy mul add sqrt
57 /draw_tuplet % height gap dx dy thick dir
59 % urg: the only Level-2 PS, check effect in print
60 % true setstrokeadjust
69 tuplet_dy tuplet_dx div tuplet_gapx mul /tuplet_gapy exch def
73 0 tuplet_h dir mul lineto
74 tuplet_dx tuplet_gapx sub 2 div
75 tuplet_dy tuplet_gapy sub 2 div tuplet_h dir mul add lineto
76 tuplet_dx tuplet_gapx add 2 div
77 tuplet_dy tuplet_gapy add 2 div tuplet_h dir mul add moveto
78 tuplet_dx tuplet_dy tuplet_h dir mul add lineto
79 tuplet_dx tuplet_dy lineto
83 /draw_volta % h w thick vert_start vert_end
90 % urg: the only Level-2 PS, check effect in print
91 % true setstrokeadjust
99 volta_w volta_h lineto
106 % this is for drawing slurs.
107 /draw_bezier_sandwich % thickness
137 /traject_alpha exch def
138 traject_ds traject_alpha sin mul add
140 traject_ds traject_alpha cos mul add
151 arch_thick arch_height add half_height bracket_thick sub arch_width add
152 arch_angle arch_height -0.15 mul bracket_traject
155 0 arch_height 0.5 mul bracket_traject
159 arch_thick half_height bracket_thick sub
160 0 arch_height 0.4 mul bracket_traject
162 arch_thick arch_height add half_height bracket_thick sub arch_width add
163 arch_angle arch_height -0.25 mul bracket_traject
165 arch_thick arch_height add half_height bracket_thick sub arch_width add
167 arch_thick half_height bracket_thick sub
186 /draw_bracket % arch_angle arch_width arch_height bracket_width bracket_height arch_thick bracket_thick
189 /bracket_thick exch def
191 /bracket_height exch def
192 /bracket_width exch def
193 /arch_height exch def
197 bracket_height 2 div arch_thick add /half_height exch def
198 % urg: the only Level-2 PS, check effect in print
199 % true setstrokeadjust