Mario Streiber wrote:
Dierk Fröhling's Message from Thu December 2 2004 10:08:
Dierk Fröhling wrote:
Dierk Fröhling wrote:
Try instead:
%!PS-Adobe-2.0 %%BoundingBox: 0 0 842 595 %%HiResBoundingBox: 0.0000000 0.0000000 842.00000 595.00000 -90 rotate -842.0 0.00000 translate 0.8 0.8 scale . . .
Maybe that's better...
If it works, you could use sed as in the example at: http://portal.suse.de/sdb/de/2002/12/jsmeix_print-cups-landsca pe-81.html to modify the PostScript code (add the rotate line, change the translate line and change the scale line).
sed -e 's/^0.0 595.00000 translate/-90 rotate\n-842.0 0.0 translate/' pstest.ps | sed -e 's/^0.8 -0.8/0.8 0.8/'
^-- without linebreak
and without the file name!
sed -e 's/^0.0 595.00000 translate/-90 rotate\n-842.0 0.0 translate/' | sed -e 's/^0.8 -0.8/0.8 0.8/'
Many thanks for your efforts, but the modifications still mirror the printed page. Here is the .ps file again with a letter added (lowercase k in the upper left corner) that shows the mirroring:
%!PS-Adobe-2.0 %%BoundingBox: 0 0 842 595 %%HiResBoundingBox: 0.0000000 0.0000000 842.00000 595.00000 0.0 595.00000 translate 0.8 -0.8 scale gsave [1.0000000 0.0000000 0.0000000 1.0000000 0.0000000 0.0000000] concat gsave [1.0000000 0.0000000 0.0000000 1.0000000 -10.751160 743.75510] concat 0.0000000 0.0000000 0.0000000 setrgbcolor newpath 152.66046 -566.75702 moveto 152.66046 -141.91464 lineto 910.57446 -141.91464 lineto 910.57446 -566.75702 lineto 152.66046 -566.75702 lineto closepath [] 0 setdash 0.35404503 setlinewidth 0 setlinejoin 0 setlinecap stroke grestore gsave [7.5221810 -0.0000000 0.0000000 8.5339330 0.0000000 0.0000000] concat 0.0000000 0.0000000 0.0000000 setrgbcolor newpath 20.255056 27.925713 moveto 20.255056 21.757744 lineto 21.024588 21.757744 lineto 21.024588 25.742119 lineto 22.446463 23.683525 lineto 23.180838 23.683525 lineto 21.825369 25.687431 lineto 23.583181 27.925713 lineto 22.645681 27.925713 lineto 21.024588 25.749931 lineto 21.024588 27.925713 lineto 20.255056 27.925713 lineto fill grestore grestore showpage
Mario
hopefully final version: %!PS-Adobe-2.0 %%BoundingBox: 0 0 842 595 %%HiResBoundingBox: 0.0000000 0.0000000 842.00000 595.00000 -90 rotate -842.0 595.0 translate 0.8 -0.8 scale . . . sed command: sed -e 's/^0.0 595.00000 translate/-90 rotate\n-842.0 595.0 translate/' Oh and for A3 paper replace every 842 by 1191 and every 595 by 842. For letter size 595->612, 842->792. For tabloid size 595->792, 842->1224 CU Dierk -- Mit freundlichen Grüßen Best regards // Dierk Froehling // aycan Digitalsysteme GmbH // Innere Aumuehlstrasse 5 // 97076 Wuerzburg // Germany // phone: +49.931.270 40 90 // fax: +49.931.270 40 91 // mailto:dfroehling@aycan.de // http://www.aycan.de