]> code.delx.au - gnu-emacs/blobdiff - etc/ps-prin0.ps
(Program Modes): Replace inforef to emacs-xtra by conditional xref's, depending
[gnu-emacs] / etc / ps-prin0.ps
index b57968fecc31b3447efac0ea7dd8fa7b16636d11..952c31d2b2e7db02091f59c27a0b3e55e690f877 100644 (file)
@@ -1,4 +1,35 @@
 % === BEGIN ps-print prologue 0
+% version: 6.0
+
+% Copyright (C) 2000, 2001  Free Software Foundation, Inc.
+%
+% This file is part of GNU Emacs.
+%
+% GNU Emacs is free software; you can redistribute it and/or modify
+% it under the terms of the GNU General Public License as published by
+% the Free Software Foundation; either version 2, or (at your option)
+% any later version.
+%
+% GNU Emacs is distributed in the hope that it will be useful,
+% but WITHOUT ANY WARRANTY; without even the implied warranty of
+% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+% GNU General Public License for more details.
+%
+% You should have received a copy of the GNU General Public License
+% along with GNU Emacs; see the file COPYING.  If not, write to the
+% Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+% Boston, MA 02110-1301, USA.
+
+% As a special exception, the copyright holders of this module give
+% you permission to include the module in a Postscript file generated
+% by Emacs or other free software together with the result of
+% converting text to be printed, regardless of the license terms of
+% that text, and to use under terms of your choice the page images
+% resulting from formatting said combination.  If you modify this
+% module, you may extend this exception to your version of the module
+% but you are not obligated to do so.  If you do not wish to do so,
+% delete this exception statement from your version.
+
 
 %%BeginProcSet: ErrorHandler
 % Downloaded Error Break-page handler
 {
  /ps$brkpage 64 dict def
  ps$brkpage begin
-  /tx 0 def /ty 0 def /toy 0 def /tox 0 def
+  /tx 0 def/ty 0 def/toy 0 def/tox 0 def
   /prnt{
-   dup type /stringtype ne{=string cvs}if
+   dup type/stringtype ne{=string cvs}if
    dup length 6 mul
-   /tx exch def /ty 10 def
-   currentpoint /toy exch def /tox exch def
+   /tx exch def/ty 10 def
+   currentpoint/toy exch def/tox exch def
    1 setgray newpath
    tox toy 2 sub moveto
    0 ty rlineto tx 0 rlineto
@@ -30,8 +61,8 @@
   /lmargin 72 def
   /rmargin 72 def
   /tprint{
-   dup length cp add rmargin gt{nl /cp 0 def}if
-   dup length cp add /cp exch def
+   dup length cp add rmargin gt{nl/cp 0 def}if
+   dup length cp add/cp exch def
    prnt
   }readonly def
   /cvsprint{=string cvs tprint( )tprint}readonly def
@@ -63,8 +94,8 @@
     {({)tprint{typeprint}forall(})tprint}
     {([)tprint{typeprint}forall(])tprint}ifelse}
    {pop(-packedarray-)tprint}ifelse}readonly def
-  /courier /Courier findfont 10 scalefont def
-  /OLDhandleerror errordict /handleerror get def
+  /courier/Courier findfont 10 scalefont def
+  /OLDhandleerror errordict/handleerror get def
  end %ps$brkpage
 
  /handleerror{
    ErrorMessage 1 and 0 ne{ % print on paper
     courier setfont lmargin 720 moveto
     (# ERROR: )prnt errorname prnt nl
-    (# OFFENDING COMMAND: )prnt /command load prnt
-    $error /ostack known
-    {nl nl(# STACK:)prnt nl nl $error /ostack get aload length{==}repeat}if
-    $error /errorinfo known
-    {nl nl(# ERRORINFO:)prnt nl nl $error /errorinfo get aload length{==}repeat}if
-    systemdict /showpage get exec}if
+    (# OFFENDING COMMAND: )prnt/command load prnt
+    $error/ostack known
+    {nl nl(# STACK:)prnt nl nl $error/ostack get aload length{==}repeat}if
+    $error/errorinfo known
+    {nl nl(# ERRORINFO:)prnt nl nl $error/errorinfo get aload length{==}repeat}if
+    systemdict/showpage get exec}if
    ErrorMessage 2 and 0 ne{ % send back to printing system
     (\%\%[ Error: )print errorname =print
     (; OffendingCommand: )print/command load =print
-    $error /errorinfo known
-    {(; ErrorInfo:)print $error /errorinfo get aload length{( )=print =print}repeat}if
+    $error/errorinfo known
+    {(; ErrorInfo:)print $error/errorinfo get aload length{( )=print =print}repeat}if
     ( ]\%\%)= flush
     (\%\%[ Rest of job is ignored ]\%\%)= flush}if
    /newerror true store}if
 }ifelse
 %%EndProcSet
 
-gs_languagelevel 1 eq{ % operators for language level 2 only
- /<<{mark}bind def
- />>{counttomark 2 idiv dup dict begin{def}repeat pop currentdict end}bind def
- /setpagedevice{pop}bind def
- /packedarray{array astore readonly}bind def
-}if
+
+% operators for language level 2 only
+
+(<<)cvn where                  % << operator
+{pop/BMark(<<)cvn load def}
+{/BMark{mark}bind def}ifelse
+(>>)cvn where                  % >> operator
+{pop/EMark(>>)cvn load def}
+{/EMark{counttomark 2 idiv dup dict begin{def}repeat pop currentdict end}bind def}ifelse
+/setpagedevice where           % setpagedevice
+{pop}
+{/setpagedevice{pop}bind def}ifelse
+/packedarray where             % packedarray
+{pop}
+{/packedarray{array astore readonly}bind def}ifelse
+
 
 % device dependent operators
 
-/setduplexmode where{pop}
-{/setduplexmode /duplexmode where{pop/duplexmode}{/pop}ifelse load def}ifelse
+/DefOp{
+ dup where{pop pop pop}
+ {exch dup where{pop}{pop/pop}ifelse load def}ifelse}def
 
-/settumble where{pop}
-{/settumble /tumble where{pop/tumble}{/pop}ifelse load def}ifelse
+/duplexmode/setduplexmode DefOp
+/tumble/settumble DefOp
 
 % === END ps-print prologue 0