%!PS-Adobe-3.0 % % CalComp PostScript Driver Procset % Copyright (c) 1997-1998 CalComp Technology Inc. % %%BeginResource: procset CCDict /CCDict 100 dict dup begin % Define these before any invoking CCSelectDeviceProc % Model, Source, OutputFormat, OutputMode, and ColorModel % are necessary for cdcl header and margins % Change the defaults as desired /CCDisplay false def % Internal variables /CCDevice (sakec) def /CCModelSeries (5500) def /CCPSLevel 2 def /CCXOffset 0 def /CCYOffset 0 def /CCRotate 0 def /CCOrientation 0 def /CCCutMedia (0) def /CCXRes 360 def /CCResolution [ 360 360 ] def /CCHWMargins [36 96 36 102] def % External variables /CCModel (5536) def /CCOrient (AUTO) def /CCMirror (NO,NO) def /CCScale (1/1,1/1) def /CCSource (ROLL) def /CCMediaSource () def /CCMediaType () def /CCInkType (1) def /CCOutputFile false def /CCOutputFormat (RS) def /CCOutputMode () def /CCColorModel (CMYK) def % Internal variables /CCExpand 0 def /CCTrans false def /CCTransverse false def /CCPageWidth 612 def /CCPageHeight 792 def /CCImageBottom 0 def /CCImageLeft 0 def /CCImageTop 792 def /CCImageRight 612 def /CCIImageBottom 0 def /CCIImageLeft 0 def /CCIImageTop 792 def /CCIImageRight 612 def /CCMarginBottom 96 def /CCMarginLeft 36 def /CCMarginTop 102 def /CCMarginRight 36 def /CCIMarginBottom 96 def /CCIMarginLeft 36 def /CCIMarginTop 102 def /CCIMarginRight 36 def /CCOutputSized false def /CCOutputScaled false def /CCOutputScaling 1.0 def /CCSymMargins false def % ColorMatch or Brightness, Contrast, and Dithering /CCColorMatch false def /CCBrightness 0.5 def /CCContrast 0.5 def /CCDithering (STOCHASTIC) def % Ordered Dithering /CCCAngl 75 def /CCCFreq 50 def /CCMAngl 105 def /CCMFreq 50 def /CCYAngl 0 def /CCYFreq 50 def /CCKAngl 45 def /CCKFreq 50 def /CCDot { dup mul exch dup mul add 1 exch sub } def %circ %/CCDot { 180 mul cos exch 180 mul cos add 2 div } def %euclidean circ %/CCDot { abs exch abs add 1 exch sub } def %diamond %/CCDot { add 2 div } def %triangle %/CCDot { add abs 1 exch sub } def %hexline %/CCDot { add abs 1 exch sub abs } def %diagline %/CCDot { pop } def %xline /CCQuitFlashProc { % - CCQuitFlashProc - userdict begin /quit { % Flush until EOF or userdict begin /FlushString 32768 string def { currentfile FlushString readline { dup length 0 gt { 0 get 4 eq { exit } if } { pop } ifelse } { pop exit } ifelse } loop end //quit } bind def end } def /CCMarginProc % - CCMarginProc - { statusdict begin /fSymmetricMargins CCSymMargins def end } def /CCAreaProc % - CCAreaProc - { CCDict begin CCOutputScaled not { /CCOutputScaled true def % Page and Image size CCOutputSized not { /CCOutputSized true def % pathbbox - note: transverse ps will return clipped area CCPSLevel 1 eq { newpath clippath pathbbox newpath } { currentpagedevice /PageOffset get aload pop currentpagedevice /PageSize get aload pop { currentpagedevice /Orientation get /CCOrientation exch def currentpagedevice /HWResolution get /CCResolution exch def } stopped pop } ifelse /CCImageTop exch def /CCImageRight exch def /CCImageBottom exch def /CCImageLeft exch def /CCPageHeight CCImageTop def /CCPageWidth CCImageRight def /CCIImageTop CCImageTop def /CCIImageRight CCImageRight def /CCIImageBottom CCImageBottom def /CCIImageLeft CCImageLeft def % CCTrans Transverse on roll if possible? CCSource (CUTSHEET) eq not CCTrans and CCOutputFormat (RS) eq CCPageHeight CCModel cvi 100 mod 72 mul lt and and { /CCTransverse true def } if % Cutsheet landscape % RS returns portrait PS returns landscape CCSource (CUTSHEET) eq CCOutputFormat (RS) eq CCPageWidth 720 lt and CCOutputFormat (PS) eq CCPageHeight 720 lt and or and CCModelSeries (5300) eq CCModelSeries (5400) eq or CCModelSeries (5600) eq or CCModelSeries (53412) eq or and CCTransverse or { /CCRotate -90 def } { /CCRotate 0 def } ifelse % Margins in Page coordinates for rasterizer, IMargins in Image coordinates CCHWMargins aload pop /CCMarginTop exch def /CCMarginRight exch def /CCMarginBottom exch def /CCMarginLeft exch def CCHWMargins aload pop CCRotate 0 eq {} { 4 1 roll } ifelse /CCIMarginTop exch def /CCIMarginRight exch def /CCIMarginBottom exch def /CCIMarginLeft exch def CCSource (CUTSHEET) eq CCOutputFormat (PS) eq and { % do nothing if letter is 612 792 CCImageLeft 1 lt { % do if letter is 612-72 792-198 /CCPageHeight CCPageHeight CCMarginBottom add CCMarginTop add def /CCPageWidth CCPageWidth CCMarginLeft add CCMarginRight add def } { % do if letter is 612-36 792-102 /CCPageHeight CCPageHeight CCMarginTop add def /CCPageWidth CCPageWidth CCMarginRight add def } ifelse CCRotate -90 eq { CCPageWidth CCPageHeight /CCPageWidth exch def /CCPageHeight exch def } if /CCIImageTop CCPageHeight CCIMarginTop sub def /CCIImageRight CCPageWidth CCIMarginRight sub def /CCIImageBottom CCIMarginBottom def /CCIImageLeft CCIMarginLeft def } if } if % CCOutputSized not % scale up but not down, reason? CCOutputScaling 1.0 gt { /CCPageHeight CCPageHeight CCOutputScaling mul def /CCPageWidth CCPageWidth CCOutputScaling mul def /CCIImageLeft CCIImageLeft CCOutputScaling mul def /CCIImageBottom CCIImageBottom CCOutputScaling mul def /CCIImageRight CCIImageRight CCOutputScaling mul def /CCIImageTop CCIImageTop CCOutputScaling mul def } if % Centered Scaling /CCXOffset 0 def /CCYOffset 0 def CCRotate -90 eq { /CCYOffset CCPageWidth def } if } if % CCOutputScaled not end % CCDict } def /CCScaleAreaProc % - CCScaleAreaProc - { CCDict begin CCAreaProc statusdict begin CCRotate 0 eq { CCPageWidth CCPageHeight 1 setpage } { CCDict /CCOrientation 1 put CCPageHeight CCPageWidth 1 setpage } ifelse end % statusdict end % CCDict } def /CCScaleImageProc % - CCScaleImageProc - { userdict begin /initmatrix { //initmatrix CCDict begin CCXOffset CCYOffset translate CCOutputScaling dup scale CCRotate rotate end } bind def /defaultmatrix {gsave initmatrix currentmatrix grestore} bind def /initgraphics {initgraphics initmatrix} bind def /showpage {showpage initmatrix} bind def end % userdict statusdict begin /setpagedevice {setpagedevice initmatrix} bind def %/setpage { //setpage exec initmatrix } bind def /setpage [ /setpage load /exec load /initmatrix load /exec load ] cvx bind def end % statusdict statusdict /.pagetypenames known { statusdict /.pagetypenames get userdict begin { dup load [ exch /exec load /initmatrix load /exec load ] cvx def } forall end % userdict } if initmatrix } def /CCDitherProc % - CCDitherProc - { { CCDict begin userdict begin { dup 1 ne { CCDict /CCBrightness get 2 mul 1 sub add dup 1 gt { pop 1 } if dup 0 lt { pop 0 } if } if dup 1 ne { CCDict /CCContrast get 90 mul dup sin exch cos div dup neg 1 add 2 div exch mul add } if dup 1 gt { pop 1 } if dup 0 lt { pop 0 } if } settransfer CCDithering (STOCHASTIC) eq { userdict dup /sethalftone { pop } bind put dup /setscreen { pop pop pop } bind put dup /setcolorscreen { pop pop pop pop pop pop pop pop pop pop pop pop } bind put } { CCPSLevel 2 eq { CCKFreq CCKAngl /CCDot load CCCFreq CCCAngl /CCDot load CCMFreq CCMAngl /CCDot load CCYFreq CCYAngl /CCDot load setcolorscreen } { CCKFreq CCKAngl /CCDot load setscreen } ifelse } ifelse end % userdict end % CCDict } stopped pop } def /CCSelectDeviceProc { CCDict begin % CCModel for selectdevice /CCCModelDict 25 dict dup begin /5300 (sakec) def /5500 (sakec) def /5600 (sakec) def /7000 (sakec) def /68400 (rf4044c) def end def /CCGModelDict 25 dict dup begin /5300 (sakemd) def /5400 (sakemd) def /5500 (sakemd) def /5600 (sakemd) def /7000 (sakemd) def /52400 (ccrf4636) def /52200 (ccrf2036) def /53300 (ccrf3036) def /53400 (ccrf4036) def /54400 (ccrf4036) def /67400 (ccrf4036) def /68400 (rf4044md) def /53412 (ecopro) def end def /CCBModelDict 25 dict dup begin /5300 (sakem) def /5400 (sakem) def /5500 (sakem) def /5600 (sakem) def /7000 (sakem) def /52400 (crfb4636) def /52200 (crfb2036) def /53300 (crfb3036) def /53400 (crfb4036) def /54400 (crfb4036) def /67400 (crfb4036) def /68400 (rf4044m) def /53412 (ecopmk) def end def % CCModelSeries /stemp 12 string def CCModel cvi dup 100 mod sub 10 stemp cvrs /CCModelSeries exch def CCModel cvi 53412 eq { /CCModelSeries (53412) def } if % CCPSLevel for setcolorscreen CCOutputFormat (RS) eq CCModelSeries (5300) eq or CCModelSeries (5400) eq or CCModelSeries (5500) eq or CCModelSeries (5600) eq or CCModelSeries (7000) eq or CCModelSeries (53412) eq or { /CCPSLevel 2 def } { /CCPSLevel 1 def } ifelse % save current pagesize, orientation, and hwresolution CCAreaProc CCDithering (STOCHASTIC) eq CCModelSeries (53412) eq and { /CCModelSeries (53400) def } if % CCModel selectdevice (would prefer this first) [{ /CCDevice CCDisplay { (mswindll) } { CCColorModel (CMYK) eq { CCCModelDict } if CCColorModel (Gray) eq { CCGModelDict } if CCColorModel (Black) eq { CCBModelDict } if CCModelSeries cvlit get } ifelse def CCDevice selectdevice } stopped cleartomark % setpagedevice after selectdevice % separate for pesky matching CCDisplay { /CCResolution [ 72 72 ] def } if /CCXRes CCResolution aload pop pop def [{ 2 dict dup begin /HWResolution CCResolution def /Orientation CCOrientation def end setpagedevice } stopped cleartomark [{ 1 dict dup begin /OutputType CCOutputMode def end setpagedevice } stopped cleartomark [{ 1 dict dup begin /MediaType CCMediaType def end setpagedevice } stopped cleartomark % Define some procedures and variables CCQuitFlashProc CCMarginProc % Scale area and image CCScaleAreaProc CCScaleImageProc % Colormatch or settransfer and screens CCDitherProc { 0.25 .setfilladjust 0 setlinewidth } stopped pop end % CCDict } def end def % Assign all variables and then %CCDict /CCSelectDeviceProc get exec % Solus problem if lt 1M use 100M /vmstatus { vmstatus dup 1048576 lt { pop 1073741824 } if } bind def %%EndResource