summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2008-06-05 00:13:02 +0000
committerKarl Berry <karl@freefriends.org>2008-06-05 00:13:02 +0000
commit2f66d6a7d1421c68e00c753acdb09df76bcb32b6 (patch)
treeb59eff562b9289f0311d2bef41ecd91e847fba41 /Master
parent998ff0b017112401e620d400170689b6f7067d5e (diff)
fix \magnification for pdftex per http://silas.psfc.mit.edu/pdftexpatch/ and Ian Hutchinson msg, 31 May 2008 17:51:03
git-svn-id: svn://tug.org/texlive/trunk@8570 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/tex/plain/config/pdfetex.ini1
-rw-r--r--Master/texmf-dist/tex/plain/config/pdftex.ini2
-rw-r--r--Master/texmf-dist/tex/plain/config/pdftexmagfix.tex37
-rw-r--r--Master/texmf/fmtutil/format.pdftex.cnf2
4 files changed, 40 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/plain/config/pdfetex.ini b/Master/texmf-dist/tex/plain/config/pdfetex.ini
index e5b7c74d585..56b3462bbf7 100644
--- a/Master/texmf-dist/tex/plain/config/pdfetex.ini
+++ b/Master/texmf-dist/tex/plain/config/pdfetex.ini
@@ -1,5 +1,6 @@
% Thomas Esser, 1998. public domain.
\input pdftexconfig.tex
\input etex.src
+\input pdftexmagfix.tex
\dump
\endinput
diff --git a/Master/texmf-dist/tex/plain/config/pdftex.ini b/Master/texmf-dist/tex/plain/config/pdftex.ini
index 12af71c38a5..bd788c28aed 100644
--- a/Master/texmf-dist/tex/plain/config/pdftex.ini
+++ b/Master/texmf-dist/tex/plain/config/pdftex.ini
@@ -1,6 +1,6 @@
% Thomas Esser, 1998. public domain.
-% hyphenation tables are now set up in language.dat
\input pdftexconfig.tex
\input plain
+\input pdftexmagfix.tex
\dump
\endinput
diff --git a/Master/texmf-dist/tex/plain/config/pdftexmagfix.tex b/Master/texmf-dist/tex/plain/config/pdftexmagfix.tex
new file mode 100644
index 00000000000..ef550974a9a
--- /dev/null
+++ b/Master/texmf-dist/tex/plain/config/pdftexmagfix.tex
@@ -0,0 +1,37 @@
+% $Id$
+% pdftex \magnification fix by Heiko Oberdiek and Ian Hutchinson, 2007.
+% See http://silas.psfc.mit.edu/pdftexpatch/ for background.
+% Public domain.
+%
+% This file is input from pdftex.ini and pdfetex.ini.
+%
+\ifx\pdfoutput\undefined \else
+ \ifx\pdfoutput\relax \else
+ \catcode`@=11
+ \def\m@g{% replace plain.tex's definition, but start the same:
+ \mag\count@
+ \hsize6.5truein\vsize8.9truein\dimen\footins8truein
+ % And add these commands to fix the pdf sizes to be in true units.
+ \ppdfmag@fix\pdfhorigin \ppdfmag@fix\pdfvorigin
+ \ppdfmag@fix\pdfpagewidth \ppdfmag@fix\pdfpageheight
+ }%
+ \def\ppdfmag@fix#1{#1=\expandafter\ppdfconvert@truept\the#1\relax}%
+ %
+ \begingroup
+ \catcode`P=12
+ \catcode`T=12
+ \lowercase{%
+ \endgroup
+ \def\ppdfconvert@truept#1PT{#1truept}%
+ }%
+ \catcode`@=12
+ \fi
+\fi
+%
+% Here's a simple test file, from Ian:
+%\magnification \magstep5
+%\hoffset -1 truein \voffset -1 truein
+%\parindent 0pt The top
+%\end
+% "The top" should come out truly in the upper-left corner.
+
diff --git a/Master/texmf/fmtutil/format.pdftex.cnf b/Master/texmf/fmtutil/format.pdftex.cnf
index ff754e11fe3..ac2d98d2901 100644
--- a/Master/texmf/fmtutil/format.pdftex.cnf
+++ b/Master/texmf/fmtutil/format.pdftex.cnf
@@ -1,5 +1,5 @@
# ------------------------------------------------------------------
# $Id$
-etex pdftex language.def -translate-file=cp227.tcx *pdftex.ini
+etex pdftex language.def -translate-file=cp227.tcx *pdfetex.ini
pdfetex pdftex language.def -translate-file=cp227.tcx *pdfetex.ini
pdftex pdftex - -translate-file=cp227.tcx *pdftex.ini