🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #8003

Troff macro to include postscript.

#8003
From: Mart van Stiphout
Date: Fri, 17 Feb 1989 15:15
47 lines
1512 bytes
In reply to recent questions on how to include postscript
in troff, here is a troff macro that does the job.
---------- cut here ----------------------------------
.\"******** include postscript .pS <file> <height> <box>
.\"******** author: Reinier v.d. Born
.de pS
.ne 1v+\\$2
.rs
.sp 1v+\\$2
.nr pS 0-\\$2
.pP "\\$1" \\n(pS \\$3
..
.de pP
.ie "\\n(.z"" \{\
\\!%
\\!save /psv exch def
\\!\\n(.o  \\n(nl moveto
\\!\\n(.l  0      rlineto
\\!0       \\$2   rlineto
\\!-\\n(.l 0      rlineto closepath clip
\\!\\n(.o  \\n(nl moveto
\\!currentpoint translate resolution 72 div dup neg scale 0 0 moveto 
\\!500 dict begin (
.cf \\$1
.if \\n(.$-2 \{\
\\!0 setgray initmatrix 1 setlinewidth clippath stroke 
.\}
\\!end
\\!PE
\\!.
.\}
.el \{\
\\!.pP "\\$1" \\$2 \\$3
.\}
..
---------- cut here ----------------------------------


Mart van Stiphout
Eindhoven University of Technology
Design Automation Section
Dept. of Electrical Engineering
P.O.Box 513
5600 MB Eindhoven
The Netherlands
Email: mart@euteal.UUCp
Technical Details
Message-ID: <24@euteal.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!decwrl!sun!pitstop!sundc!seismo!uunet!mcvax!hp4nl!eutrc3!euteal!mart

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!utstat!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!decwrl!sun!pitstop!sundc!seismo!uunet!mcvax!hp4nl!eutrc3!euteal!mart
From: mart@euteal.UUCP (Mart van Stiphout)
Newsgroups: comp.lang.postscript,comp.text
Subject: Troff macro to include postscript.
Keywords: troff, postscript.
Message-ID: <24@euteal.UUCP>
Date: 17 Feb 89 15:15:41 GMT
Organization: Eindhoven University of Technology, The Netherlands
Lines: 47