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 controls
120 /draw_dashed_line % dash thickness width
131 /draw_dashed_slur % dash thickness controls
148 /traject_alpha exch def
149 traject_ds traject_alpha sin mul add
151 traject_ds traject_alpha cos mul add
162 bracket_thick arch_height add half_height arch_thick sub arch_width add
163 arch_angle arch_height -0.15 mul bracket_traject
166 0 arch_height 0.5 mul bracket_traject
170 bracket_thick half_height arch_thick sub
171 0 arch_height 0.4 mul bracket_traject
173 bracket_thick arch_height add half_height arch_thick sub arch_width add
174 arch_angle arch_height -0.25 mul bracket_traject
176 bracket_thick arch_height add half_height arch_thick sub arch_width add
178 bracket_thick half_height arch_thick sub
197 /draw_bracket % arch_angle arch_width arch_height bracket_width bracket_height arch_thick bracket_thick
200 /bracket_thick exch def
202 /bracket_height exch def
203 /bracket_width exch def
204 /arch_height exch def
208 bracket_height 2 div bracket_thick add /half_height exch def
209 % urg: the only Level-2 PS, check effect in print
210 % true setstrokeadjust