HP3000-L Archives

August 2002, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Wirt Atmar <[log in to unmask]>
Reply To:
Date:
Thu, 15 Aug 2002 17:46:04 EDT
Content-Type:
text/plain
Parts/Attachments:
text/plain (114 lines)
Bruce writes:

> >No, no, no.
>
>  Yes, yes, yes, from the point of view of the spooler or other
>  postprocessor. I've written a page tumbling postprocessor that interprets
>  PostScript and ADSC together, and I do very much care about the structure
>  of both the comments *and* the PostScript code in that application. The
>  PostScript needs to be augmented, then repackaged with different
>  "comments" (to PostScript) or "code" (to the downstream processor) in
>  order to do the job. Whether ADSC is interpreted as comments or code
>  depends on what's doing the interpretation.

No, you're skewing the question. That, and the fact that I don't understand
what you're doing. The comments (lines that begin with "%") are completely
ignored by the PS interpreter.

I just selected another printer, one that duplexes, tumbles and prints in
color, and printed the same page that I quoted earlier. The QueryCalc-emitted
code now looks like this:

=======================================

%!PS-Adobe-3.1
%%Title: QueryCalc
%%Creator: AICS Research, Inc.
%%CreationDate: THU, AUG 15, 2002,  3:25 PM
%%DocumentFonts: Helvetica
%%BoundingBox: 0 0 612 792
%%Pages: (atend)
%%EndComments

%%BeginProlog
statusdict begin
<</Duplex true /Tumble true>> setpagedevice
end
/$aics 210 dict def
$aics begin
/cellwidth 72 def
/rightshow {dup stringwidth pop cellwidth exch sub 0 rmoveto show} def
/rjshow {dup stringwidth pop neg 0 rmoveto show} def
/centershow {dup stringwidth pop cellwidth exch
             sub 2 div 0 rmoveto show} def
/justify {dup stringwidth pop justwidth exch sub
          numspaces div 0 32 4 -1 roll widthshow} def
/Courier-Bold findfont 9 scalefont setfont 0 setgray
%%EndProlog

%%Page: SpreadSheet 1
save
/AvantGarde-BookOblique findfont 15 scalefont setfont 0 .5 1 0 setcmykcolor
96 696 moveto
/cellwidth 72 def
(Bruce lives in Phoenix) show
showpage
restore

%%Trailer
%%Pages: 1
%%EOF

=======================================

If the printer has the capability to tumble and duplex a page, the code above
will do exactly that, but then so will the code below, where all of the
comments have been removed:

=======================================

statusdict begin
<</Duplex true /Tumble true>> setpagedevice
end
/$aics 210 dict def
$aics begin
/cellwidth 72 def
/rightshow {dup stringwidth pop cellwidth exch sub 0 rmoveto show} def
/rjshow {dup stringwidth pop neg 0 rmoveto show} def
/centershow {dup stringwidth pop cellwidth exch
             sub 2 div 0 rmoveto show} def
/justify {dup stringwidth pop justwidth exch sub
          numspaces div 0 32 4 -1 roll widthshow} def
/Courier-Bold findfont 9 scalefont setfont 0 setgray

save
/AvantGarde-BookOblique findfont 15 scalefont setfont 0 .5 1 0 setcmykcolor
96 696 moveto
/cellwidth 72 def
(Bruce lives in Phoenix) show
showpage
restore

=======================================

These two code segments are identical to the PS interpreter -- and will
behave exactly the same, if the printer will accept an non-DSC-structured
document. Indeed, if you had on hand one of the earliest PostScript printers,
such as the Apple Laser Writer, they had a terminal interface where you could
type either set of code above directly into the printer and cause it to
create its page images that way. If you had that kind of printer, you could
demonstrate to yourself the equivalency of the two code segments. The DSC
instructions, which are buried in the "%%" comments are completely irrelevant
to PostScript.

The DSC is not necessary to tumbling, duplexing, negative imaging, etc. a
page. Those qualities are wholly a property of the printer itself and they
have always been commandable within PostScript itself, beginning with the
first Apple Macintoshes, although the specific means to do it have evolved
over the years.

Wirt Atmar

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2