Debian Codegraph @

texk/dvipsk/crop.lpro

raw
1 %!
2 % This file is for crop marks. This file is public domain.
3 %
4 % First, we translate and draw the marks. You can change the way the
5 % marks are drawn, but the quarter inch border around the page is fixed.
6 %
7 % This file uses bop-hook; sorry.
8 %
9 TeXDict begin
10 %
11 /cX 18 def % the crop offset
12 /CM { % draw a crop mark; just a cross.
13 gsave TR 0 cX neg moveto 0 cX lineto stroke
14 cX neg 0 moveto cX 0 lineto stroke grestore
15 } def
16 %
17 end
18 %
19 /bop-hook {
20 cX dup TR % move the origin a bit
21 gsave .3 setlinewidth 0 0 CM % now draw four crop marks
22 vsize cX 2 mul sub dup hsize cX 2 mul sub dup
23 isls { 4 2 roll } if 0 CM exch CM 0 exch CM grestore
24 0 cX -2 mul TR % now move to where we start drawing
25 isls { cX -2 mul 0 TR } if
26 } def