/usr/share/doc/pmw/contrib/Brackets is in pmw-doc 1:4.27-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | @ Drawing procedure for bracketing a note or a chord.
@ The brackets increase their curvature and thickness in the middle
@ in proportion to the note they surround.
@ Contributed by Richard Hallas, January 1993.
@ Square brackets and RH and LH brackets contributed by Richard
@ Hallas, October 1994.
@ Minor correction from Richard Hallas incorporated March 1995
Draw Bracket
@ Square left-bracket enclosing note or chord
@
-1 headleft sub accleft sub headbottom linebottom add moveto
-2 0 rlineto
-3 headleft sub accleft sub headtop linetop sub lineto
2 0 rlineto
0.5 setlinewidth stroke
Enddraw
Draw Rightbracket
@ Square right-bracket enclosing note or chord
@
1 headright add headbottom linebottom add moveto
2 0 rlineto
3 headright add headtop linetop sub lineto
-2 0 rlineto
0.5 setlinewidth stroke
Enddraw
Draw Notebracket
@ Pair of round parentheses enclosing note or chord
@ Width in the centre auto-adjusts according to size of bracket
@
@ Left bracket (inside):
-1 headleft sub accleft sub stembottom 1 sub moveto @ Bottom
-1 headleft sub accleft sub stemtop stembottom sub 8 div 1 add sub stembottom stemtop stembottom sub 4 div add @ bezier point 1 (lower)
-1 headleft sub accleft sub stemtop stembottom sub 8 div 1 add sub stemtop stemtop stembottom sub 4 div sub @ bezier point 2 (upper)
-1 headleft sub accleft sub stemtop 1 add curveto @ Top
@ Left bracket (outside):
-1 headleft sub accleft sub stemtop stembottom sub 8 div dup 2 1 roll 0.25 mul 1.5 add add sub stemtop stemtop stembottom sub 4 div sub @ bezier point 1 (upper)
-1 headleft sub accleft sub stemtop stembottom sub 8 div dup 2 1 roll 0.25 mul 1.5 add add sub stembottom stemtop stembottom sub 4 div add @ bezier point 2 (lower)
-1 headleft sub accleft sub stembottom 1 sub curveto @ Bottom
0.5 setlinewidth fill @ Left bracket complete
@
@ Right bracket (inside):
1 headright add stembottom 1 sub moveto @ Bottom
1 headright add stemtop stembottom sub 8 div 1 add add stembottom stemtop stembottom sub 4 div add @ bezier point 1 (lower)
1 headright add stemtop stembottom sub 8 div 1 add add stemtop stemtop stembottom sub 4 div sub @ bezier point 2 (upper)
1 headright add stemtop 1 add curveto @ Top
@ Right bracket (outside):
1 headright add stemtop stembottom sub 8 div dup 2 1 roll 0.25 mul 1.5 add add add stemtop stemtop stembottom sub 4 div sub @ bezier point 1 (upper)
1 headright add stemtop stembottom sub 8 div dup 2 1 roll 0.25 mul 1.5 add add add stembottom stemtop stembottom sub 4 div add @ bezier point 2 (lower)
1 headright add stembottom 1 sub curveto @ Bottom
0.5 setlinewidth fill @ Right bracket complete
Enddraw
Draw RHbracket
@ Square left-bracket with jog at bottom only, for piano RH on lower stave
@ Requires one argument to specify length of main part of bracket
@
-1 headleft sub accleft sub headbottom linebottom add moveto
-2 0 rlineto
0 exch rlineto
0.5 setlinewidth stroke
Enddraw
Draw LHbracket
@ Square left-bracket with jog at top only, for piano LH on upper stave
@ Requires one argument to specify length of main part of bracket
@
-1 headleft sub accleft sub headtop linetop sub moveto
-2 0 rlineto
0 exch sub 0 exch rlineto
0.5 setlinewidth stroke
Enddraw
|