🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #1296

PS page counter

#1296
From: consult
Date: Thu, 09 Nov 1989 03:21
18 lines
1219 bytes
  I am looking for a (simple?) algorithm to count pages in a postscript
file.  I know almost nothing about postscript, so I am soliciting your
help here.
  For years we have been using a modified lpr program on our Unix systems
that counts the number of pages being printed and charges the user a set
rate for each page.  Our problem now is that users have access to laser
printers over the net and if they try to print postscript files they are
usually way overcharged, as there can be many more than 66 lines per page
with all the font and graphics information in a postscript file.
  What I would like to do is first detect if the file being printed is
postscript (I believe it must start with '%!', right?) and if it is use
the new formula for calculating the number of pages being printed.
  Thanks for your help.

  Cary Jamison
  BYU CS Dept. Systems Programmer
  cary@cs.byu.edu
Technical Details
Message-ID: <1consult@physc1.byu.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!samsung!brutus.cs.uiuc.edu!psuvax1!psuvm!cunyvm!byuvax!physc1!physc1!consult

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!samsung!brutus.cs.uiuc.edu!psuvax1!psuvm!cunyvm!byuvax!physc1!physc1!consult
From: consult@physc1.byu.edu
Newsgroups: comp.lang.postscript
Subject: PS page counter
Message-ID: <1consult@physc1.byu.edu>
Date: 9 Nov 89 03:21:59 GMT
Lines: 16