🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.postscript
Article #3625

Re: Landscape page orientation

#3625
From: Christopher Tate
Date: Fri, 09 Nov 1990 20:16
46 lines
2460 bytes
In article <21532@well.sf.ca.us>, jef@well.sf.ca.us (Jef Poskanzer) asks:

>In the referenced message, Gisle.Aas@nr.no wrote:
>}To get the right pageheight/width you have to add together ury/x and
>}lly/x.  The clippath defines an area smaller than the physical page.
>
>You're saying I should add instead of subtracting?  That doesn't
>make sense to me.  Could you be more specific?  Provide corrected code
>perhaps?

The origin is located at the corner of the PHYSICAL page.  The actual
boundaries of the printable page are smaller than the physical page,
so you have to compensate for that.

When you pull the llx, lly, urx, and ury coordinates from the clippath
bounding box, you get the boundaries of the PRINTABLE rectangle, not of
the page rectangle.  If you do the following:

                           urx 0 translate

The origin will now corrospond to the opposite (along the x axis) corner
of the PRINTABLE rectangle, which is not what you want.  To make the
new origin the corner of the physical page, you also have to add the
distance between the x-axis edges of the physical and printable page
rectangles.  Assuming that the printable rectangle is correctly centered,
this distance is the same as the distance between the "default" origin
and the edge of the paper, i.e. the llx value.

So, if you do this:

                     llx urx add 0 translate

you'll wind up translating the origin all the way over to the other corner
of the PHYSICAL page.  Then, when you rotate into landscape orientation,
the "lower left" corners of the page will be related in the same way as
when you use the default portrait orientation.  You'll just have more room
in the x direction, and less in the y direction.

(I hope this was clear....  :-)

-------
Christopher Tate                   |
                                   |      Of alle songes this is best:
cxt105@psuvm.psu.edu               |        Verbum caro factum est!
{...}!psuvax1!psuvm.bitnet!cxt105  |
cxt105@psuvm.bitnet                |
Technical Details
Message-ID: <90313.151629CXT105@psuvm.psu.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!zaphod.mps.ohio-state.edu!julius.cs.uiuc.edu!psuvax1!psuvm!cxt105
References: <AAS.90Nov7093033@boeygen.nr.no> <21532@well.sf.ca.us>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!zaphod.mps.ohio-state.edu!julius.cs.uiuc.edu!psuvax1!psuvm!cxt105
From: CXT105@psuvm.psu.edu (Christopher Tate)
Newsgroups: comp.lang.postscript
Subject: Re: Landscape page orientation
Message-ID: <90313.151629CXT105@psuvm.psu.edu>
Date: 9 Nov 90 20:16:29 GMT
References: <AAS.90Nov7093033@boeygen.nr.no> <21532@well.sf.ca.us>
Organization: Penn State University
Lines: 46