home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Simtel MSDOS 1992 September
/
Simtel20_Sept92.cdr
/
msdos
/
laser
/
postprn.arc
/
LAND2.PS
< prev
next >
Wrap
Text File
|
1989-06-09
|
2KB
|
136 lines
%!
%
% Two-Up Landscape Page Printer
%
/inch {72 mul} def
/pageheight 11 inch def
/pagewidth 8.5 inch def
/tp0 pageheight .3 inch sub def
/bp0 5.6 inch def
/tp1 5.4 inch def
/bp1 .3 inch def
/lmarg .3 inch def
/tmarg tp0 def
/bmarg bp0 def
/lincr 5.6 def
/x lmarg def
/y tmarg def
/pg 0 def
/xw 0 def
/yw 0 def
/i currentfile def
/s 1000 string def
/ones 1 string def
/lastFF 0 def
/page_text 0 def % no text on this page
/undershow
{
currentlinewidth exch
dup show currentpoint 3 2 roll
stringwidth exch neg exch
0 -1.5 rmoveto rlineto 0.4 setlinewidth stroke
moveto setlinewidth
} def
/dolines
{
gsave
.1 setlinewidth
newpath
.2 inch 5.5 inch moveto
10.8 inch 5.5 inch lineto
stroke
grestore
} def
/doFF
%
% Takes 2 arguments:
%
% Top: Type of FF encountered (0 = whatever 1=char 2=margin)
% Next: Force showpage anyways?
%
{
/curFF exch def
1 eq
{
dolines
showpage
/page_text 0 def
/x lmarg def
/y tmarg def
/xw 0 def
/yw 0 def
}
{
%
% if FF right after last line on page, ignore FF
%
curFF 1 eq % This is FF?
lastFF 2 eq % Last was type 2 -- margin
x lmarg eq % Still at left margin
y tmarg eq % Still at top margin
and and and false eq % Do it if all the above is false
{
pg 0 eq
{
/pg 1 def
/tmarg tp1 def
/bmarg bp1 def
}
{
dolines
showpage
/page_text 0 def
/pg 0 def
/tmarg tp0 def
/bmarg bp0 def
} ifelse
/x lmarg def
/y tmarg def
/xw 0 def
/yw 0 def
} if
} ifelse
x y moveto
/lastFF curFF def
} def
/normal-font /Courier findfont 7 scalefont def
/bold-font /Courier-Bold findfont 7 scalefont def
/italic-font /Courier-Oblique findfont 7 scalefont def
/bolditalic-font /Courier-BoldOblique findfont 7 scalefont def
/isbold 0 def
/isitalic 0 def
/lineprint
{
normal-font setfont
{i s readline
{
x y moveto
showline
/x lmarg def
/y y lincr sub def
y bmarg lt
{ 0 2 doFF } if
}
{
page_text 1 eq
{1 0 doFF} if
exit
} ifelse
} loop
} def
lineprint