Belle Nuit Montage
PS:State Machine
TinyPS Editor
Render
% label x y /state { gsave translate 0 0 30 0 360 arc stroke dup stringwidth pop 2 div neg -3 moveto show grestore } def /atartstate { gsave translate 0 0 30 0 360 arc stroke 0 0 25 0 360 arc stroke dup stringwidth pop 2 div neg -3 moveto show grestore } def % label x1 y1 x2 y2 /path { gsave /y2 exch def /x2 exch def /y1 exch def /x1 exch def /label exch def /a y2 y1 sub x2 x1 sub atan def % line x1 a cos 30 mul add y1 a sin 30 mul add moveto x2 a cos 30 mul sub y2 a sin 30 mul sub lineto stroke % arrows x2 a cos 30 mul sub y2 a sin 30 mul sub moveto a 150 add cos 10 mul a 150 add sin 10 mul rlineto stroke x2 a cos 30 mul sub y2 a sin 30 mul sub moveto a -150 add cos 10 mul a -150 add sin 10 mul rlineto stroke % label x1 a cos 40 mul add 3 sub y1 a sin 40 mul add 2 sub moveto label stringwidth pop 3 add 0 rlineto 0 12 rlineto label stringwidth pop 3 add neg 0 rlineto 0 -12 rlineto 0.8 setgray fill x1 a cos 40 mul add y1 a sin 40 mul add moveto 0 setgray label show grestore } def % label x1 y1 x2 y2 x3 y3 x4 y4 /path2 { gsave /y4 exch def /x4 exch def /y3 exch def /x3 exch def /y2 exch def /x2 exch def /y1 exch def /x1 exch def /label exch def % line /a1 y2 y1 sub x2 x1 sub atan def /a4 y4 y3 sub x4 x3 sub atan def x1 a1 cos 30 mul add y1 a1 sin 30 mul add moveto x2 y2 lineto x2 a1 cos 50 mul add y2 a1 sin 50 mul add x3 a4 cos 50 mul sub y3 a4 sin 50 mul sub x3 y3 curveto x4 a4 cos 30 mul sub y4 a4 sin 30 mul sub lineto stroke % arrows x4 a4 cos 30 mul sub y4 a4 sin 30 mul sub moveto a4 150 add cos 10 mul a4 150 add sin 10 mul rlineto stroke x4 a4 cos 30 mul sub y4 a4 sin 30 mul sub moveto a4 -150 add cos 10 mul a4 -150 add sin 10 mul rlineto stroke % label x1 a1 cos 50 mul add 3 sub y1 a1 sin 50 mul add 2 sub moveto label stringwidth pop 3 add 0 rlineto 0 12 rlineto label stringwidth pop 3 add neg 0 rlineto 0 -12 rlineto 0.8 setgray fill x1 a1 cos 50 mul add y1 a1 sin 50 mul add moveto 0 setgray label show grestore } def /Helvetica findfont 12 scalefont setfont (start) 100 200 atartstate (number) 200 300 state (fraction) 200 400 state (operator) 200 100 state (0-9-) 100 200 200 300 path (0-9) 200 300 255 275 250 325 200 300 path2 (.) 200 300 200 400 path (space) 200 300 150 325 100 250 100 200 path2 (0-9) 200 400 255 375 250 425 200 400 path2 (space) 200 400 150 425 75 250 100 200 path2 (a-z) 100 200 200 100 path (a-z0-9) 200 100 255 75 250 125 200 100 path2 (space) 200 100 150 75 100 150 100 200 path2 showpage
My Journey to PostScript
≡
Home
Deutsch
English
Français
Login
English
Deutsch
English
Français
Login
Login