summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/latex/pdfpages/README69
-rw-r--r--Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex2
-rw-r--r--Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex2
-rw-r--r--Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex2
-rw-r--r--Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdfbin177657 -> 171951 bytes
-rw-r--r--Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx578
-rw-r--r--Master/texmf-dist/source/latex/pdfpages/pdfpages.ins3
-rw-r--r--Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty120
-rw-r--r--Master/texmf-dist/tex/latex/pdfpages/ppnull.def32
-rw-r--r--Master/texmf-dist/tex/latex/pdfpages/pppdftex.def90
-rw-r--r--Master/texmf-dist/tex/latex/pdfpages/ppvtex.def35
-rw-r--r--Master/texmf-dist/tex/latex/pdfpages/ppxetex.def180
12 files changed, 907 insertions, 206 deletions
diff --git a/Master/texmf-dist/doc/latex/pdfpages/README b/Master/texmf-dist/doc/latex/pdfpages/README
index 2cac22941c8..3d734620295 100644
--- a/Master/texmf-dist/doc/latex/pdfpages/README
+++ b/Master/texmf-dist/doc/latex/pdfpages/README
@@ -1,30 +1,39 @@
-
-The pdfpages Package
---------------------
-
-This package simplifies the insertion of external multi-page PDF
-documents into LaTeX documents. Pages can be freely selected and
-similar to psnup it is possible to put several logical pages onto
-each sheet of paper. Furthermore a lot of hypertext features like
-hyperlinks and article threads are provided. This package supports
-pdfTeX (pdflatex) and VTeX. With VTeX it is even possible to use
-this package to insert PostScript files, in addition to PDF files.
-
-
-Run `latex pdfpages.ins' to produce pdfpages.sty and the
-driver files pppdftex.def, ppvtex.def and ppnull.def.
-Move these files into a directory searched by LaTeX.
-
-Run `latex pdfpages.dtx' to produce the documentation.
-
-Run `pdflatex pdf-ex.tex', `pdflatex pdf-hyp.tex',
-and `pdflatex pdf-toc.tex' to produce some examples.
-
-This program may be distributed and/or modified under the
-conditions of the LaTeX Project Public License, either version 1.3c
-of this license or (at your option) any later version.
-See <http://www.latex-project.org/lppl/>.
-
-
- Andreas MATTHIAS
- amat@kabsi.at
+
+The pdfpages Package
+--------------------
+
+This package simplifies the insertion of external multi-page PDF
+documents into LaTeX documents. Pages can be freely selected and
+similar to psnup it is possible to put several logical pages onto
+each sheet of paper. Furthermore a lot of hypertext features like
+hyperlinks and article threads are provided. This package supports
+pdfTeX, VTeX, and XeTeX. With VTeX it is even possible to use
+this package to insert PostScript files, in addition to PDF files.
+
+
+INSTALLATION:
+
+To install this package, unzip pdfpages-tds.zip into your TeX-tree,
+e.g.:
+
+ unzip -d /usr/local/TL2007/texmf-local/ pdfpages-tds.zip
+
+
+To create and install the files manually, proceed as follows:
+
+ * Run `latex pdfpages.ins' to produce the LaTeX files
+ * Run `latex pdfpages.dtx' to produce the documentation
+ * Move the files into appropriate directories searched by LaTeX.
+
+
+This work may be distributed and/or modified under the conditions
+of the LaTeX Project Public License, either version 1.3 of this
+license or (at your option) any later version.
+The latest version of this license is in
+ <http://www.latex-project.org/lppl.txt>
+and version 1.3 or later is part of all distributions of LaTeX
+version 2005/12/01 or later.
+
+
+
+ Andreas MATTHIAS
diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex
index 0c1093a325b..cfcdfd0bf95 100644
--- a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex
+++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex
@@ -9,7 +9,7 @@
%% This file demonstrates how to use the pdfpages package.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
\documentclass[a4paper,12pt]{article}
\usepackage[final]{pdfpages}
diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex
index 777a3bce272..dd7672e7ee5 100644
--- a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex
+++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex
@@ -9,7 +9,7 @@
%% This file demonstrates how to use the pdfpages package.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
\documentclass[a4paper,12pt]{article}
\usepackage[final]{pdfpages}
diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex
index b41a1abb0dd..6199822f7b9 100644
--- a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex
+++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex
@@ -9,7 +9,7 @@
%% This file demonstrates how to use the pdfpages package.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
\documentclass[a4paper]{book}
\usepackage{pdfpages}
diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf b/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf
index b37f151d7ce..a4e678ab3b7 100644
--- a/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf
+++ b/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx b/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx
index a55be43f57f..259ab056cf3 100644
--- a/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx
+++ b/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx
@@ -4,22 +4,24 @@
%<*(package,pppdftexdef,ppvtexdef,ppnulldef)>
%% Copyright (C) 2001-2006 Andreas MATTHIAS
%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3c of this license or (at your option) any
-%% later version. The latest version of this license is in
+%% This work may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
-%% and version 1.3c or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
-%% The Current Maintainer of this work is Andreas Matthias <amat@kabsi.at>.
+%% The Current Maintainer of this work is
+%% Andreas Matthias <andreas.matthias@gmail.com>.
+%
%</(package,pppdftexdef,ppvtexdef,ppnulldef)>
%<*!installer>
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%</!installer>
%%
%
@@ -27,10 +29,10 @@
%<*dtx>
\makeatletter
%</dtx>
-\def\AM@fileversion{v0.4a}
+\def\AM@fileversion{v0.4c}
\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
-\AM@SVN@Date$Date: 2006-08-12 01:13:35 +0200 (Sat, 12 Aug 2006) $
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
%</!(example1,example2,example3,installer)>
%
%
@@ -41,6 +43,7 @@
%<package>\ProvidesPackage{pdfpages}
%<pppdftexdef>\ProvidesFile{pppdftex.def}
%<ppvtexdef>\ProvidesFile{ppvtex.def}
+%<ppxetexdef>\ProvidesFile{ppxetex.def}
%<ppnulldef>\ProvidesFile{ppnull.def}
%<driver>\ProvidesFile{pdfpages.drv}
%<*!(example1,example2,example3,installer)>
@@ -67,14 +70,15 @@
%<package> Insert pages of external PDF documents (AM)]
%<pppdftexdef> Pdfpages driver for pdfTeX (AM)]
%<ppvtexdef> Pdfpages driver for VTeX (AM)]
-%<ppnulldef> Pdfpages' dummy driver (AM)]
+%<ppxetexdef> Pdfpages driver for XeTeX (AM)]
+%<ppnulldef> Pdfpages dummy driver (AM)]
%
%
% \fi
%
% \GetFileInfo{pdfpages.dtx}
%
-% \CheckSum{3751}
+% \CheckSum{4225}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -97,7 +101,10 @@
%<*driver>
\documentclass{ltxdoc}
\usepackage{array}
-\usepackage{hyperref}
+\usepackage{graphicx}
+\usepackage{hypdoc}
+\hypersetup{colorlinks, linkcolor=blue, pdfstartview={Fit},
+ bookmarksopenlevel=1, bookmarksnumbered=false}
\OnlyDescription
\begin{document}
\DocInput{pdfpages.dtx}
@@ -113,20 +120,25 @@
% \newcommand{\marginstyle}
% {\raggedleft\itshape\small}
%
-% \def\pdfTeX{pdf\kern.04em\TeX}
-% \def\pdfLaTeX{pdf\kern.06em\LaTeX}
-% \def\VTeX{V\kern-.05em\TeX}
+% \def\pdfTeX{pdfTeX}
+% \def\pdfLaTeX{pdfLaTeX}
+% \def\VTeX{VTeX}
+% \def\XeTeX{XeTeX}
% \def\PDF{{\small PDF}}
% \def\PS{{\small PS}}
% \def\DVI{{\small DVI}}
%
-% \pdfstringdef{\pdfTeX}{pdfTeX}
-% \pdfstringdef{\VTeX}{VTeX}
+% \pdfstringdefDisableCommands{%
+% \def\pdfTeX{pdfTeX}%
+% \def\VTeX{VTeX}%
+% \def\XeTeX{XeTeX}%
+% }
%
% \makeatletter
% \title{The \textsf{pdfpages} Package\thanks{This file
% has version number \AM@fileversion, last revised \AM@filedate.}}
-% \author{Andreas MATTHIAS\\ \texttt{amat@kabsi.at}}
+% \author{Andreas \textsc{Matthias}\\
+% \href{mailto:andreas.matthias@gmail.com}{andreas.matthias@gmail.com}}
% \date{\AM@filedate}
% \makeatother
%
@@ -135,10 +147,9 @@
% \begin{abstract}
% \noindent
% This package simplifies the insertion of external multi-page \PDF\
-% or \PS\ documents. It supports \pdfLaTeX\ and \VTeX.
+% or \PS\ documents. It supports \pdfTeX, \VTeX, and \XeTeX.
% \end{abstract}
%
-% \pdfbookmark[1]{\contentsname}{toc}
% \tableofcontents
%
%
@@ -349,6 +360,8 @@
% Either `true' or `false' (or no value, which
% is equivalent to `true'). \df{fitpaper=false}
% \item[reflect] Reflects included pages.
+% Either `true' or `false' (or no value, which
+% is equivalent to `true'). \df{reflect=false}
% \item[signature] Creates booklets by rearranging
% pages into signatures and setting
% |nup=1x2| or |nup=2x1|, respectively. This option
@@ -361,6 +374,11 @@
% |\includepdf[pages=-, signature=8]{landscape-doc.pdf}|
% \item[signature*] Similar to |signature|, but now for right-edge
% binding.
+% \item[booklet] This option is just a shortcut of the `signature'
+% option, if you choose a signature value
+% so large that all pages fit into one signature.
+% Either `true' or `false' (or no value, which
+% is equivalent to `true'). \df{booklet=false}
% \item[picturecommand] Declares picture commands which are executed
% on every page within a picture environment with the
% base point at the lower left corner of the page.
@@ -373,13 +391,22 @@
% \df{picturecommand*=\{\}}
% \item[pagetemplate] By default the first inserted page will be
% used as a template. This means that all further
-% pages are scaled to match within the contour of this
+% pages are scaled such that they match within the
+% contour of this
% first page. This option allows to declare another
% page to be used as a template; which is only useful
% if a \PDF\ document contains different page sizes
% or page orientations. The argument should
% be a page number.
% \df{pagetemplate=\meta{first inserted page}}
+% \item[templatesize] This option is similar to the |pagetemplate|
+% option, but its arguments specify the size of
+% the template directly. Its syntax is:
+% |templatesize={|\meta{width}|}{|\meta{height}|}|, e.g.
+% |templatesize={615pt}{846pt}|.
+% Note: The two lengths should be a bit larger than
+% desired, to keep away from rounding errors.\par
+% \df{templatesize=\meta{size of the first inserted page}}
% \item[rotateoversize] This option allows to rotate oversized
% pages. E.g.\ pages in landscape orientation are
% oversized relatively to their portrait counterpart,
@@ -466,17 +493,29 @@
%
% \begin{description}
% \makeatletter\@beginparpenalty=10000\makeatother
-% \item[linkfit] Specifies the way the viewer displays a linked page.
+% \item[linkfit] Specifies, how the viewer displays a linked page.
% This option changes the default behavior of the
% option \texttt{link}.
-% Possible values are: \texttt{fitb}, \texttt{fith},
-% \texttt{fitv}, \texttt{fitr},
-% \texttt{xyz zoom \meta{integer}}, etc.
-% These are destinations (|\pdfdest|) like they are
-% described in \cite{pdftex}.
-% Pdfpages adds one additional destination named
-% |region|, which scales a page such that it fits
-% exactly into the window of the \PDF\ viewer.
+% Possible values are:
+% \texttt{Fit},
+% \texttt{FitH \meta{top}},
+% \texttt{FitV \meta{left}},
+% \texttt{FitB},
+% \texttt{FitBH \meta{top}},
+% \texttt{FitBV \meta{left}},
+%^^A \texttt{fitr \meta{left} \meta{bottom}
+%^^A \meta{right} \meta{top}},
+%^^A \texttt{xyz \meta{left} \meta{top} \meta{zoom}},
+% and \texttt{Region}.
+%
+% See \cite{PDFRef} for a details description of these
+% \PDF\ destinations. The |region| destination was
+% added by pdfpages and is not a real \PDF\
+% destinations. It scales a page such that the
+% included page fits exactly into the window of the
+% \PDF\ viewer.\par
+% Note that not all of these options are supported by
+% all \TeX-engines or drivers, respectively.
% \df{linkfit=fit}
% \item[linktodocfit] By default the option \texttt{linktodoc} opens
% the page in `Fit in Window' view.
@@ -969,9 +1008,8 @@
% Sebastian Rahtz, Hans Hagen,
% \textit{The \pdfTeX\ user manual},
% \url{http://www.tug.org/applications/pdftex}
-% \bibitem{PDFRef} \textit{PDF Reference}, Third Edition, Version 1.4,
-% Adobe Systems Incorporated,\\
-% \url{http://partners.adobe.com/asn/tech/pdf/specifications.jsp}
+% \bibitem{PDFRef} \textit{PDF Reference}, Adobe Systems Incorporated,\\
+% \url{http://www.adobe.com/devnet/pdf/pdf_reference.html}
% \end{thebibliography}
% }
%
@@ -989,33 +1027,51 @@
\DeclareOption{final}{\AM@pkg@draftfalse}
\DeclareOption{enable-survey}{\AM@pkg@surveytrue}
\DeclareOption{disable-survey}{\AM@pkg@surveyfalse}
-\ProcessOptions
-% \end{macrocode}
-% \subsection{Required Packages and Version Checking}
-%
+% \begin{macrocode}
% |\AM@ifdriverlater| checks that the driver loaded is more recent
% than the given date. See |\@ifpackagelater| from the standard
% \LaTeX\ kernel.
% \begin{macrocode}
\def\AM@ifdriverlater{\@ifl@ter{def}}
% \end{macrocode}
-% Check for using \pdfTeX\ of \VTeX.
-% -- Note:
-% If \texttt{graphics.sty} is loaded before this package,
-% \texttt{pdfoutput} may be undefined, even if \pdfLaTeX\
-% is used, because some \texttt{graphic.cfg} undefine
-% \texttt{pdfoutput} (\verb|\let\pdfoutput\@undefined|),
-% if the document contains the line \verb|\pdfoutput=0|.
+% The configuration file |pdfpages.cfg| can be used to make
+% new driver files known to the package.
% \begin{macrocode}
-\begingroup
-\@ifundefined{pdfoutput}{%
- \@ifundefined{OpMode}{%
- \def\AM@driver{null}
- }{\gdef\AM@driver{vtex}}%
-}{\gdef\AM@driver{pdftex}}
-\endgroup
+\InputIfFileExists{pdfpages.cfg}{%
+ \PackageInfo{pdfpages}{Loading configuration file `pdfpages.cfg'}}{}
+% \end{macrocode}
+% These options overrule the automatic detection of the \TeX-engine.
+% \begin{macrocode}
+\DeclareOption{pdftex}{\def\AM@driver{pdftex}}
+\DeclareOption{vtex}{\def\AM@driver{vtex}}
+\DeclareOption{null}{\def\AM@driver{null}}
+\DeclareOption{xetex}{\def\AM@driver{xetex}}
% \end{macrocode}
-% Required Packages.
+% \begin{macrocode}
+\ProcessOptions
+% \end{macrocode}
+% \subsection{Detection of TeX-Engine}
+%
+% Automatic detection of \TeX-engine: \pdfTeX, \VTeX\ or \XeTeX.
+% This detection is omitted if |\AM@driver| is already defined. This
+% happens if the driver was given as a package option or if
+% the driver was identified in the configuration files |pdfpages.cfg|
+%
+% \begin{macrocode}
+\@ifundefined{AM@driver}{
+ \begingroup
+ \@ifundefined{pdftexversion}{%
+ \@ifundefined{XeTeXversion}{%
+ \@ifundefined{OpMode}{%
+ \def\AM@driver{null}
+ }{\gdef\AM@driver{vtex}}%
+ }{\gdef\AM@driver{xetex}}%
+ }{\gdef\AM@driver{pdftex}}
+ \endgroup
+}{}
+% \end{macrocode}
+% \subsection{Required Packages and Version Checking}
+%
% \begin{macrocode}
\RequirePackage{ifthen, graphicx, calc, eso-pic}
\newif\ifAM@DVIoutput\AM@DVIoutputfalse
@@ -1077,13 +1133,14 @@
\newcommand*{\AM@lscape@rot}{0}
\newcommand*{\AM@threadname}{}\newcommand*{\AM@linkname}{}
\newcommand*{\AM@linkname@option}{}
-\newcommand*{\AM@linkfit}{fit}\newcommand*{\AM@linktodocfit}{/Fit}
+\newcommand*{\AM@linktodocfit}{/Fit}
\newcommand*{\threadinfodict}{}
\newcommand*{\AM@toclist}{}\newcommand*{\AM@loflist}{}
\newcommand*{\AM@signature}{}
\newcommand*{\AM@ARBug@hook}{}
\newcommand*{\AM@xrprefix}{}
-\newcommand*{\AM@picturecommand}{}\newcommand*{\AM@picturecommandstar}{}
+\newcommand*{\AM@picturecommand}{}
+\newcommand*{\AM@picturecommandstar}{}
\newsavebox{\AM@pagebox}
% \end{macrocode}
% \macro{\AM@setlscape}
@@ -1128,17 +1185,17 @@
% \begin{macrocode}
\newcommand*{\AM@findfile@i}[2]{%
\let\AM@currentdocname\relax
- \IfFileExists{#1.#2}{\edef\AM@currentdocname{#1.#2}}{%
- \IfFileExists{#1}{\edef\AM@currentdocname{#1}}{%
+ \AM@IfFileExists{#1.#2}{\edef\AM@currentdocname{#1.#2}}{%
+ \AM@IfFileExists{#1}{\edef\AM@currentdocname{#1}}{%
\ifx\Ginput@path\@undefined\else
\expandafter\@tfor\expandafter\AM@dir\expandafter
:\expandafter=\Ginput@path\do{%
- \IfFileExists{\AM@dir#1.#2}{%
+ \AM@IfFileExists{\AM@dir#1.#2}{%
\ifx\AM@currentdocname\relax
\edef\AM@currentdocname{\AM@dir#1.#2}%
\fi
}{%
- \IfFileExists{\AM@dir#1}{%
+ \AM@IfFileExists{\AM@dir#1}{%
\ifx\AM@currentdocname\relax
\edef\AM@currentdocname{\AM@dir#1}%
\fi
@@ -1377,11 +1434,16 @@
\AM@split@options{Gin@noscale}{#1}%
\let\AM@filelist@save\@filelist
\ifAM@DVIoutput
- \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}}
+ \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}}%
\else
- \setbox\@tempboxa=\hbox{%
- \expandafter\includegraphics\expandafter[\the\@temptokena,
+ \ifAM@templatesize
+ \setbox\@tempboxa=\hbox{%
+ \rotatebox{\AM@lscape@rot}{\copy\AM@templatesizebox}}%
+ \else
+ \setbox\@tempboxa=\hbox{%
+ \expandafter\includegraphics\expandafter[\the\@temptokena,
page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}%
+ \fi
\fi
% \end{macrocode}
% Adjust the paper size.
@@ -1461,13 +1523,20 @@
% \begin{macrocode}
\let\AM@filelist@save\@filelist
\AM@split@options{Gin}{#1}%
- \setbox\@tempboxa=\hbox{%
- \expandafter\includegraphics\expandafter[\the\@temptokena,
- page=\AM@page, scale=\AM@globalscale,
- angle=\AM@lscape@rot]{\AM@docname}}%
+ \ifAM@templatesize
+ \setbox\@tempboxa=\hbox{%
+ \scalebox{\AM@globalscale}{\copy\AM@templatesizebox}}%
+ \setbox\@tempboxa=\hbox{%
+ \rotatebox{\AM@lscape@rot}{\copy\@tempboxa}}%
+ \else
+ \setbox\@tempboxa=\hbox{%
+ \expandafter\includegraphics\expandafter[\the\@temptokena,
+ page=\AM@page, scale=\AM@globalscale,
+ angle=\AM@lscape@rot]{\AM@docname}}%
+ \fi
\let\@filelist\AM@filelist@save
\edef\AM@templatewidth{\the\wd\@tempboxa}%
- \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}%
+ \setlength{\@tempdima}{\ht\@tempboxa + \dp\@tempboxa}%
\edef\AM@templateheight{\the\@tempdima}%
\setlength{\@tempdimb}{\ht\@tempboxa + \dp\@tempboxa}%
\def\AM@xmargin{%
@@ -1671,11 +1740,7 @@
% \end{macrocode}
% Calculate |fitr| coordinates, if |linkfit=region|.
% \begin{macrocode}
- \def\AM@region{region}%
- \ifx\AM@linkfit\AM@region
- \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}%
- \let\AM@linkfit\AM@linkfit@special
- \fi
+ \AM@region@calc
% \end{macrocode}
% Ship out page.
% \begin{macrocode}
@@ -1796,8 +1861,8 @@
\def\AM@doclist{}%
\AM@readlisti#1,\END,
\ifAM@defaultone\AM@append{1}\fi
- \edef\AM@doclist{\expandafter\@gobble\AM@doclist}%
- \edef\AM@pagelist{\expandafter\@gobble\AM@pagelist}%
+ \edef\AM@doclist{\expandafter\@gobble\AM@doclist\@empty}%
+ \edef\AM@pagelist{\expandafter\@gobble\AM@pagelist\@empty}%
}
% \end{macrocode}
% \begin{macrocode}
@@ -2281,7 +2346,8 @@
\newcommand{\AM@split@optionsii}{}
\def\AM@split@optionsii#1=#2\END{%
\edef\AM@temp{\AM@trim@space{#1}}%
- \ifthenelse{\equal{pages}{\AM@temp}\or
+ \ifthenelse{\equal{page}{\AM@temp}\or
+ \equal{pages}{\AM@temp}\or
\equal{nup}{\AM@temp}\or
\equal{deltax}{\AM@temp}\or
\equal{deltay}{\AM@temp}\or
@@ -2319,6 +2385,7 @@
\equal{signature*}{\AM@temp}\or
\equal{booklet}{\AM@temp}\or
\equal{pagetemplate}{\AM@temp}\or
+ \equal{templatesize}{\AM@temp}\or
\equal{rotateoversize}{\AM@temp}\or
\equal{picturecommand}{\AM@temp}\or
\equal{picturecommand*}{\AM@temp}\or
@@ -2368,7 +2435,6 @@
% Add hypertext operations (targets, links and threads) to
% the inserted pages.
% \begin{macrocode}
-
\newcommand{\AM@hyper@begin@i}{%
% \end{macrocode}
% Page is a target for a link.
@@ -2554,6 +2620,7 @@
\edef\AM@doclist{\expandafter\@gobble\AM@newdoclist}%
% \end{macrocode}
% \begin{macrocode}
+ \AM@pagesize@boogie
\ifdim\AM@pagewidth<\AM@pageheight
\def\AM@xnup{\@ne}\def\AM@ynup{\tw@}%
\else
@@ -2837,6 +2904,12 @@
% \end{macrocode}
% \subsection{Options of \texttt{\protect\bslash includepdf}}
% \begin{macrocode}
+\define@key{pdfpages}{page}{\PackageWarningNoLine{pdfpages}{%
+ Option `page' is unknow to \string\includepdf.\MessageBreak
+ Did you mean `pages'? (Note the `s'!)\MessageBreak
+ OK, I'll proceed as if it were `pages'}%
+ \AM@CheckValue{pages}{#1}%
+ \def\AM@pagestemp{#1}}
\define@key{pdfpages}{pages}{\AM@CheckValue{pages}{#1}%
\def\AM@pagestemp{#1}}
\define@key{pdfpages}{nup}{\AM@parse@nup#1x\END}
@@ -2857,7 +2930,8 @@
\define@key{pdfpages}{thread}[true]{\setboolean{AM@thread}{#1}}
\define@key{pdfpages}{threadname}{\def\AM@threadname{#1}}
\define@key{pdfpages}{link}[true]{\setboolean{AM@link}{#1}}
-\define@key{pdfpages}{linkfit}{\def\AM@linkfit{#1}}
+%\define@key{pdfpages}{linkfit}{\def\AM@linkfit{#1}}
+\define@key{pdfpages}{linkfit}{\AM@convert@dest{#1}}
\define@key{pdfpages}{linkname}{\def\AM@linkname@option{#1}}
\define@key{pdfpages}{linktodoc}[true]{\setboolean{AM@linktodoc}{#1}}
\define@key{pdfpages}{linktodocfit}{\def\AM@linktodocfit{#1}}
@@ -2901,6 +2975,7 @@
\def\AM@signature{x}}
\define@key{pdfpages}{pagetemplate}{\AM@CheckValue{pagetemplate}{#1}%
\def\AM@pagetemplate{#1}}
+\define@key{pdfpages}{templatesize}{\AM@parse@templatesize#1\END}
\define@key{pdfpages}{rotateoversize}[true]%
{\setboolean{AM@rotateoversize}{#1}}
\define@key{pdfpages}{picturecommand}{\def\AM@picturecommand{#1}}
@@ -2934,6 +3009,17 @@
}
\def\AM@parse@nupi#1x{\def\AM@ynup{#1}}
% \end{macrocode}
+% \macro{\AM@parse@templatesize}
+% Parsing \texttt{templatesize} item.
+% \begin{macrocode}
+\newcommand{\AM@parse@templatesize}{}
+\def\AM@parse@templatesize#1#2\END{%
+ \setbox\AM@templatesizebox=\hbox{\rule{#1}{#2}}
+ \AM@templatesizetrue
+}
+\newbox\AM@templatesizebox
+\newif\ifAM@templatesize\AM@templatesizefalse
+% \end{macrocode}
% \macro{\AM@parse@deltax}
% \macro{\AM@parse@deltay}
% \macro{\AM@parse@offset}
@@ -2978,12 +3064,14 @@
%
% \iffalse
%</package>
+% \fi
%
+% \subsection{Driver files}
+%
+% \iffalse
%<*pppdftexdef>
% \fi
%
-%
-% \subsection{Driver files}
% \subsubsection{\pdfTeX\ driver}
%
% Check \pdfTeX\ version and output.
@@ -3058,6 +3146,7 @@
\setlength{\pdfpagewidth}{\the\wd\@tempboxa}%
\setlength{\pdfpageheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
% \end{macrocode}
% Change paper size.
% \begin{macrocode}
@@ -3069,6 +3158,11 @@
\AM@findfile@i{#1}{pdf}%
\AM@findfile@ii{#1}%
}
+\AtBeginDocument{%
+\@ifpackageloaded{grffile}{%
+ \let\AM@IfFileExists\grffile@IfFileExists}{%
+ \let\AM@IfFileExists\IfFileExists}%
+}
% \end{macrocode}
% Rotate page.
% \begin{macrocode}
@@ -3111,12 +3205,73 @@
}
\let\AM@thread@special@end\relax
% \end{macrocode}
-% Destination for links.
+% Destination of links.
% \begin{macrocode}
-\def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@linkfit}
+\def\AM@view{fit}
+\def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@view}
\def\AM@anchor@special{\pdfdest name {pdfpages.\the\count1} fit}
-\edef\AM@linkfit@special{fitr width\the\wd\@tempboxa\space
- height0pt depth\the\@tempdima}
+% \end{macrocode}
+% Convert synatx of \PDF\ destinations.
+% \pdfTeX\ does not support positional parameters to |fith| etc.
+% \begin{macrocode}
+\def\AM@convert@dest#1{%
+ \expandafter\AM@convert@dest@i\ifdim\z@=0pt#1 \END\fi}
+\def\AM@convert@dest@i#1 #2\END{%
+ \begingroup
+ \def\tag{#1}%
+ \def\x{FitH}%
+ \ifx\x\tag
+ \gdef\AM@view{fith}%
+ \else
+ \def\x{FitBH}%
+ \ifx\x\tag
+ \gdef\AM@view{fitbh}%
+ \else
+ \def\x{FitV}%
+ \ifx\x\tag
+ \gdef\AM@view{fitv}%
+ \else
+ \def\x{FitBV}%
+ \ifx\x\tag
+ \gdef\AM@view{fitbv}%
+ \else
+ \def\x{FitR}%
+ \ifx\x\tag
+ \gdef\AM@view{fitr}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=FitR' is not supported,
+ I will try `linkfit=Region'.}%
+ \def\tag{region}%
+ \else
+ \def\x{FitB}%
+ \ifx\x\tag
+ \gdef\AM@view{fitb}%
+ \else
+ \def\x{XZY}%
+ \ifx\x\tag
+ \gdef\AM@view{xyz zoom #2}%
+ \else
+ \def\x{Region}%
+ \ifx\x\tag
+ \gdef\AM@view{fitr
+ width\the\wd\@tempboxa\space
+ height0pt depth\AM@region@depth}%
+ \else
+ \gdef\AM@view{fit}%
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \endgroup
+}
+\def\AM@region@calc{%
+ \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}
+ \edef\AM@region@depth{\the\@tempdima}
+}
% \end{macrocode}
% Do not disable |\includegraphics|.
% \begin{macrocode}
@@ -3131,6 +3286,19 @@
%
% \subsubsection{\VTeX\ driver}
%
+% Check if the graphics package was loaded with an
+% incompatible driver option (e.g. dvips).
+% \begin{macrocode}
+\begingroup
+\@ifundefined{ver@vtex.def}{%
+ \PackageError{pdfpages}
+ {The graphics package was loaded with driver\MessageBreak
+ `\Gin@driver', which cannot be used with VTeX}
+ {Check the driver option of the graphics package.}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput}{}
+\endgroup
+% \end{macrocode}
% Check \VTeX\ version.
% \begin{macrocode}
\ifnum\VTeXversion<822
@@ -3166,6 +3334,7 @@
\setlength{\mediawidth}{\the\wd\@tempboxa}%
\setlength{\mediaheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
% \end{macrocode}
% Rotate page.
% \begin{macrocode}
@@ -3188,6 +3357,7 @@
\fi
\AM@findfile@ii{#1}%
}
+\let\AM@IfFileExists\IfFileExists
% \end{macrocode}
% Link to original document.
% \begin{macrocode}
@@ -3216,12 +3386,14 @@
}
\def\AM@thread@special@end{\special{!endthread}}
% \end{macrocode}
-% Destination for links.
+% Destination of links.
% \begin{macrocode}
\def\AM@dest@special{\special{!aname \AM@linkname.\AM@page}}
\def\AM@anchor@special{\special{!aname pdfpages.\the\count1}}
-\edef\AM@linkfit@special{fit}%r width\the\wd\@tempboxa\space
- % height0pt depth\the\@tempdima}
+% \end{macrocode}
+% Convert synatx of \PDF\ destinations.
+% \begin{macrocode}
+\def\AM@convert@dest#1{}
% \end{macrocode}
% Do not disable |\includegraphics|.
% \begin{macrocode}
@@ -3231,6 +3403,214 @@
% \iffalse
%</ppvtexdef>
%
+%<*ppxetexdef>
+% \fi
+%
+% \subsubsection{\XeTeX\ driver}
+%
+% Check if the graphics package was loaded with an
+% incompatible driver option (e.g. dvips).
+% \begin{macrocode}
+\begingroup
+\@ifundefined{ver@xetex.def}{%
+ \PackageError{pdfpages}
+ {The graphics package was loaded with driver\MessageBreak
+ `\Gin@driver', which cannot be used with XeTeX}
+ {Check the driver option of the graphics package.}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput}{}
+\endgroup
+% \end{macrocode}
+% Packages like ngerman.sty make " with catcode 11 active. So let's
+% use " with catcode 12 to delimit arguments.
+% \begin{macrocode}
+{\catcode`\"=12
+ \gdef\AM@XeTeXquote{"}%
+}
+% \end{macrocode}
+% Get last page number.
+% \begin{macrocode}
+\def\AM@getpagecount{%
+ \edef\AM@pagecount{\the\XeTeXpdfpagecount\AM@XeTeXquote
+ \AM@currentdocname\AM@XeTeXquote\relax}%
+}
+% \end{macrocode}
+% \begin{macrocode}
+\begingroup
+\ifnum\XeTeXversion=0
+ \edef\temp{\expandafter\@gobble\XeTeXrevision}
+ \ifnum\temp<997
+ \PackageError{pdfpages}
+ {Package pdfpages requires at least XeTeX-0.997}
+ {Update your TeX distribution!}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput
+ \fi
+\fi
+\endgroup
+% \end{macrocode}
+% Page dimensions.
+% \begin{macrocode}
+\let\AM@pagewidth\pdfpagewidth
+\let\AM@pageheight\pdfpageheight
+\def\AM@setpagedimen{%
+ \setlength{\pdfpagewidth}{\the\wd\@tempboxa}%
+ \setlength{\pdfpageheight}{\the\ht\@tempboxa}%
+}
+\def\AM@pagesize@boogie{%
+ \ifdim\AM@pagewidth=\z@
+ \ifdim\AM@pageheight=\z@
+ \let\AM@pagewidth\paperwidth
+ \let\AM@pageheight\paperheight
+ \fi
+ \fi
+}
+% \end{macrocode}
+% Change paper size.
+% \begin{macrocode}
+\let\AM@fitpaper@special\relax
+% \end{macrocode}
+% Find file.
+% \begin{macrocode}
+\def\AM@findfile#1{%
+ \AM@findfile@i{#1}{pdf}%
+ \AM@findfile@ii{#1}%
+}
+\long\def\AM@IfFileExists#1#2#3{%
+ \openin\@inputcheck=\AM@XeTeXquote#1\AM@XeTeXquote\relax
+ \ifeof\@inputcheck
+ \ifx\input@path\@undefined
+ \def\reserved@a{#3}%
+ \else
+ \def\reserved@a{\@iffileonpath{#1}{#2}{#3}}%
+ \fi
+ \else
+ \closein\@inputcheck
+ \edef\@filef@und{#1 }%
+ \def\reserved@a{#2}%
+ \fi
+ \reserved@a}
+% \end{macrocode}
+% Rotate page.
+% \begin{macrocode}
+\def\AM@setlscape{\special{pdf: put @thispage << /Rotate 90 >>}}
+% \end{macrocode}
+% Link to original document.
+% \begin{macrocode}
+\def\AM@linktodoc@special@begin{%
+ \special{pdf: annot
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ << /Type /Annot
+ /Subtype /Link /Border [0 0 0]
+ /A << /S /GoToR
+ /F (\AM@linkfilename)
+ /D [\AM@linktodoc@page@m@ne \AM@linktodocfit]
+ \ifAM@newwindow/NewWindow true\fi >>
+ >>}%
+}
+\let\AM@linktodoc@special@end\relax
+% \end{macrocode}
+% Survey.
+% \begin{macrocode}
+\def\AM@survey@special@begin{%
+ \special{pdf: annot
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ << /Type /Annot
+ /Subtype /Link /Border [0 0 0]
+ /A << /S /GoTo
+ /D (pdfpages.\AM@linktodoc@page@m@ne) >>
+ >>}%
+}
+\let\AM@survey@special@end\relax
+% \end{macrocode}
+% Thread.
+% \begin{macrocode}
+\def\AM@thread@special@begin{%
+ \special{pdf: thread @\AM@threadname\space
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ <<\threadinfodict>>
+ }%
+}
+\let\AM@thread@special@end\relax
+% \end{macrocode}
+% Destination of links.
+% \begin{macrocode}
+\def\AM@view{/Fit}
+\def\AM@dest@special{%
+ \special{pdf: dest (\AM@linkname.\AM@page) [ @thispage \AM@view ]}}
+\def\AM@anchor@special{%
+ \special{pdf: dest (pdfpages.\the\count1) [ @thispage /Fit ]}}
+% \end{macrocode}
+% Convert synatx of \PDF\ destinations.
+% \begin{macrocode}
+\def\AM@convert@dest#1{%
+ \expandafter\AM@convert@dest@i\ifdim\z@=0pt#1 \END\fi}
+\def\AM@convert@dest@i#1 #2\END{%
+ \begingroup
+ \def\tag{#1}%
+ \def\x{FitH}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitH @ypos}%
+ \else
+ \def\x{FitBH}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitBH @ypos}%
+ \else
+ \def\x{FitV}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitV @xpos}%
+ \else
+ \def\x{FitBV}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitBV @xpos}%
+ \else
+ \def\x{fitr}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=FitR' is not supported.}%
+ \else
+ \def\x{FitB}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitB}%
+ \else
+ \def\x{XYZ}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \else
+ \def\x{Region}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=Region' is not supported by XeTeX.}%
+ \else
+ \gdef\AM@view{/Fit}%
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \endgroup
+}
+\def\AM@region@calc{}
+% \end{macrocode}
+% Do not disable |\includegraphics|.
+% \begin{macrocode}
+\let\AM@disable@includegraphics\relax
+% \end{macrocode}
+%
+% \iffalse
+%</ppxetexdef>
+%
%<*ppnulldef>
% \fi
%
@@ -3243,7 +3623,6 @@
I will use a dummy \string\includepdf\space command\MessageBreak
which will NOT insert any pages, because\MessageBreak
you are producing DVI output}
-% \iffalse
% \end{macrocode}
% Find file: the file must not exist for this dummy driver. Let's just
% set \cmd{\AM@currentdocname}.
@@ -3251,6 +3630,7 @@
\def\AM@findfile#1{%
\def\AM@currentdocname{#1}%
}
+\let\AM@IfFileExists\IfFileExists
% \end{macrocode}
% Get last page number.
% \begin{macrocode}
@@ -3258,8 +3638,8 @@
\ifx\AM@pagecount\AM@undefined
\PackageWarningNoLine{pdfpages}{%
I cannot determine the number of pages of the\MessageBreak
- included document, while in DVI mode. You can\MessageBreak
- use the option `lastpage' to give me a hint}%
+ included document, while being in DVI mode. You\MessageBreak
+ can use the option `lastpage' to give me a hint}%
\edef\AM@pagecount{1}%
\fi
}
@@ -3272,6 +3652,7 @@
\setlength{\paperwidth}{\the\wd\@tempboxa}%
\setlength{\paperheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
% \end{macrocode}
% Change paper size.
% \begin{macrocode}
@@ -3302,11 +3683,14 @@
\let\AM@thread@special@begin\relax
\let\AM@thread@special@end\relax
% \end{macrocode}
-% Destination for links.
+% Destination of links.
% \begin{macrocode}
\let\AM@dest@special\relax
\let\AM@anchor@special\relax
-\let\AM@linkfit@special\relax
+% \end{macrocode}
+% Convert synatx of \PDF\ destinations.
+% \begin{macrocode}
+\def\AM@convert@dest#1{}
% \end{macrocode}
% Disable |\includegraphics|.
% \begin{macrocode}
@@ -3318,6 +3702,9 @@
% \begin{macrocode}
\newcommand*{\AM@checkpagenumber}[1]{}
% \end{macrocode}
+% \begin{macrocode}
+\def\AM@region@calc{}
+% \end{macrocode}
%
% \iffalse
%</ppnulldef>
@@ -3405,7 +3792,6 @@
% \item Optimizations for a faster processing of signatures.
% \end{itemize}
%
-%
% \subsection*{2006/08/05 v0.4a}
% \begin{itemize}
% \item Support of \DVI\ mode: Insertion of empty pages instead of
@@ -3413,6 +3799,11 @@
% \item Option |lastpage| added.
% \end{itemize}
%
+% \subsection*{2007/04/21 v0.4b}
+% \begin{itemize}
+% \item Support of \XeTeX.
+% \end{itemize}
+%
%
% \Finale
%
@@ -3778,6 +4169,8 @@ This file demonstrates how to use the pdfpages package.
\generate{\usepreamble\package
\file{ppvtex.def}{\from{pdfpages.dtx}{ppvtexdef}}}
\generate{\usepreamble\package
+ \file{ppxetex.def}{\from{pdfpages.dtx}{ppxetexdef}}}
+\generate{\usepreamble\package
\file{ppnull.def}{\from{pdfpages.dtx}{ppnulldef}}}
%% \generate{\usepreamble\package
@@ -3800,6 +4193,7 @@ This file demonstrates how to use the pdfpages package.
\Msg{* \space\space pdfpages.sty}
\Msg{* \space\space pppdftex.def}
\Msg{* \space\space ppvtex.def}
+\Msg{* \space\space ppxetex.def}
\Msg{* \space\space ppnull.def}
\Msg{*}
\Msg{* To produce the documentation, run the following}
diff --git a/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins b/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins
index 8928d1701eb..433a249841a 100644
--- a/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins
+++ b/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins
@@ -46,6 +46,8 @@ This file demonstrates how to use the pdfpages package.
\generate{\usepreamble\package
\file{ppvtex.def}{\from{pdfpages.dtx}{ppvtexdef}}}
\generate{\usepreamble\package
+ \file{ppxetex.def}{\from{pdfpages.dtx}{ppxetexdef}}}
+\generate{\usepreamble\package
\file{ppnull.def}{\from{pdfpages.dtx}{ppnulldef}}}
%% \generate{\usepreamble\package
@@ -67,6 +69,7 @@ This file demonstrates how to use the pdfpages package.
\Msg{* \space\space pdfpages.sty}
\Msg{* \space\space pppdftex.def}
\Msg{* \space\space ppvtex.def}
+\Msg{* \space\space ppxetex.def}
\Msg{* \space\space ppnull.def}
\Msg{*}
\Msg{* To produce the documentation, run the following}
diff --git a/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty b/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty
index fdcd7dc8439..72ba894904c 100644
--- a/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty
+++ b/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty
@@ -10,25 +10,26 @@
%%
%% Copyright (C) 2001-2006 Andreas MATTHIAS
%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3c of this license or (at your option) any
-%% later version. The latest version of this license is in
+%% This work may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
-%% and version 1.3c or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
-%% The Current Maintainer of this work is Andreas Matthias <amat@kabsi.at>.
+%% The Current Maintainer of this work is
+%% Andreas Matthias <andreas.matthias@gmail.com>.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
-\def\AM@fileversion{v0.4a}
+\def\AM@fileversion{v0.4c}
\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
-\AM@SVN@Date$Date: 2006-08-12 01:13:35 +0200 (Sat, 12 Aug 2006) $
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{pdfpages}
[\AM@filedate\space\AM@fileversion\space
@@ -39,15 +40,25 @@
\DeclareOption{final}{\AM@pkg@draftfalse}
\DeclareOption{enable-survey}{\AM@pkg@surveytrue}
\DeclareOption{disable-survey}{\AM@pkg@surveyfalse}
-\ProcessOptions
\def\AM@ifdriverlater{\@ifl@ter{def}}
-\begingroup
-\@ifundefined{pdfoutput}{%
- \@ifundefined{OpMode}{%
- \def\AM@driver{null}
- }{\gdef\AM@driver{vtex}}%
-}{\gdef\AM@driver{pdftex}}
-\endgroup
+\InputIfFileExists{pdfpages.cfg}{%
+ \PackageInfo{pdfpages}{Loading configuration file `pdfpages.cfg'}}{}
+\DeclareOption{pdftex}{\def\AM@driver{pdftex}}
+\DeclareOption{vtex}{\def\AM@driver{vtex}}
+\DeclareOption{null}{\def\AM@driver{null}}
+\DeclareOption{xetex}{\def\AM@driver{xetex}}
+\ProcessOptions
+\@ifundefined{AM@driver}{
+ \begingroup
+ \@ifundefined{pdftexversion}{%
+ \@ifundefined{XeTeXversion}{%
+ \@ifundefined{OpMode}{%
+ \def\AM@driver{null}
+ }{\gdef\AM@driver{vtex}}%
+ }{\gdef\AM@driver{xetex}}%
+ }{\gdef\AM@driver{pdftex}}
+ \endgroup
+}{}
\RequirePackage{ifthen, graphicx, calc, eso-pic}
\newif\ifAM@DVIoutput\AM@DVIoutputfalse
\input{pp\AM@driver.def}
@@ -98,13 +109,14 @@
\newcommand*{\AM@lscape@rot}{0}
\newcommand*{\AM@threadname}{}\newcommand*{\AM@linkname}{}
\newcommand*{\AM@linkname@option}{}
-\newcommand*{\AM@linkfit}{fit}\newcommand*{\AM@linktodocfit}{/Fit}
+\newcommand*{\AM@linktodocfit}{/Fit}
\newcommand*{\threadinfodict}{}
\newcommand*{\AM@toclist}{}\newcommand*{\AM@loflist}{}
\newcommand*{\AM@signature}{}
\newcommand*{\AM@ARBug@hook}{}
\newcommand*{\AM@xrprefix}{}
-\newcommand*{\AM@picturecommand}{}\newcommand*{\AM@picturecommandstar}{}
+\newcommand*{\AM@picturecommand}{}
+\newcommand*{\AM@picturecommandstar}{}
\newsavebox{\AM@pagebox}
\newif\ifAM@thumbpdf
\newif\ifAM@pdflscape
@@ -134,17 +146,17 @@
}
\newcommand*{\AM@findfile@i}[2]{%
\let\AM@currentdocname\relax
- \IfFileExists{#1.#2}{\edef\AM@currentdocname{#1.#2}}{%
- \IfFileExists{#1}{\edef\AM@currentdocname{#1}}{%
+ \AM@IfFileExists{#1.#2}{\edef\AM@currentdocname{#1.#2}}{%
+ \AM@IfFileExists{#1}{\edef\AM@currentdocname{#1}}{%
\ifx\Ginput@path\@undefined\else
\expandafter\@tfor\expandafter\AM@dir\expandafter
:\expandafter=\Ginput@path\do{%
- \IfFileExists{\AM@dir#1.#2}{%
+ \AM@IfFileExists{\AM@dir#1.#2}{%
\ifx\AM@currentdocname\relax
\edef\AM@currentdocname{\AM@dir#1.#2}%
\fi
}{%
- \IfFileExists{\AM@dir#1}{%
+ \AM@IfFileExists{\AM@dir#1}{%
\ifx\AM@currentdocname\relax
\edef\AM@currentdocname{\AM@dir#1}%
\fi
@@ -312,11 +324,16 @@
\AM@split@options{Gin@noscale}{#1}%
\let\AM@filelist@save\@filelist
\ifAM@DVIoutput
- \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}}
+ \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}}%
\else
- \setbox\@tempboxa=\hbox{%
- \expandafter\includegraphics\expandafter[\the\@temptokena,
+ \ifAM@templatesize
+ \setbox\@tempboxa=\hbox{%
+ \rotatebox{\AM@lscape@rot}{\copy\AM@templatesizebox}}%
+ \else
+ \setbox\@tempboxa=\hbox{%
+ \expandafter\includegraphics\expandafter[\the\@temptokena,
page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}%
+ \fi
\fi
\ifthenelse{\boolean{AM@fitpaper}}
{\setlength{\AM@pagewidth}{\the\wd\@tempboxa}%
@@ -372,13 +389,20 @@
\fi
\let\AM@filelist@save\@filelist
\AM@split@options{Gin}{#1}%
- \setbox\@tempboxa=\hbox{%
- \expandafter\includegraphics\expandafter[\the\@temptokena,
- page=\AM@page, scale=\AM@globalscale,
- angle=\AM@lscape@rot]{\AM@docname}}%
+ \ifAM@templatesize
+ \setbox\@tempboxa=\hbox{%
+ \scalebox{\AM@globalscale}{\copy\AM@templatesizebox}}%
+ \setbox\@tempboxa=\hbox{%
+ \rotatebox{\AM@lscape@rot}{\copy\@tempboxa}}%
+ \else
+ \setbox\@tempboxa=\hbox{%
+ \expandafter\includegraphics\expandafter[\the\@temptokena,
+ page=\AM@page, scale=\AM@globalscale,
+ angle=\AM@lscape@rot]{\AM@docname}}%
+ \fi
\let\@filelist\AM@filelist@save
\edef\AM@templatewidth{\the\wd\@tempboxa}%
- \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}%
+ \setlength{\@tempdima}{\ht\@tempboxa + \dp\@tempboxa}%
\edef\AM@templateheight{\the\@tempdima}%
\setlength{\@tempdimb}{\ht\@tempboxa + \dp\@tempboxa}%
\def\AM@xmargin{%
@@ -550,11 +574,7 @@
\setlength{\@tempdima}{\AM@ypos}%
\edef\AM@ypos{\strip@pt\@tempdima}%
\setlength{\fboxsep}{\z@}%
- \def\AM@region{region}%
- \ifx\AM@linkfit\AM@region
- \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}%
- \let\AM@linkfit\AM@linkfit@special
- \fi
+ \AM@region@calc
\ifAM@phantompage
\def\AM@shippage{}%
\else
@@ -640,8 +660,8 @@
\def\AM@doclist{}%
\AM@readlisti#1,\END,
\ifAM@defaultone\AM@append{1}\fi
- \edef\AM@doclist{\expandafter\@gobble\AM@doclist}%
- \edef\AM@pagelist{\expandafter\@gobble\AM@pagelist}%
+ \edef\AM@doclist{\expandafter\@gobble\AM@doclist\@empty}%
+ \edef\AM@pagelist{\expandafter\@gobble\AM@pagelist\@empty}%
}
\newcommand{\AM@readlisti}{}
\def\AM@readlisti#1,{%
@@ -987,7 +1007,8 @@
\newcommand{\AM@split@optionsii}{}
\def\AM@split@optionsii#1=#2\END{%
\edef\AM@temp{\AM@trim@space{#1}}%
- \ifthenelse{\equal{pages}{\AM@temp}\or
+ \ifthenelse{\equal{page}{\AM@temp}\or
+ \equal{pages}{\AM@temp}\or
\equal{nup}{\AM@temp}\or
\equal{deltax}{\AM@temp}\or
\equal{deltay}{\AM@temp}\or
@@ -1025,6 +1046,7 @@
\equal{signature*}{\AM@temp}\or
\equal{booklet}{\AM@temp}\or
\equal{pagetemplate}{\AM@temp}\or
+ \equal{templatesize}{\AM@temp}\or
\equal{rotateoversize}{\AM@temp}\or
\equal{picturecommand}{\AM@temp}\or
\equal{picturecommand*}{\AM@temp}\or
@@ -1053,7 +1075,6 @@
\AM@phantompagefalse
\fi
}
-
\newcommand{\AM@hyper@begin@i}{%
\ifAM@link \AM@dest@special\fi
}
@@ -1185,6 +1206,7 @@
\AM@sort
\edef\AM@pagelist{\expandafter\@gobble\AM@newpagelist}%
\edef\AM@doclist{\expandafter\@gobble\AM@newdoclist}%
+ \AM@pagesize@boogie
\ifdim\AM@pagewidth<\AM@pageheight
\def\AM@xnup{\@ne}\def\AM@ynup{\tw@}%
\else
@@ -1382,6 +1404,12 @@
{Option `#1' must have a non-empty value}%
\fi
}
+\define@key{pdfpages}{page}{\PackageWarningNoLine{pdfpages}{%
+ Option `page' is unknow to \string\includepdf.\MessageBreak
+ Did you mean `pages'? (Note the `s'!)\MessageBreak
+ OK, I'll proceed as if it were `pages'}%
+ \AM@CheckValue{pages}{#1}%
+ \def\AM@pagestemp{#1}}
\define@key{pdfpages}{pages}{\AM@CheckValue{pages}{#1}%
\def\AM@pagestemp{#1}}
\define@key{pdfpages}{nup}{\AM@parse@nup#1x\END}
@@ -1402,7 +1430,7 @@
\define@key{pdfpages}{thread}[true]{\setboolean{AM@thread}{#1}}
\define@key{pdfpages}{threadname}{\def\AM@threadname{#1}}
\define@key{pdfpages}{link}[true]{\setboolean{AM@link}{#1}}
-\define@key{pdfpages}{linkfit}{\def\AM@linkfit{#1}}
+\define@key{pdfpages}{linkfit}{\AM@convert@dest{#1}}
\define@key{pdfpages}{linkname}{\def\AM@linkname@option{#1}}
\define@key{pdfpages}{linktodoc}[true]{\setboolean{AM@linktodoc}{#1}}
\define@key{pdfpages}{linktodocfit}{\def\AM@linktodocfit{#1}}
@@ -1446,6 +1474,7 @@
\def\AM@signature{x}}
\define@key{pdfpages}{pagetemplate}{\AM@CheckValue{pagetemplate}{#1}%
\def\AM@pagetemplate{#1}}
+\define@key{pdfpages}{templatesize}{\AM@parse@templatesize#1\END}
\define@key{pdfpages}{rotateoversize}[true]%
{\setboolean{AM@rotateoversize}{#1}}
\define@key{pdfpages}{picturecommand}{\def\AM@picturecommand{#1}}
@@ -1474,6 +1503,13 @@
\fi
}
\def\AM@parse@nupi#1x{\def\AM@ynup{#1}}
+\newcommand{\AM@parse@templatesize}{}
+\def\AM@parse@templatesize#1#2\END{%
+ \setbox\AM@templatesizebox=\hbox{\rule{#1}{#2}}
+ \AM@templatesizetrue
+}
+\newbox\AM@templatesizebox
+\newif\ifAM@templatesize\AM@templatesizefalse
\def\AM@parse@deltax#1 #2\\{\AMGin@defaultbp\AM@deltax{#1}}
\def\AM@parse@deltay#1 #2\\{\AMGin@defaultbp\AM@deltay{#1}}
\def\AM@parse@delta#1 #2 #3\\{%
diff --git a/Master/texmf-dist/tex/latex/pdfpages/ppnull.def b/Master/texmf-dist/tex/latex/pdfpages/ppnull.def
index a538bc80221..4782b9f2258 100644
--- a/Master/texmf-dist/tex/latex/pdfpages/ppnull.def
+++ b/Master/texmf-dist/tex/latex/pdfpages/ppnull.def
@@ -10,28 +10,29 @@
%%
%% Copyright (C) 2001-2006 Andreas MATTHIAS
%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3c of this license or (at your option) any
-%% later version. The latest version of this license is in
+%% This work may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
-%% and version 1.3c or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
-%% The Current Maintainer of this work is Andreas Matthias <amat@kabsi.at>.
+%% The Current Maintainer of this work is
+%% Andreas Matthias <andreas.matthias@gmail.com>.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
-\def\AM@fileversion{v0.4a}
+\def\AM@fileversion{v0.4c}
\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
-\AM@SVN@Date$Date: 2006-08-12 01:13:35 +0200 (Sat, 12 Aug 2006) $
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
\ProvidesFile{ppnull.def}
[\AM@filedate\space\AM@fileversion\space
- Pdfpages' dummy driver (AM)]
+ Pdfpages dummy driver (AM)]
\AM@DVIoutputtrue
\PackageWarningNoLine{pdfpages}{%
I will use a dummy \string\includepdf\space command\MessageBreak
@@ -40,12 +41,13 @@
\def\AM@findfile#1{%
\def\AM@currentdocname{#1}%
}
+\let\AM@IfFileExists\IfFileExists
\def\AM@getpagecount{%
\ifx\AM@pagecount\AM@undefined
\PackageWarningNoLine{pdfpages}{%
I cannot determine the number of pages of the\MessageBreak
- included document, while in DVI mode. You can\MessageBreak
- use the option `lastpage' to give me a hint}%
+ included document, while being in DVI mode. You\MessageBreak
+ can use the option `lastpage' to give me a hint}%
\edef\AM@pagecount{1}%
\fi
}
@@ -55,6 +57,7 @@
\setlength{\paperwidth}{\the\wd\@tempboxa}%
\setlength{\paperheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
\let\AM@fitpaper@special\relax
\def\AM@findfile#1{%
\def\AM@currentdocname{}%
@@ -68,11 +71,12 @@
\let\AM@thread@special@end\relax
\let\AM@dest@special\relax
\let\AM@anchor@special\relax
-\let\AM@linkfit@special\relax
+\def\AM@convert@dest#1{}
\def\AM@disable@includegraphics{%
\renewcommand\includegraphics[2][]{}%
}
\newcommand*{\AM@checkpagenumber}[1]{}
+\def\AM@region@calc{}
\endinput
%%
%% End of file `ppnull.def'.
diff --git a/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def b/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def
index 537326f7008..dc9c03569ce 100644
--- a/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def
+++ b/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def
@@ -10,25 +10,26 @@
%%
%% Copyright (C) 2001-2006 Andreas MATTHIAS
%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3c of this license or (at your option) any
-%% later version. The latest version of this license is in
+%% This work may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
-%% and version 1.3c or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
-%% The Current Maintainer of this work is Andreas Matthias <amat@kabsi.at>.
+%% The Current Maintainer of this work is
+%% Andreas Matthias <andreas.matthias@gmail.com>.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
-\def\AM@fileversion{v0.4a}
+\def\AM@fileversion{v0.4c}
\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
-\AM@SVN@Date$Date: 2006-08-12 01:13:35 +0200 (Sat, 12 Aug 2006) $
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
\ProvidesFile{pppdftex.def}
[\AM@filedate\space\AM@fileversion\space
Pdfpages driver for pdfTeX (AM)]
@@ -75,11 +76,17 @@
\setlength{\pdfpagewidth}{\the\wd\@tempboxa}%
\setlength{\pdfpageheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
\let\AM@fitpaper@special\relax
\def\AM@findfile#1{%
\AM@findfile@i{#1}{pdf}%
\AM@findfile@ii{#1}%
}
+\AtBeginDocument{%
+\@ifpackageloaded{grffile}{%
+ \let\AM@IfFileExists\grffile@IfFileExists}{%
+ \let\AM@IfFileExists\IfFileExists}%
+}
\def\AM@setlscape{\pdfpageattr{/Rotate 90}}
\def\AM@linktodoc@special@begin{%
\pdfannot width \wd\@tempboxa
@@ -109,10 +116,67 @@
name {\AM@threadname}%
}
\let\AM@thread@special@end\relax
-\def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@linkfit}
+\def\AM@view{fit}
+\def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@view}
\def\AM@anchor@special{\pdfdest name {pdfpages.\the\count1} fit}
-\edef\AM@linkfit@special{fitr width\the\wd\@tempboxa\space
- height0pt depth\the\@tempdima}
+\def\AM@convert@dest#1{%
+ \expandafter\AM@convert@dest@i\ifdim\z@=0pt#1 \END\fi}
+\def\AM@convert@dest@i#1 #2\END{%
+ \begingroup
+ \def\tag{#1}%
+ \def\x{FitH}%
+ \ifx\x\tag
+ \gdef\AM@view{fith}%
+ \else
+ \def\x{FitBH}%
+ \ifx\x\tag
+ \gdef\AM@view{fitbh}%
+ \else
+ \def\x{FitV}%
+ \ifx\x\tag
+ \gdef\AM@view{fitv}%
+ \else
+ \def\x{FitBV}%
+ \ifx\x\tag
+ \gdef\AM@view{fitbv}%
+ \else
+ \def\x{FitR}%
+ \ifx\x\tag
+ \gdef\AM@view{fitr}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=FitR' is not supported,
+ I will try `linkfit=Region'.}%
+ \def\tag{region}%
+ \else
+ \def\x{FitB}%
+ \ifx\x\tag
+ \gdef\AM@view{fitb}%
+ \else
+ \def\x{XZY}%
+ \ifx\x\tag
+ \gdef\AM@view{xyz zoom #2}%
+ \else
+ \def\x{Region}%
+ \ifx\x\tag
+ \gdef\AM@view{fitr
+ width\the\wd\@tempboxa\space
+ height0pt depth\AM@region@depth}%
+ \else
+ \gdef\AM@view{fit}%
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \endgroup
+}
+\def\AM@region@calc{%
+ \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}
+ \edef\AM@region@depth{\the\@tempdima}
+}
\let\AM@disable@includegraphics\relax
\endinput
%%
diff --git a/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def b/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def
index 484a1aa121d..0955985d642 100644
--- a/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def
+++ b/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def
@@ -10,28 +10,38 @@
%%
%% Copyright (C) 2001-2006 Andreas MATTHIAS
%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3c of this license or (at your option) any
-%% later version. The latest version of this license is in
+%% This work may be distributed and/or modified under the conditions
+%% of the LaTeX Project Public License, either version 1.3
+%% of this license or (at your option) any later version.
+%% The latest version of this license is in
%% http://www.latex-project.org/lppl.txt
-%% and version 1.3c or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
+%% and version 1.3 or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
-%% The Current Maintainer of this work is Andreas Matthias <amat@kabsi.at>.
+%% The Current Maintainer of this work is
+%% Andreas Matthias <andreas.matthias@gmail.com>.
%%
%% Please send error reports and suggestions for improvements to
-%% Andreas MATTHIAS <amat@kabsi.at>.
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
-\def\AM@fileversion{v0.4a}
+\def\AM@fileversion{v0.4c}
\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
-\AM@SVN@Date$Date: 2006-08-12 01:13:35 +0200 (Sat, 12 Aug 2006) $
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
\ProvidesFile{ppvtex.def}
[\AM@filedate\space\AM@fileversion\space
Pdfpages driver for VTeX (AM)]
+\begingroup
+\@ifundefined{ver@vtex.def}{%
+ \PackageError{pdfpages}
+ {The graphics package was loaded with driver\MessageBreak
+ `\Gin@driver', which cannot be used with VTeX}
+ {Check the driver option of the graphics package.}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput}{}
+\endgroup
\ifnum\VTeXversion<822
\PackageError{pdfpages}
{Package pdfpages requires at least\MessageBreak
@@ -56,6 +66,7 @@
\setlength{\mediawidth}{\the\wd\@tempboxa}%
\setlength{\mediaheight}{\the\ht\@tempboxa}%
}
+\let\AM@pagesize@boogie\relax
\def\AM@setlscape{\special{pS:
[{ThisPage}\string<\string</Rotate 90\string>\string>%]
/PUT pdfmark}%
@@ -69,6 +80,7 @@
\fi
\AM@findfile@ii{#1}%
}
+\let\AM@IfFileExists\IfFileExists
\def\AM@linktodoc@special@begin{%
\special{!aref <\ifAM@newwindow n\fi
f=\AM@linkfilename>!\AM@linktodoc@page;
@@ -89,8 +101,7 @@
\def\AM@thread@special@end{\special{!endthread}}
\def\AM@dest@special{\special{!aname \AM@linkname.\AM@page}}
\def\AM@anchor@special{\special{!aname pdfpages.\the\count1}}
-\edef\AM@linkfit@special{fit}%r width\the\wd\@tempboxa\space
- % height0pt depth\the\@tempdima}
+\def\AM@convert@dest#1{}
\let\AM@disable@includegraphics\relax
\endinput
%%
diff --git a/Master/texmf-dist/tex/latex/pdfpages/ppxetex.def b/Master/texmf-dist/tex/latex/pdfpages/ppxetex.def
new file mode 100644
index 00000000000..ebde43c152b
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/pdfpages/ppxetex.def
@@ -0,0 +1,180 @@
+%%
+%% This is file `ppxetex.def',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% pdfpages.dtx (with options: `ppxetexdef')
+%%
+%% This file is part of the pdfpages package.
+%%
+%%
+%% Please send error reports and suggestions for improvements to
+%% Andreas MATTHIAS <andreas.matthias@gmail.com>.
+%%
+\def\AM@fileversion{v0.4c}
+\def\AM@SVN@Date@i#1-#2-#3\END{\def\AM@filedate{#1/#2/#3}}
+\def\AM@SVN@Date$Date: #1 #2${\AM@SVN@Date@i#1\END}
+\AM@SVN@Date$Date: 2008-04-01 17:31:14 +0200 (Tue, 01 Apr 2008) $
+\ProvidesFile{ppxetex.def}
+ [\AM@filedate\space\AM@fileversion\space
+ Pdfpages driver for XeTeX (AM)]
+\begingroup
+\@ifundefined{ver@xetex.def}{%
+ \PackageError{pdfpages}
+ {The graphics package was loaded with driver\MessageBreak
+ `\Gin@driver', which cannot be used with XeTeX}
+ {Check the driver option of the graphics package.}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput}{}
+\endgroup
+{\catcode`\"=12
+ \gdef\AM@XeTeXquote{"}%
+}
+\def\AM@getpagecount{%
+ \edef\AM@pagecount{\the\XeTeXpdfpagecount\AM@XeTeXquote
+ \AM@currentdocname\AM@XeTeXquote\relax}%
+}
+\begingroup
+\ifnum\XeTeXversion=0
+ \edef\temp{\expandafter\@gobble\XeTeXrevision}
+ \ifnum\temp<997
+ \PackageError{pdfpages}
+ {Package pdfpages requires at least XeTeX-0.997}
+ {Update your TeX distribution!}
+ \global\let\AM@endinput\relax
+ \aftergroup\endinput
+ \fi
+\fi
+\endgroup
+\let\AM@pagewidth\pdfpagewidth
+\let\AM@pageheight\pdfpageheight
+\def\AM@setpagedimen{%
+ \setlength{\pdfpagewidth}{\the\wd\@tempboxa}%
+ \setlength{\pdfpageheight}{\the\ht\@tempboxa}%
+}
+\def\AM@pagesize@boogie{%
+ \ifdim\AM@pagewidth=\z@
+ \ifdim\AM@pageheight=\z@
+ \let\AM@pagewidth\paperwidth
+ \let\AM@pageheight\paperheight
+ \fi
+ \fi
+}
+\let\AM@fitpaper@special\relax
+\def\AM@findfile#1{%
+ \AM@findfile@i{#1}{pdf}%
+ \AM@findfile@ii{#1}%
+}
+\long\def\AM@IfFileExists#1#2#3{%
+ \openin\@inputcheck=\AM@XeTeXquote#1\AM@XeTeXquote\relax
+ \ifeof\@inputcheck
+ \ifx\input@path\@undefined
+ \def\reserved@a{#3}%
+ \else
+ \def\reserved@a{\@iffileonpath{#1}{#2}{#3}}%
+ \fi
+ \else
+ \closein\@inputcheck
+ \edef\@filef@und{#1 }%
+ \def\reserved@a{#2}%
+ \fi
+ \reserved@a}
+\def\AM@setlscape{\special{pdf: put @thispage << /Rotate 90 >>}}
+\def\AM@linktodoc@special@begin{%
+ \special{pdf: annot
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ << /Type /Annot
+ /Subtype /Link /Border [0 0 0]
+ /A << /S /GoToR
+ /F (\AM@linkfilename)
+ /D [\AM@linktodoc@page@m@ne \AM@linktodocfit]
+ \ifAM@newwindow/NewWindow true\fi >>
+ >>}%
+}
+\let\AM@linktodoc@special@end\relax
+\def\AM@survey@special@begin{%
+ \special{pdf: annot
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ << /Type /Annot
+ /Subtype /Link /Border [0 0 0]
+ /A << /S /GoTo
+ /D (pdfpages.\AM@linktodoc@page@m@ne) >>
+ >>}%
+}
+\let\AM@survey@special@end\relax
+\def\AM@thread@special@begin{%
+ \special{pdf: thread @\AM@threadname\space
+ width \the\wd\@tempboxa\space
+ height \the\ht\@tempboxa\space
+ depth \the\dp\@tempboxa\space
+ <<\threadinfodict>>
+ }%
+}
+\let\AM@thread@special@end\relax
+\def\AM@view{/Fit}
+\def\AM@dest@special{%
+ \special{pdf: dest (\AM@linkname.\AM@page) [ @thispage \AM@view ]}}
+\def\AM@anchor@special{%
+ \special{pdf: dest (pdfpages.\the\count1) [ @thispage /Fit ]}}
+\def\AM@convert@dest#1{%
+ \expandafter\AM@convert@dest@i\ifdim\z@=0pt#1 \END\fi}
+\def\AM@convert@dest@i#1 #2\END{%
+ \begingroup
+ \def\tag{#1}%
+ \def\x{FitH}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitH @ypos}%
+ \else
+ \def\x{FitBH}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitBH @ypos}%
+ \else
+ \def\x{FitV}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitV @xpos}%
+ \else
+ \def\x{FitBV}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitBV @xpos}%
+ \else
+ \def\x{fitr}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=FitR' is not supported.}%
+ \else
+ \def\x{FitB}%
+ \ifx\x\tag
+ \gdef\AM@view{/FitB}%
+ \else
+ \def\x{XYZ}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \else
+ \def\x{Region}%
+ \ifx\x\tag
+ \gdef\AM@view{/XYZ @xpos @ypos null}%
+ \PackageWarningNoLine{pdfpages}{%
+ `linkfit=Region' is not supported by XeTeX.}%
+ \else
+ \gdef\AM@view{/Fit}%
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \fi
+ \endgroup
+}
+\def\AM@region@calc{}
+\let\AM@disable@includegraphics\relax
+\endinput
+%%
+%% End of file `ppxetex.def'.