home *** CD-ROM | disk | FTP | other *** search
- %
- % Standard prolog file for BengtPS
- % Copyright (C) Bengt Computer Graphics 1996
- %
- initmatrix
- /bd {bind def} bind def
- /run {(r) file cvx exec} bd
-
- % System operators which may be needed
- true setglobal
- systemdict begin
-
- % Font and Encoding stuff --
- /findencoding { /Encoding findresource } bd
- /findfont { /Font findresource } bd
- /definefont { /Font defineresource } bd
- /undefinefont { /Font undefineresource } bd
- /packedarray { array astore } bd
-
- % bind the system FontDirectory and GlobalFontDirectory to the
- % global font resource instance dictionary
- /Font /Category findresource
- dup /GlobalResInstances get /GlobalFontDirectory exch def
- /GlobalResInstances get /SharedFontDirectory exch def
-
- % Names which many programs depend on (but really shouldn't be there)
- %
- /letter {<</PageSize [612 792]>> setpagedevice } bd
- /legal { <</PageSize [612 1008]>> setpagedevice } bd
- /b5 { <</PageSize [516 729]>> setpagedevice } bd
- /a4 { <</PageSize [595 842]>> setpagedevice } bd
- /legalsmall /legal load def
- /lettersmall /letter load def
- /a4small /a4 load def
-
- /setjobtimeout /pop load def
- /_tmpstring 300 string def % temporary string
- % Adobe uses these in its error processing
- /=string _tmpstring def
- /=print /=only load def
- /framedevice {} def
- currentdict readonly
- pop
- end
-
- % Build a status dictionary
- false setglobal
- statusdict begin
- /checkpassword { 0 eq } bd
- /jobname (dummy.ps) def
- /lettertray {} def
- end
- true setglobal
-
- % Build a server dictionary
- /serverdict 6 dict def
- serverdict begin
- /execjob {} def
- /exitserver {clear cleardictstack} bd
- /setrealdevice {} def
- end
- false setglobal
-
- /showdict {{== == (\n) print} forall} bd
-
- %-Open standard files
- /.stdin (%stdin)(r)file def
- /.stdout (%stdout)(w)file def
- /.stderr (%stderr)(w)file def
-
- %-Load default color rendering dict
- /DefaultColorRendering /ColorRendering findresource setcolorrendering
-
- /prompt {
- (P) print count 0 ne {(<) print count print} if (>) print flush
- } bd
-
- /executive {
- /.stdin (%stdin) (r) file def
- product print ( Executive Version ) print version print (\n\n) print
- false _trace
- { prompt (%statementedit) (r) file
- dup bytesavailable 0 lt
- { .stdin bytesavailable 0 lt {closefile exit} if }
- if cvx stopped { handleerror } if
- } loop (\n) print
- } bd
-
- %
- % This proc is required by the api - don't delete it
- /_execprocstopped {
- _execfilestopped {handleerror _die} if
- } bd
-
- <1b> cvn { } def % MS Windows LaserJet 4 prologue
- /@PJL { % H-P job control
- currentfile //_tmpstring readline { pop } if
- } bd
-
- % This makes the interpreter think we have a bunch of memory free as it is hard
- % to tell under Windows how much we can actually get at any one time
- /vmstatus {vmstatus pop pop 0 2000000000} bind def
-