🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #3994

Re: How do I recognize postscript from a file

#3994
From: Vidiot
Date: Sat, 07 Nov 1992 03:27
33 lines
2241 bytes
In article <AV.92Nov4095431@kielo.uta.fi> av@uta.fi (Arto V. Viitanen) writes:
<>>>>> On 3 Nov 92 11:14:48 GMT, eweingar@loanshark.cs.indiana.edu (Peter Weingartner) said:
<
<Peter> In article <1992Nov3.083527.20756@ugle.unit.no> helgeaa@colargol (Helge O. Aarstein) writes:
<
<Peter>    We are trying to make a filter for the lp-command to reject 
<Peter>    non-postscript files. But, there is a problem: 
<Peter> 	   How can I be sure that the file contains postscript-
<Peter> 	   code?
<
<Peter> The simplest way is probably to check to see that the first two
<Peter> characters of the file are '%!'.  
<
<When printing from MS Windows to Postscript file, the file (if you don't
<make it not to) starts with characters ^D%! (i.e. control-D, %, !). In a way,
<this is right way, since ^D means end-of-job to a Postscript printer, so
<previous job is stopped. I only thought to say this, since lpr-filter on our
<department checks the %! -pair, and several times Postscript document has
<been run through Ascii-to-PS filter.

Starting with a ^D is wrong pure and simple.  DOS machines have been doing it
wrong for a long time.  Sending a ^D to the printer at the end of the job is
fine, but not before the job.

Makes it rough on printer spoolers looking for the correct %! and it also makes
it tough when trying to cat PostScript files together as one job.

I consider it wrong, plain and simple.
-- 
      harvard\                          spool.cs.wisc.edu!astroatc!vidiot!brown
Vidiot  ucbvax!uwvax..........!astroatc!vidiot!brown
      rutgers/            INTERNET:vidiot!brown%astroatc.UUCP@spool.cs.wisc.edu
                                   brown@wi.extrel.com
Technical Details
Message-ID: <4395@vidiot.UUCP>
Path: arc1-ca.pugleaf.net!sparky!uunet!europa.asd.contel.com!emory!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!rutgers!uwvax!astroatc!vidiot!brown
References: <1992Nov3.083527.20756@ugle.unit.no> <EWEINGAR.92Nov3111448@loanshark.cs.indiana.edu> <AV.92Nov4095431@kielo.uta.fi>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!europa.asd.contel.com!emory!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!rutgers!uwvax!astroatc!vidiot!brown
From: brown@vidiot.UUCP (Vidiot)
Newsgroups: comp.lang.postscript
Subject: Re: How do I recognize postscript from a file
Message-ID: <4395@vidiot.UUCP>
Date: 7 Nov 92 03:27:33 GMT
References: <1992Nov3.083527.20756@ugle.unit.no> <EWEINGAR.92Nov3111448@loanshark.cs.indiana.edu> <AV.92Nov4095431@kielo.uta.fi>
Reply-To: brown@vidiot.UUCP (Vidiot)
Organization: Vidiot's Hangout
Lines: 33