| 1 |
% $Id: pdftexmagfix.tex 8570 2008-06-05 00:13:02Z karl $ |
| 2 |
% pdftex \magnification fix by Heiko Oberdiek and Ian Hutchinson, 2007. |
| 3 |
% See http://silas.psfc.mit.edu/pdftexpatch/ for background. |
| 4 |
% Public domain. |
| 5 |
% |
| 6 |
% This file is input from pdftex.ini and pdfetex.ini. |
| 7 |
% |
| 8 |
\ifx\pdfoutput\undefined \else |
| 9 |
\ifx\pdfoutput\relax \else |
| 10 |
\catcode`@=11 |
| 11 |
\def\m@g{% replace plain.tex's definition, but start the same: |
| 12 |
\mag\count@ |
| 13 |
\hsize6.5truein\vsize8.9truein\dimen\footins8truein |
| 14 |
% And add these commands to fix the pdf sizes to be in true units. |
| 15 |
\ppdfmag@fix\pdfhorigin \ppdfmag@fix\pdfvorigin |
| 16 |
\ppdfmag@fix\pdfpagewidth \ppdfmag@fix\pdfpageheight |
| 17 |
}% |
| 18 |
\def\ppdfmag@fix#1{#1=\expandafter\ppdfconvert@truept\the#1\relax}% |
| 19 |
% |
| 20 |
\begingroup |
| 21 |
\catcode`P=12 |
| 22 |
\catcode`T=12 |
| 23 |
\lowercase{% |
| 24 |
\endgroup |
| 25 |
\def\ppdfconvert@truept#1PT{#1truept}% |
| 26 |
}% |
| 27 |
\catcode`@=12 |
| 28 |
\fi |
| 29 |
\fi |
| 30 |
% |
| 31 |
% Here's a simple test file, from Ian: |
| 32 |
%\magnification \magstep5 |
| 33 |
%\hoffset -1 truein \voffset -1 truein |
| 34 |
%\parindent 0pt The top |
| 35 |
%\end |
| 36 |
% "The top" should come out truly in the upper-left corner. |
| 37 |
|