]> matita.cs.unibo.it Git - helm.git/blob - helm/papers/calculemus-2003/stamp.pro
ocaml 3.09 transition
[helm.git] / helm / papers / calculemus-2003 / stamp.pro
1 %!
2 % stamp.pro
3 % Put a stamp onto upper left corner of the page.
4 %
5 % $Log$
6 % Revision 1.1  2003/05/22 16:05:12  sacerdot
7 % ed and draftstamp packages committed and activated
8 %
9 % Revision 1.1  2002/10/21 14:41:51  kohlhase
10 % more restructuring of definitions
11 %
12 % Revision 1.1  1999/04/28 16:23:03  kohlhase
13 % bla
14 %
15 % Revision 1.1  1998/09/29 07:32:03  kohlhase
16 % *** empty log message ***
17 %
18 % Revision 1.1  1998/01/05 10:53:58  mmueller
19 % blurb
20 %
21 % Revision 1.1  1997/03/18 18:14:22  tmueller
22 % starting ilps version of cpi paper
23 %
24 % Revision 1.1  91/02/17  01:51:12  schwarze
25 % Initial revision
26
27
28 /inch { 72 mul } def
29 /mm { inch 25.4 div } def
30
31 /StampText (Draft) def
32 %/StampDate (12.01.91) def
33
34 /StampSize 24 def
35 /StampFont /Helvetica-Bold findfont StampSize scalefont def
36 /DateSize 10 def
37 /DateFont /Helvetica-Bold findfont DateSize scalefont def
38 /Gray .5 def
39 /LMargin 10 mm def
40 /TMargin 10 mm def
41 %/PaperHeight 297 mm def
42 /PaperHeight 280 mm def
43 /Angle 30 def
44
45 /Randomize { rand 2147483647 div .6 mul .7 add mul cvi } def 
46
47 /bop-hook {
48     gsave
49
50     /TheAngle Angle Randomize def
51     /TheLMargin LMargin Randomize def 
52     /TheTMargin TMargin Randomize def 
53
54     StampFont setfont
55     /StampWidth StampText stringwidth pop def
56
57     TheLMargin StampSize TheAngle sin mul add % x
58     PaperHeight TheTMargin sub StampWidth TheAngle sin mul sub 
59     StampSize TheAngle cos mul sub % y
60
61     translate
62     TheAngle rotate
63     Gray setgray
64     0 0 moveto StampText show
65
66     userdict /StampDate known { 
67         DateFont setfont
68         StampDate stringwidth pop 
69         StampWidth exch sub 2 div DateSize -1.2 mul moveto
70         StampDate show
71     } if
72
73     StampWidth 2 div dup StampSize 0.2 mul translate
74
75     1.35 mul dup StampSize 1.35 mul scale
76     newpath 1 exch div setlinewidth 0 0 1 0 360 arc stroke
77
78     grestore
79 } def
80
81 %bop-hook
82 %showpage