From 29d07a8cd3db51f6eeecc9b1d2cc4d8fd9c7466b Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 14 Aug 2006 23:00:18 +0000 Subject: pdfpages 0.4a (14aug06) git-svn-id: svn://tug.org/texlive/trunk@1958 c570f23f-e606-0410-a88d-b1316a301751 --- Build/tools/tpm-ctan-check | 2 +- Master/texmf-dist/doc/latex/pdfpages/README | 30 + Master/texmf-dist/doc/latex/pdfpages/dummy.pdf | Bin 17192 -> 30894 bytes Master/texmf-dist/doc/latex/pdfpages/pdf-ex.pdf | Bin 72702 -> 0 bytes Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex | 6 +- Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf | Bin 65363 -> 0 bytes Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex | 6 +- Master/texmf-dist/doc/latex/pdfpages/pdf-toc.pdf | Bin 64786 -> 0 bytes Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex | 6 +- Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf | Bin 167950 -> 177657 bytes Master/texmf-dist/doc/latex/pdfpages/pic.tex | 75 --- Master/texmf-dist/doc/latex/pdfpages/readme | 28 - .../texmf-dist/source/latex/pdfpages/pdfpages.dtx | 668 ++++++++++++++++----- .../texmf-dist/source/latex/pdfpages/pdfpages.ins | 52 +- Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty | 192 +++--- Master/texmf-dist/tex/latex/pdfpages/ppnull.def | 78 +++ Master/texmf-dist/tex/latex/pdfpages/pppdftex.def | 35 +- Master/texmf-dist/tex/latex/pdfpages/ppvtex.def | 29 +- Master/texmf-dist/tpm/pdfpages.tpm | 15 +- Master/texmf/lists/pdfpages | 7 +- 20 files changed, 837 insertions(+), 392 deletions(-) create mode 100644 Master/texmf-dist/doc/latex/pdfpages/README delete mode 100644 Master/texmf-dist/doc/latex/pdfpages/pdf-ex.pdf delete mode 100644 Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf delete mode 100644 Master/texmf-dist/doc/latex/pdfpages/pdf-toc.pdf delete mode 100644 Master/texmf-dist/doc/latex/pdfpages/pic.tex delete mode 100644 Master/texmf-dist/doc/latex/pdfpages/readme create mode 100644 Master/texmf-dist/tex/latex/pdfpages/ppnull.def diff --git a/Build/tools/tpm-ctan-check b/Build/tools/tpm-ctan-check index 266885411f6..09712dd8224 100755 --- a/Build/tools/tpm-ctan-check +++ b/Build/tools/tpm-ctan-check @@ -69,7 +69,7 @@ sub main nag ncclatex ncctools newlfm noitcrul nomencl nomentbl ntheorem-vn numprint oberdiek octavo - pauldoc pdf-trans pdfcprot pdftex-def perception + pauldoc pdf-trans pdfcprot pdfpages pdftex-def perception perltex pgf pictex pict2e placeins polynom poemscol powerdot powerdot-doc-vn ppr-prv pracjourn preview probsoln proof pstricks pstricks-add diff --git a/Master/texmf-dist/doc/latex/pdfpages/README b/Master/texmf-dist/doc/latex/pdfpages/README new file mode 100644 index 00000000000..2cac22941c8 --- /dev/null +++ b/Master/texmf-dist/doc/latex/pdfpages/README @@ -0,0 +1,30 @@ + +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 . + + + Andreas MATTHIAS + amat@kabsi.at diff --git a/Master/texmf-dist/doc/latex/pdfpages/dummy.pdf b/Master/texmf-dist/doc/latex/pdfpages/dummy.pdf index 95b4dc7ae7f..8f9c259446e 100644 Binary files a/Master/texmf-dist/doc/latex/pdfpages/dummy.pdf and b/Master/texmf-dist/doc/latex/pdfpages/dummy.pdf differ diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.pdf b/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.pdf deleted file mode 100644 index 787260d25a2..00000000000 Binary files a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.pdf and /dev/null differ diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex index 2dbfdc5a32e..0c1093a325b 100644 --- a/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex +++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-ex.tex @@ -6,13 +6,11 @@ %% %% pdfpages.dtx (with options: `example1') %% -%% This file is a demonstration of the pdfpages package. -%% Run it through pdfLaTeX. -%% +%% This file demonstrates how to use the pdfpages package. +%% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% - \documentclass[a4paper,12pt]{article} \usepackage[final]{pdfpages} \usepackage{verbatim} diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf b/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf deleted file mode 100644 index 6703e24d0e4..00000000000 Binary files a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf and /dev/null differ diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex index 1d737651a18..777a3bce272 100644 --- a/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex +++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-hyp.tex @@ -6,13 +6,11 @@ %% %% pdfpages.dtx (with options: `example2') %% -%% This file is a demonstration of the pdfpages package. -%% Run it through pdfLaTeX. -%% +%% This file demonstrates how to use the pdfpages package. +%% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% - \documentclass[a4paper,12pt]{article} \usepackage[final]{pdfpages} \usepackage{verbatim} diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.pdf b/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.pdf deleted file mode 100644 index fbce61ae48b..00000000000 Binary files a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.pdf and /dev/null differ diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex b/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex index ac07ed3040a..b41a1abb0dd 100644 --- a/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex +++ b/Master/texmf-dist/doc/latex/pdfpages/pdf-toc.tex @@ -6,13 +6,11 @@ %% %% pdfpages.dtx (with options: `example3') %% -%% This file is a demonstration of the pdfpages package. -%% Run it through pdfLaTeX. -%% +%% This file demonstrates how to use the pdfpages package. +%% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% - \documentclass[a4paper]{book} \usepackage{pdfpages} \usepackage{verbatim} diff --git a/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf b/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf index b4e224e7976..b37f151d7ce 100644 Binary files a/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf and b/Master/texmf-dist/doc/latex/pdfpages/pdfpages.pdf differ diff --git a/Master/texmf-dist/doc/latex/pdfpages/pic.tex b/Master/texmf-dist/doc/latex/pdfpages/pic.tex deleted file mode 100644 index 26a448743c5..00000000000 --- a/Master/texmf-dist/doc/latex/pdfpages/pic.tex +++ /dev/null @@ -1,75 +0,0 @@ -\setlength{\unitlength}{.7mm} -\def\thick{.7pt} -\def\thin{.2pt} -%^^A\fbox{ -\begin{picture}(145,238) - \small -\put(0,33){ - \linethickness{\thick} - \put(0,0){\framebox(145,205){}} - \linethickness{\thin} - \put(10,15){\dashbox(35,49){}} - \put(55,15){\dashbox(35,49){}} - \put(100,15){\dashbox(35,49){}} - \put(10,78){\dashbox(35,49){}} - \put(55,78){\dashbox(35,49){}} - \put(100,78){\dashbox(35,49){}} - \put(10,141){\dashbox(35,49){}} - \put(55,141){\dashbox(35,49){}} - \put(100,141){\dashbox(35,49){}} - \put(5,7){ - \put(10,15){\framebox(35,49){}} - \put(55,15){\framebox(35,49){}} - \put(100,15){\framebox(35,49){}} - \put(10,78){\framebox(35,49){}} - \put(55,78){\framebox(35,49){}} - \put(100,78){\framebox(35,49){}} - \put(10,141){\framebox(35,49){}} - \put(55,141){\framebox(35,49){}} - \put(100,141){\framebox(35,49){}} - \put(45,36){\vector(1,0){10}} - \put(55,36){\vector(-1,0){10}} - \put(44.5,38){\textit{delx}} - \put(90,36){\vector(1,0){10}} - \put(100,36){\vector(-1,0){10}} - \put(89.5,38){\textit{delx}} - \put(27,64){\vector(0,1){14}} - \put(27,78){\vector(0,-1){14}} - \put(15,70){\textit{dely}} - \put(27,127){\vector(0,1){14}} - \put(27,141){\vector(0,-1){14}} - \put(15,133){\textit{dely}} - } - \put(10,15){\vector(1,0){5}} - \put(15,15){\vector(0,1){7}} - \put(8,8){\textit{offx}} - \put(17,17){\textit{offy}} -} -% -%^^A legend -% -\setlength{\fboxsep}{4pt} -\put(72.5,10){ - \makebox(0,0){ - \fbox{ - \begin{tabular}{l@{\hskip20pt}l} - \linethickness{\thick}^^A - \raisebox{.8ex}{\line(1,0){5}} physical sheet of paper - & - |delta=|\meta{delx} \meta{dely} - \\ - \linethickness{\thin}^^A - \raisebox{.8ex}{\line(1,0){5}} logical pages - & - |offset=|\meta{offx} \meta{offy} - \\ - \raisebox{.8ex}{\line(1,0){1}\hskip.55mm\line(1,0){1} - \hskip.55mm\line(1,0){1}} centered position - & - \\ - \end{tabular} - }} -} - -\end{picture} -%^^A} \ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/pdfpages/readme b/Master/texmf-dist/doc/latex/pdfpages/readme deleted file mode 100644 index 8645c32904c..00000000000 --- a/Master/texmf-dist/doc/latex/pdfpages/readme +++ /dev/null @@ -1,28 +0,0 @@ - -The pdfpages Package --------------------- - -This package makes it easy to insert pages of external PDF -documents. It is possible to arrange several logical -pages on each sheet of paper. (Like `psnup'.) - -This package supports pdfLaTeX and VTeX but does not work -with LaTeX. - -Run `latex pdfpages.ins' to produce pdfpages.sty and the -driver files pppdftex.def and ppvtex.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.2 -of this license or (at your option) any later version. - - Andreas MATTHIAS - amat@kabsi.at - diff --git a/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx b/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx index cd7028f3eb2..a55be43f57f 100644 --- a/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx +++ b/Master/texmf-dist/source/latex/pdfpages/pdfpages.dtx @@ -1,75 +1,80 @@ % % \iffalse % -% pdfpages.dtx Copyright (C) 2001-2003 Andreas MATTHIAS -% -%<*package> -%% This program may be distributed and/or modified under the -%% conditions of the LaTeX Project Public License, either version 1.2 -%% of this license or (at your option) any later version. -%% The latest version of this license is in +%<*(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 %% http://www.latex-project.org/lppl.txt -%% and version 1.2 or later is part of all distributions of LaTeX -%% version 1999/12/01 or later. +%% and version 1.3c 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 . +% +%<*!installer> %% -% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . +% %% % -%<*!package> -% =================================================================== -% @LaTeX-package-file{ -% author = {Andreas MATTHIAS}, -% version = "0.3e", -% date = "2004-01-31", -% filename = "pdfpages.sty", -% address = "", -% telephone = "", -% email = "amat@kabsi.at", -% codetable = "ISO/ASCII", -% keywords = "pdfLaTeX, PDF, include, insert, page", -% dependences = "ifthen, graphicx, eso-pic", -% supported = "yes", -% docstring = "Package for inserting pages of external -% PDF documents. (Requiring pdfLaTeX.)" -% } -% =================================================================== -% +%<*!(example1,example2,example3,installer)> +%<*dtx> +\makeatletter +% +\def\AM@fileversion{v0.4a} +\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) $ +% +% % %<*dtx> - \ProvidesFile{pdfpages.dtx} +\ProvidesFile{pdfpages.dtx} % %\NeedsTeXFormat{LaTeX2e} %\ProvidesPackage{pdfpages} %\ProvidesFile{pppdftex.def} %\ProvidesFile{ppvtex.def} +%\ProvidesFile{ppnull.def} %\ProvidesFile{pdfpages.drv} -%<*!example1&!example2&!example3> +%<*!(example1,example2,example3,installer)> % \fi % +% \makeatletter % \ProvidesFile{pdfpages.dtx} - [2004/01/31 v0.3e + [\AM@filedate\space\AM@fileversion\space % % \iffalse -% +% %<*none> % \fi ] +% \makeatother % \iffalse % +%<*!(example1,example2,example3,installer)> +%<*dtx> +\makeatother +% +% % % Insert pages of external PDF documents (AM)] % Pdfpages driver for pdfTeX (AM)] % Pdfpages driver for VTeX (AM)] +% Pdfpages' dummy driver (AM)] % -%\def\AM@version{0.3e} % % \fi % % \GetFileInfo{pdfpages.dtx} % -% \CheckSum{3495} +% \CheckSum{3751} % % \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 @@ -92,6 +97,7 @@ %<*driver> \documentclass{ltxdoc} \usepackage{array} +\usepackage{hyperref} \OnlyDescription \begin{document} \DocInput{pdfpages.dtx} @@ -111,44 +117,54 @@ % \def\pdfLaTeX{pdf\kern.06em\LaTeX} % \def\VTeX{V\kern-.05em\TeX} % \def\PDF{{\small PDF}} +% \def\PS{{\small PS}} +% \def\DVI{{\small DVI}} +% +% \pdfstringdef{\pdfTeX}{pdfTeX} +% \pdfstringdef{\VTeX}{VTeX} % +% \makeatletter % \title{The \textsf{pdfpages} Package\thanks{This file -% has version number \fileversion, last revised \filedate.}} +% has version number \AM@fileversion, last revised \AM@filedate.}} % \author{Andreas MATTHIAS\\ \texttt{amat@kabsi.at}} -% -% -% \date{\filedate} +% \date{\AM@filedate} +% \makeatother % % \maketitle % % \begin{abstract} % \noindent -% This package makes it easy to insert pages of external -% PDF documents. It supports \pdfLaTeX\ and \VTeX\, but -% does \textit{not} work with \LaTeX. +% This package simplifies the insertion of external multi-page \PDF\ +% or \PS\ documents. It supports \pdfLaTeX\ and \VTeX. % \end{abstract} % +% \pdfbookmark[1]{\contentsname}{toc} % \tableofcontents % % % \section{Introduction} -% Creating \PDF\ documents, it is sometimes useful to insert -% pages of other, external \PDF\ documents. This can be done -% with the |\includegraphics| command from the -% \texttt{graphics} package. But a simple -% |\includegraphics{doc.pdf}| normally produces -% `|Overfull \hbox|' and `|Overfull \vbox|' warnings, -% because the size of the inserted pages does not match the -% print space. +% When creating \PDF\ documents, it is sometimes useful to insert pages +% of other, external \PDF\ documents. This can be done with the +% |\includegraphics| command from the \texttt{graphics} package. But a +% simple |\includegraphics{doc.pdf}| normally produces `|Overfull \hbox|' +% and `|Overfull \vbox|' warnings, because the size of the inserted pages +% does not match the print space. % -% The |pdfpages| package makes it easy to insert -% pages of external \PDF\ documents without worrying about -% the print space. Here are some features of the -% |pdfpages| package: Several logical pages can be arranged -% onto each sheet of paper and the layout can be changed -% individually. A lot of hypertext operations are supported, -% like links to the inserted pages, links to the original -% \PDF\ document, threads, etc. +% The |pdfpages| package makes it easy to insert pages of external \PDF\ +% documents without worrying about the print space. Here are some +% features of the |pdfpages| package: Several logical pages can be +% arranged onto each sheet of paper and the layout can be changed +% individually. A lot of hypertext operations are supported, like links +% to the inserted pages, links to the original \PDF\ document, threads, +% etc. When working with \VTeX\ the same is possible with PostScript +% documents, too. Note that PostScript documents are only supported by +% \VTeX\ and \emph{not} by \pdfLaTeX. +% +% When producing \DVI\ output |pdfpages| cannot insert pages of a \PDF\ +% documents. But instead of interrupting execution |pdfpages| will insert +% empty pages. This feature is important when using packages like +% |pst-pdf|, which need to produce \DVI\ output at the first run. +% % % \section{Usage} % \subsection{Package Options} @@ -229,7 +245,7 @@ % \par % E.g.: |pages=-| will insert \emph{all} pages % of the document, and |pages=last-1| will insert -% all pages in revers order. +% all pages in reverse order. % \par\df{pages=1} % \item[nup] Puts multiple logical pages onto each sheet % of paper. The syntax of this option is: @@ -337,12 +353,14 @@ % pages into signatures and setting % |nup=1x2| or |nup=2x1|, respectively. This option % takes one argument specifying the size of the -% signature, which should be a multiply of 4.\par +% signature, which should be a multiple of 4.\par % An example for documents in portrait orientation:\par % |\includepdf[pages=-, signature=8,|\\ % \hspace*{6em} |landscape]{portrait-doc.pdf}|\par % An example for documents in landscape orientation:\par % |\includepdf[pages=-, signature=8]{landscape-doc.pdf}| +% \item[signature*] Similar to |signature|, but now for right-edge +% binding. % \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. @@ -395,6 +413,15 @@ % equivalent to `true'). \df{doublepagestwistodd*=false} % \end{description} % +% \item Miscellaneous options: +% \makeatletter\@beginparpenalty=10000\makeatother +% \begin{description} +% \item[lastpage] In \DVI\ mode pdfpages cannot determine the number of +% pages of the included document. So this option is suitable to +% specify the number of pages. This option is only used in \DVI\ mode +% and has no meaning in any other mode. The argument should be a page +% number. \df{lastpage=1} +% \end{description} % % \item Hypertext options: % @@ -640,7 +667,81 @@ % % % \begin{figure} -% \centering\input{pic.tex} +% \centering +% \setlength{\unitlength}{.7mm} +% \def\thick{.7pt} +% \def\thin{.2pt} +% ^^A\fbox{ +% \begin{picture}(145,238) +% \small +% \put(0,33){ +% \linethickness{\thick} +% \put(0,0){\framebox(145,205){}} +% \linethickness{\thin} +% \put(10,15){\dashbox(35,49){}} +% \put(55,15){\dashbox(35,49){}} +% \put(100,15){\dashbox(35,49){}} +% \put(10,78){\dashbox(35,49){}} +% \put(55,78){\dashbox(35,49){}} +% \put(100,78){\dashbox(35,49){}} +% \put(10,141){\dashbox(35,49){}} +% \put(55,141){\dashbox(35,49){}} +% \put(100,141){\dashbox(35,49){}} +% \put(5,7){ +% \put(10,15){\framebox(35,49){}} +% \put(55,15){\framebox(35,49){}} +% \put(100,15){\framebox(35,49){}} +% \put(10,78){\framebox(35,49){}} +% \put(55,78){\framebox(35,49){}} +% \put(100,78){\framebox(35,49){}} +% \put(10,141){\framebox(35,49){}} +% \put(55,141){\framebox(35,49){}} +% \put(100,141){\framebox(35,49){}} +% \put(45,36){\vector(1,0){10}} +% \put(55,36){\vector(-1,0){10}} +% \put(44.5,38){\textit{delx}} +% \put(90,36){\vector(1,0){10}} +% \put(100,36){\vector(-1,0){10}} +% \put(89.5,38){\textit{delx}} +% \put(27,64){\vector(0,1){14}} +% \put(27,78){\vector(0,-1){14}} +% \put(15,70){\textit{dely}} +% \put(27,127){\vector(0,1){14}} +% \put(27,141){\vector(0,-1){14}} +% \put(15,133){\textit{dely}} +% } +% \put(10,15){\vector(1,0){5}} +% \put(15,15){\vector(0,1){7}} +% \put(8,8){\textit{offx}} +% \put(17,17){\textit{offy}} +% } +% +% ^^A legend +% +% \setlength{\fboxsep}{4pt} +% \put(72.5,10){ +% \makebox(0,0){ +% \fbox{ +% \begin{tabular}{l@{\hskip20pt}l} +% \linethickness{\thick}^^A +% \raisebox{.8ex}{\line(1,0){5}} physical sheet of paper +% & +% |delta=|\meta{delx} \meta{dely} +% \\ +% \linethickness{\thin}^^A +% \raisebox{.8ex}{\line(1,0){5}} logical pages +% & +% |offset=|\meta{offx} \meta{offy} +% \\ +% \raisebox{.8ex}{\line(1,0){1}\hskip.55mm\line(1,0){1} +% \hskip.55mm\line(1,0){1}} centered position +% & +% \\ +% \end{tabular} +% }} +% } +% \end{picture} +% ^^A}% fbox % \caption{Layout} % \label{fig:layout} % \end{figure} @@ -867,10 +968,10 @@ % H\`an Th\^e\llap{\raise 0.5ex\hbox{\'{}}} Th\`anh, % Sebastian Rahtz, Hans Hagen, % \textit{The \pdfTeX\ user manual}, -% http://www.tug.org/applications/pdftex/pdftex-s.pdf +% \url{http://www.tug.org/applications/pdftex} % \bibitem{PDFRef} \textit{PDF Reference}, Third Edition, Version 1.4, % Adobe Systems Incorporated,\\ -% http://partners.adobe.com/asn/tech/pdf/specifications.jsp +% \url{http://partners.adobe.com/asn/tech/pdf/specifications.jsp} % \end{thebibliography} % } % @@ -906,26 +1007,20 @@ % \texttt{pdfoutput} (\verb|\let\pdfoutput\@undefined|), % if the document contains the line \verb|\pdfoutput=0|. % \begin{macrocode} -\def\AM@driver{pdftex} \begingroup \@ifundefined{pdfoutput}{% \@ifundefined{OpMode}{% - \PackageError{pdfpages} - {You are using neither pdfTeX nor VTeX.\MessageBreak - Package pdfpages does not work with other\MessageBreak - TeX implementations} - {Please, change to pdfTeX or VTeX to use this - package!}% - \aftergroup\endinput + \def\AM@driver{null} }{\gdef\AM@driver{vtex}}% -}{} +}{\gdef\AM@driver{pdftex}} \endgroup % \end{macrocode} % Required Packages. % \begin{macrocode} \RequirePackage{ifthen, graphicx, calc, eso-pic} +\newif\ifAM@DVIoutput\AM@DVIoutputfalse \input{pp\AM@driver.def} -\ifx\AM@endinput\relax\endinput\fi +\ifx\AM@endinput\relax\expandafter\endinput\fi \ifAM@pkg@survey \let\AM@setanchor\AM@anchor@special \RequirePackage{count1to}% @@ -939,6 +1034,7 @@ \def\AM@ClearShipoutPicture{\relax}} {\def\AM@AddToShipoutPicture{\AddToShipoutPicture}% \def\AM@ClearShipoutPicture{\ClearShipoutPicture}} + \let\Orig@AM@AddToShipoutPicture\AM@AddToShipoutPicture % \end{macrocode} % \subsection{Booleans} % \begin{macrocode} @@ -963,6 +1059,8 @@ \newif\ifAM@doublepagestmpi\AM@doublepagestmpifalse \newif\ifAM@linkfilename\AM@linkfilenamefalse \newif\ifAM@signature\AM@signaturefalse +\newif\ifAM@signaturestar\AM@signaturestarfalse +\newif\ifAM@booklet\AM@bookletfalse \newif\ifAM@sigrotate\AM@sigrotatefalse \newif\ifAM@newwindow\AM@newwindowtrue \newif\ifAM@rescale\AM@rescalefalse @@ -986,10 +1084,7 @@ \newcommand*{\AM@ARBug@hook}{} \newcommand*{\AM@xrprefix}{} \newcommand*{\AM@picturecommand}{}\newcommand*{\AM@picturecommandstar}{} - - \newsavebox{\AM@pagebox} - % \end{macrocode} % \macro{\AM@setlscape} % |\AM@setlscape| is defined in the driver files but may be @@ -1047,7 +1142,7 @@ \ifx\AM@currentdocname\relax \edef\AM@currentdocname{\AM@dir#1}% \fi - }% + }{}% }% }% \@tfor \fi @@ -1152,18 +1247,18 @@ % Some simple checks. % \begin{macrocode} \newcommand{\AM@CheckAtEnd}{% - \ifx\@empty\AM@toclist\else - \PackageWarning{pdfpages}{% - There's something wrong with the entries\MessageBreak - of `addtotoc'. Not all entries were\MessageBreak - processed. Check `addtotoc'}% - \fi - \ifx\@empty\AM@loflist\else - \PackageWarning{pdfpages}{% - There's something wrong with the entries\MessageBreak - of `addtolist'. Not all entries were\MessageBreak - processed. Check `addtolist'}% - \fi + \ifx\@empty\AM@toclist\else + \PackageWarning{pdfpages}{% + There's something wrong with the entries\MessageBreak + of `addtotoc'. Not all entries were\MessageBreak + processed. Check `addtotoc'}% + \fi + \ifx\@empty\AM@loflist\else + \PackageWarning{pdfpages}{% + There's something wrong with the entries\MessageBreak + of `addtolist'. Not all entries were\MessageBreak + processed. Check `addtolist'}% + \fi } % \end{macrocode} % \macro{\AM@output} @@ -1177,6 +1272,11 @@ \c@totalnumber=0 \if@twocolumn\let\AM@twocolumn\relax \onecolumn \fi % \end{macrocode} +% Some drivers, like |ppnull|, need a hook to disable +% |\includegraphics|. +% \begin{macrocode} + \AM@disable@includegraphics +% \end{macrocode} % Some macros may already be initialized by |\includepdfset|. % So do not reset them here. % \begin{macrocode} @@ -1195,11 +1295,6 @@ \else \setkeys{Gin}{draft=false}% \fi % \end{macrocode} -% Some preparations before starting the output. -% \begin{macrocode} - \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}} - {}{\AM@getpagecount} -% \end{macrocode} % \begin{macrocode} \ifthenelse{\boolean{AM@landscape}} {\def\AM@lscape@rot{90}% @@ -1245,7 +1340,7 @@ \ifthenelse{\boolean{AM@reflect}} {\let\AM@reflectbox\reflectbox} {\let\AM@reflectbox\relax}% -\setbox\AM@pagebox\null + \setbox\AM@pagebox\null % \end{macrocode} % \begin{macrocode} \ifthenelse{\boolean{AM@column}} @@ -1281,9 +1376,13 @@ \else \AM@split@options{Gin@noscale}{#1}% \let\AM@filelist@save\@filelist - \setbox\@tempboxa=\hbox{% - \expandafter\includegraphics\expandafter[\the\@temptokena, - page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}% + \ifAM@DVIoutput + \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}} + \else + \setbox\@tempboxa=\hbox{% + \expandafter\includegraphics\expandafter[\the\@temptokena, + page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}% + \fi % \end{macrocode} % Adjust the paper size. % \begin{macrocode} @@ -1575,8 +1674,7 @@ \def\AM@region{region}% \ifx\AM@linkfit\AM@region \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}% - \edef\AM@linkfit{fitr width\the\wd\@tempboxa\space - height0pt depth\the\@tempdima}% + \let\AM@linkfit\AM@linkfit@special \fi % \end{macrocode} % Ship out page. @@ -1588,9 +1686,9 @@ \edef\AM@shippage{% \noexpand\put(\AM@xpos,\AM@ypos){% \noexpand\raisebox{\dp\@tempboxa}{% -% /end{macrocode} +% \end{macrocode} % Raise the target of a link to the top of the included page. -% /begin{macrocode} +% \begin{macrocode} \noexpand\raise \ht\@tempboxa \hbox{\AM@hyper@begin@i}% % \end{macrocode} % \begin{macrocode} @@ -1618,7 +1716,7 @@ \AM@AddToShipoutPicture{\setlength{\unitlength}{\p@}% \global\let\AM@filelist@save\@filelist}% % \end{macrocode} -% |\AM@pagebox| is only use for option |reflect|, which was added +% |\AM@pagebox| is only used for option |reflect|, which was added % lately. Probabley it would be better to use |\AM@pagebox| in % all cases? % \begin{macrocode} @@ -1759,6 +1857,11 @@ \edef\AM@tempii{\AM@trim@space{#1}}% \expandafter\ifx\expandafter\\\AM@tempii\\ \@tempcntb=\AM@pagecount\relax + \ifAM@DVIoutput + \ifnum\AM@pagecount=1 + \@tempcntb\@tempcnta + \fi + \fi \advance\@tempcntb\@ne \whiledo{\@tempcnta<\@tempcntb}{% \AM@append{\the\@tempcnta}% @@ -1787,7 +1890,7 @@ } % \end{macrocode} % \begin{macrocode} -\newcommand*{\AM@checkpagenumber}[1]{% +\providecommand*{\AM@checkpagenumber}[1]{% \ifnum#1>\AM@pagecount\relax \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}}{% }{% @@ -1875,6 +1978,7 @@ % \end{macrocode} % \begin{macrocode} \def\AM@ReturnAfterFi#1\fi{\fi#1} +\def\AM@ReturnAfterFiFi#1\fi\fi{\fi\fi#1} % \end{macrocode} % \begin{macrocode} \newcommand{\AM@getlasti}{} @@ -1905,6 +2009,38 @@ \edef\AM@lastnitems{\AM@templist}% } % \end{macrocode} +% \macro{\AM@split@firstn} +% Removes the first |n=#2| items from the cvs=list, which +% is specified by the name of a macro in |#1|. These |n| +% items are split into two lists with the names |#1@firstn| +% and |#1@lastn|. The latter one is sorted backwards. This +% is needed for a faster processing of the |signature| option. +% \begin{macrocode} +\newcommand{\AM@split@firstn}{} +\def\AM@split@firstn#1#2{% + \edef\AM@tmp{\expandafter\@gobble\string#1@firstn}% + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname{\the\toks@}% + \@tempcnta=\@ne + \@tempcntb=#2 \divide\@tempcntb\tw@ + \loop\ifnum\@tempcnta<\@tempcntb + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname + {\@nameuse{\AM@tmp},\the\toks@}% + \advance\@tempcnta\@ne + \repeat + \edef\AM@tmp{\expandafter\@gobble\string#1@lastn}% + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname{\the\toks@}% + \@tempcnta=\@ne + \loop\ifnum\@tempcnta<\@tempcntb + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname + {\the\toks@,\@nameuse{\AM@tmp}}% + \advance\@tempcnta\@ne + \repeat +} +% \end{macrocode} % \macro{\AM@count} % \macro{\AM@counti} % Parameter |#1| must be a macro containing a csv-list. @@ -2180,13 +2316,16 @@ \equal{doublepagestwist*}{\AM@temp}\or \equal{doublepagestwistodd*}{\AM@temp}\or \equal{signature}{\AM@temp}\or + \equal{signature*}{\AM@temp}\or + \equal{booklet}{\AM@temp}\or \equal{pagetemplate}{\AM@temp}\or \equal{rotateoversize}{\AM@temp}\or \equal{picturecommand}{\AM@temp}\or \equal{picturecommand*}{\AM@temp}\or \equal{newwindow}{\AM@temp}\or \equal{reflect}{\AM@temp}\or - \equal{reflect*}{\AM@temp}} + \equal{reflect*}{\AM@temp}\or + \equal{lastpage}{\AM@temp}} {\AM@pdfpages@optionstrue}{}% \ifthenelse{\equal{scale}{\AM@temp}}{\AM@scaletrue}{}% } @@ -2194,8 +2333,7 @@ % \macro{\AM@trim@space} % \macro{\AM@trim@spacei} % \macro{\AM@trim@spaceii} -% Removes leading and trailing spaces and save the result -% in |\AM@trimmed|. +% Removes leading and trailing spaces. % \begin{macrocode} \newcommand{\AM@trim@space}{}\newcommand{\AM@trim@spacei}{} \newcommand{\AM@trim@spaceii}{} @@ -2334,6 +2472,18 @@ \def\AM@newpagelist{}% \def\AM@newdoclist{}% % \end{macrocode} +% Calculate value of |\AM@signature| for option |booklet|. +% \begin{macrocode} +\ifAM@booklet + \AM@countpagelist + \@tempcntb=\@tempcnta + \divide\@tempcnta by 4 + \multiply\@tempcnta by 4 + \advance\@tempcntb-\@tempcnta + \ifnum\@tempcntb=0\else \advance\@tempcnta by 4\fi + \edef\AM@signature{\the\@tempcnta}% +\fi +% \end{macrocode} % Make |\AM@signature| a multiply of 4. % \begin{macrocode} \@tempcnta=\AM@signature\relax @@ -2365,34 +2515,36 @@ \def\AM@sort{% \def\AM@sigpagelist{}% \def\AM@sigdoclist{}% - \@tempcntb=\AM@signature\relax - \AM@getlastn{\AM@pagelist}{\@tempcntb}% - \edef\AM@lastnpages{\AM@lastnitems}% - \AM@getlastn{\AM@doclist}{\@tempcntb}% - \edef\AM@lastndocs{\AM@lastnitems}% - \@tempcnta=0 + \AM@split@firstn{\AM@pagelist}{\AM@signature}% + \AM@split@firstn{\AM@doclist}{\AM@signature}% \def\AM@first{% - \AM@getfirst{\AM@lastnpages}% + \AM@getfirst{\AM@pagelist@firstn}% \edef\AM@sigpagelist{\AM@sigpagelist,\the\toks@}% - \AM@getfirst{\AM@lastndocs}% + \AM@getfirst{\AM@doclist@firstn}% \edef\AM@sigdoclist{\AM@sigdoclist,\the\toks@}% }% \def\AM@last{% - \AM@getlast{\AM@lastnpages}% - \edef\AM@sigpagelist{\AM@sigpagelist,\AM@lastitem}% - \AM@getlast{\AM@lastndocs}% - \edef\AM@sigdoclist{\AM@sigdoclist,\AM@lastitem}% + \AM@getfirst{\AM@pagelist@lastn}% + \edef\AM@sigpagelist{\AM@sigpagelist,\the\toks@}% + \AM@getfirst{\AM@doclist@lastn}% + \edef\AM@sigdoclist{\AM@sigdoclist,\the\toks@}% }% - \whiledo{\@tempcnta<\@tempcntb}{% + \@tempcnta=\z@ + \@tempcntb=\AM@signature\relax + \whiledo{\@tempcnta<\@tempcntb}{% \ifAM@landscape - \AM@last\AM@first\AM@last\AM@first + \ifAM@signaturestar + \AM@first\AM@last\AM@first\AM@last + \else + \AM@last\AM@first\AM@last\AM@first + \fi \else \AM@first\AM@last\AM@first\AM@last \fi \advance\@tempcnta by 4 }% - \edef\AM@newpagelist{\AM@sigpagelist\AM@newpagelist}% - \edef\AM@newdoclist{\AM@sigdoclist\AM@newdoclist}% + \edef\AM@newpagelist{\AM@newpagelist\AM@sigpagelist}% + \edef\AM@newdoclist{\AM@newdoclist\AM@sigdoclist}% \ifx\AM@pagelist\@empty \else\expandafter\AM@sort \fi @@ -2540,7 +2692,7 @@ \def\@captype{\AM@lof@list}% \long\def\@makecaption##1##2{}% \let\@fs@capt\relax% float.sty - \caption{\AM@lof@heading}% + \expandafter\caption\expandafter{\AM@lof@heading}% \AM@addtolist@hook \@ifundefined{hyper@@anchor}{}{% \@ifundefined{float@caption}{% @@ -2563,7 +2715,7 @@ \def\AM@parse@loflisti#1,#2,#3,#4,#5\END{% \def\AM@lof@page{\AM@trim@space{#1}}% \def\AM@lof@list{\AM@trim@space{#2}}% - \def\AM@lof@heading{#3}% + \edef\AM@lof@heading{\AM@trim@leadingspace{#3}}% \def\AM@lof@label{\AM@trim@space{#4}}% \AM@checkinteger{\AM@lof@page}% \ifAM@integer\else @@ -2676,9 +2828,17 @@ } \AtBeginDocument{\AM@TeXpower@hook} % \end{macrocode} +% \begin{macrocode} +\def\AM@CheckValue#1#2{% + \ifx\\#2\\\PackageError{pdfpages} + {Option `#1' must have a non-empty value}% + \fi +} +% \end{macrocode} % \subsection{Options of \texttt{\protect\bslash includepdf}} % \begin{macrocode} -\define@key{pdfpages}{pages}{\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} \define@key{pdfpages}{deltax}{\AM@parse@deltax#1 \\} \define@key{pdfpages}{deltay}{\AM@parse@deltay#1 \\} @@ -2735,7 +2895,12 @@ \AM@doublepagestmpfalse\AM@doublepagestmpitrue \AM@doublepagestwistxtrue} \define@key{pdfpages}{signature}{\def\AM@signature{#1}} -\define@key{pdfpages}{pagetemplate}{\def\AM@pagetemplate{#1}} +\define@key{pdfpages}{signature*}{\def\AM@signature{#1}% + \AM@signaturestartrue} +\define@key{pdfpages}{booklet}[true]{\setboolean{AM@booklet}{#1}% + \def\AM@signature{x}} +\define@key{pdfpages}{pagetemplate}{\AM@CheckValue{pagetemplate}{#1}% + \def\AM@pagetemplate{#1}} \define@key{pdfpages}{rotateoversize}[true]% {\setboolean{AM@rotateoversize}{#1}} \define@key{pdfpages}{picturecommand}{\def\AM@picturecommand{#1}} @@ -2743,6 +2908,7 @@ \define@key{pdfpages}{newwindow}[true]{\setboolean{AM@newwindow}{#1}} \define@key{pdfpages}{reflect*}[true]{\setboolean{AM@reflect}{#1}} \define@key{pdfpages}{reflect}[true]{\setboolean{AM@reflectall}{#1}} +\define@key{pdfpages}{lastpage}{\def\AM@pagecount{#1}} % \end{macrocode} % \macro{\AM@parse@nup} % Parsing \texttt{nup} item. @@ -2831,11 +2997,7 @@ \expandafter\endinput \fi \ifcase\pdfoutput - \PackageError{pdfpages} - {You produce DVI output but PDF output\MessageBreak - is needed for package pdfpages} - {Set output to PDF. (use: \pdfoutput = 1)} - \let\AM@endinput\relax + \input{ppnull.def} \expandafter\endinput \fi % \end{macrocode} @@ -2953,6 +3115,12 @@ % \begin{macrocode} \def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@linkfit} \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} +% Do not disable |\includegraphics|. +% \begin{macrocode} +\let\AM@disable@includegraphics\relax % \end{macrocode} % % \iffalse @@ -3052,10 +3220,107 @@ % \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} +% Do not disable |\includegraphics|. +% \begin{macrocode} +\let\AM@disable@includegraphics\relax % \end{macrocode} % % \iffalse % +% +%<*ppnulldef> +% \fi +% +% \subsubsection{Null driver} +% This is a dummy driver used when producing {\small DVI} output. +% +% \begin{macrocode} +\AM@DVIoutputtrue +\PackageWarningNoLine{pdfpages}{% + 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}. +% \begin{macrocode} +\def\AM@findfile#1{% + \def\AM@currentdocname{#1}% +} +% \end{macrocode} +% Get last page number. +% \begin{macrocode} +\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}% + \edef\AM@pagecount{1}% + \fi +} +% \end{macrocode} +% Page dimensions. +% \begin{macrocode} +\let\AM@pagewidth\paperwidth +\let\AM@pageheight\paperheight +\def\AM@setpagedimen{% + \setlength{\paperwidth}{\the\wd\@tempboxa}% + \setlength{\paperheight}{\the\ht\@tempboxa}% +} +% \end{macrocode} +% Change paper size. +% \begin{macrocode} +\let\AM@fitpaper@special\relax +% \end{macrocode} +% Find file. +% \begin{macrocode} +\def\AM@findfile#1{% + \def\AM@currentdocname{}% +} +% \end{macrocode} +% Rotate page. +% \begin{macrocode} +\let\AM@setlscape\relax +% \end{macrocode} +% Link to original document. +% \begin{macrocode} +\let\AM@linktodoc@special@begin\relax +\let\AM@linktodoc@special@end\relax +% \end{macrocode} +% Survey. +% \begin{macrocode} +\let\AM@survey@special@begin\relax +\let\AM@survey@special@end\relax +% \end{macrocode} +% Thread. +% \begin{macrocode} +\let\AM@thread@special@begin\relax +\let\AM@thread@special@end\relax +% \end{macrocode} +% Destination for links. +% \begin{macrocode} +\let\AM@dest@special\relax +\let\AM@anchor@special\relax +\let\AM@linkfit@special\relax +% \end{macrocode} +% Disable |\includegraphics|. +% \begin{macrocode} +\def\AM@disable@includegraphics{% + \renewcommand\includegraphics[2][]{}% +} +% \end{macrocode} +% Don't check page numbers. +% \begin{macrocode} +\newcommand*{\AM@checkpagenumber}[1]{} +% \end{macrocode} +% +% \iffalse +% % \fi % % @@ -3063,78 +3328,91 @@ % % \subsection*{2001/01/17 v0.1b} % \begin{itemize} -% \item The first released version. +% \item The first released version. % \end{itemize} % % \subsection*{2001/02/03 v0.1c} % \begin{itemize} -% \item Pages are being centered automatically. +% \item Pages are being centered automatically. % \end{itemize} % % \subsection*{2001/03/16 v0.1f} % \begin{itemize} -% \item Option |pages| added. +% \item Option |pages| added. % \end{itemize} % % \subsection*{2001/04/07 v0.1h} % \begin{itemize} -% \item Hypertext operations added. (Hyperlinks, threads) +% \item Hypertext operations added. (Hyperlinks, threads) % \end{itemize} % % \subsection*{2001/11/12 v0.2} % \begin{itemize} -% \item Support of |m|$\times$|n| logical pages on each -% sheet of paper. -% \item Options |column| and |columnstrict| added. -% \item New command |\inlcudepdfmerge|. +% \item Support of |m|$\times$|n| logical pages on each sheet of paper. +% \item Options |column| and |columnstrict| added. +% \item New command |\inlcudepdfmerge|. % \end{itemize} % % \subsection*{2001/12/26 v0.2c} % \begin{itemize} -% \item Option |fitpaper| added. +% \item Option |fitpaper| added. % \end{itemize} % % \subsection*{2001/03/31 v0.2g} % \begin{itemize} -% \item Option |signature| added. -% \item Options |addtotoc| and |addtolist| added. -% \item Option |doublepages| added. -% \item Options now have their own namespace |pdfpages| and -% do not extent the |Gin| (graphicx) namespace any longer. +% \item Option |signature| added. +% \item Options |addtotoc| and |addtolist| added. +% \item Option |doublepages| added. +% \item Options now have their own namespace |pdfpages| and do not extent +% the |Gin| (graphicx) namespace any longer. % \end{itemize} % % \subsection*{2002/12/14 v0.2l} % \begin{itemize} -% \item Survey functionality added. +% \item Survey functionality added. % \end{itemize} % % \subsection*{2003/06/02 v0.2m} % \begin{itemize} -% \item Support of \PDF s with mixed portrait/landscape pages. -% Options |pagetemplate| and |rotateoversize| added. -% \item Support of |\graphicspath|. -% \item Options |picturecommand| and |picturecommand*| added. -% \item Reverse page order: |pages=7-3|, |pages=last-5| +% \item Support of \PDF s with mixed portrait/landscape pages. Options +% |pagetemplate| and |rotateoversize| added. +% \item Support of |\graphicspath|. +% \item Options |picturecommand| and |picturecommand*| added. +% \item Reverse page order: |pages=7-3|, |pages=last-5| % \end{itemize} % % \subsection*{2003/06/21 v0.3a} % \begin{itemize} -% \item Support of \VTeX. -% \item Driver layer added. All driver specific macros are -% defined in |.def| driver files. +% \item Support of \VTeX. +% \item Driver layer added. All driver specific macros are defined in +% |.def| driver files. % \end{itemize} % % \subsection*{2003/07/16 v0.3b} % \begin{itemize} -% \item Option |\doublepagestwist| added. +% \item Option |\doublepagestwist| added. % \end{itemize} % % \subsection*{2003/12/08 v0.3e} % \begin{itemize} -% \item Option |reflect| added. -% \item Made |\AddToSurvey| work within TeXpower's |\stepwise|. +% \item Option |reflect| added. +% \item Made |\AddToSurvey| work within TeXpower's |\stepwise|. % \end{itemize} - +% +% \subsection*{2004/02/21 v0.3f} +% \begin{itemize} +% \item Option |signature*| (right-edge binding) added. +% \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 +% interrupting execution. +% \item Option |lastpage| added. +% \end{itemize} +% % % \Finale % @@ -3474,5 +3752,77 @@ See Section \ref{sec:second} (\nameref{sec:second}) on page \end{document} % % +%<*installer> +\input docstrip +\askforoverwritefalse +\keepsilent + +\preamble +\endpreamble + +\declarepreamble\package + +This file is part of the pdfpages package. + +\endpreamble + +\declarepreamble\example + +This file demonstrates how to use the pdfpages package. +\endpreamble + +\generate{\usepreamble\package + \file{pdfpages.sty}{\from{pdfpages.dtx}{package}}} +\generate{\usepreamble\package + \file{pppdftex.def}{\from{pdfpages.dtx}{pppdftexdef}}} +\generate{\usepreamble\package + \file{ppvtex.def}{\from{pdfpages.dtx}{ppvtexdef}}} +\generate{\usepreamble\package + \file{ppnull.def}{\from{pdfpages.dtx}{ppnulldef}}} + +%% \generate{\usepreamble\package +%% \file{pdfpages.drv}{\from{pdfpages.dtx}{driver}}} + +\generate{\usepreamble\example + \file{pdf-ex.tex}{\from{pdfpages.dtx}{example1}}} +\generate{\usepreamble\example + \file{pdf-hyp.tex}{\from{pdfpages.dtx}{example2}}} +\generate{\usepreamble\example + \file{pdf-toc.tex}{\from{pdfpages.dtx}{example3}}} + + +\Msg{^^46^^75^^65^^72 ^^64^^69^^63^^68^^2c ^^41^^67^^6e^^65^^73^^21^^J} +\Msg{**************************************************************} +\Msg{*} +\Msg{* To finish the installation you have to move the following} +\Msg{* files into a directory searched by LaTeX:} +\Msg{*} +\Msg{* \space\space pdfpages.sty} +\Msg{* \space\space pppdftex.def} +\Msg{* \space\space ppvtex.def} +\Msg{* \space\space ppnull.def} +\Msg{*} +\Msg{* To produce the documentation, run the following} +\Msg{* file through LaTeX:} +\Msg{*} +\Msg{* \space\space pdfpages.dtx} +\Msg{*} +\Msg{* The following files are examples demonstrating how to use} +\Msg{* the pdfpages package.} +\Msg{*} +\Msg{* \space\space pdf-ex.tex} +\Msg{* \space\space pdf-hyp.tex} +\Msg{* \space\space pdf-toc.tex} +\Msg{*} +\Msg{* Happy TeXing!} +\Msg{*} +\Msg{**************************************************************} +\endbatchfile +% +% %\fi \endinput +%%% +%%% Local Variables: *** +%%% fill-column: 76 *** +%%% End: *** diff --git a/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins b/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins index 662e8e2735a..8928d1701eb 100644 --- a/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins +++ b/Master/texmf-dist/source/latex/pdfpages/pdfpages.ins @@ -1,48 +1,64 @@ +%% +%% This is file `pdfpages.ins', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% pdfpages.dtx (with options: `installer') +%% +%% IMPORTANT NOTICE: +%% +%% For the copyright see the source file. +%% +%% Any modified versions of this file must be renamed +%% with new filenames distinct from pdfpages.ins. +%% +%% For distribution of the original source see the terms +%% for copying and modification in the file pdfpages.dtx. +%% +%% This generated file may be distributed as long as the +%% original source files, as listed above, are part of the +%% same distribution. (The sources need not necessarily be +%% in the same archive or directory.) +%% \input docstrip - \askforoverwritefalse \keepsilent -\declarepreamble\package +\preamble +\endpreamble -This is a package for PDFLaTeX, which makes it -easy to insert pages of external PDF documents. +\declarepreamble\package This file is part of the pdfpages package. -Copyright (C) 2001-2003 Andreas MATTHIAS. - \endpreamble \declarepreamble\example -This file is a demonstration of the pdfpages package. -Run it through pdfLaTeX. - +This file demonstrates how to use the pdfpages package. \endpreamble - \generate{\usepreamble\package \file{pdfpages.sty}{\from{pdfpages.dtx}{package}}} - \generate{\usepreamble\package \file{pppdftex.def}{\from{pdfpages.dtx}{pppdftexdef}}} - \generate{\usepreamble\package \file{ppvtex.def}{\from{pdfpages.dtx}{ppvtexdef}}} +\generate{\usepreamble\package + \file{ppnull.def}{\from{pdfpages.dtx}{ppnulldef}}} %% \generate{\usepreamble\package %% \file{pdfpages.drv}{\from{pdfpages.dtx}{driver}}} \generate{\usepreamble\example \file{pdf-ex.tex}{\from{pdfpages.dtx}{example1}}} - \generate{\usepreamble\example \file{pdf-hyp.tex}{\from{pdfpages.dtx}{example2}}} - \generate{\usepreamble\example \file{pdf-toc.tex}{\from{pdfpages.dtx}{example3}}} +\Msg{^^46^^75^^65^^72 ^^64^^69^^63^^68^^2c ^^41^^67^^6e^^65^^73^^21^^J} \Msg{**************************************************************} \Msg{*} \Msg{* To finish the installation you have to move the following} @@ -51,14 +67,15 @@ Run it through pdfLaTeX. \Msg{* \space\space pdfpages.sty} \Msg{* \space\space pppdftex.def} \Msg{* \space\space ppvtex.def} +\Msg{* \space\space ppnull.def} \Msg{*} \Msg{* To produce the documentation, run the following} \Msg{* file through LaTeX:} \Msg{*} \Msg{* \space\space pdfpages.dtx} \Msg{*} -\Msg{* To produce some examples, run the following files} -\Msg{* through pdfLaTeX:} +\Msg{* The following files are examples demonstrating how to use} +\Msg{* the pdfpages package.} \Msg{*} \Msg{* \space\space pdf-ex.tex} \Msg{* \space\space pdf-hyp.tex} @@ -68,3 +85,6 @@ Run it through pdfLaTeX. \Msg{*} \Msg{**************************************************************} \endbatchfile +\endinput +%% +%% End of file `pdfpages.ins'. diff --git a/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty b/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty index 3dd1d0cc26b..fdcd7dc8439 100644 --- a/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty +++ b/Master/texmf-dist/tex/latex/pdfpages/pdfpages.sty @@ -6,29 +6,33 @@ %% %% pdfpages.dtx (with options: `package') %% -%% This is a package for PDFLaTeX, which makes it -%% easy to insert pages of external PDF documents. -%% %% This file is part of the pdfpages package. %% -%% Copyright (C) 2001-2003 Andreas MATTHIAS. -%% -%% This program may be distributed and/or modified under the -%% conditions of the LaTeX Project Public License, either version 1.2 -%% of this license or (at your option) any later version. -%% The latest version of this license is in +%% 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 %% http://www.latex-project.org/lppl.txt -%% and version 1.2 or later is part of all distributions of LaTeX -%% version 1999/12/01 or later. +%% and version 1.3c 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 . %% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% +\def\AM@fileversion{v0.4a} +\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) $ \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{pdfpages} - [2004/01/31 v0.3e + [\AM@filedate\space\AM@fileversion\space Insert pages of external PDF documents (AM)] -\def\AM@version{0.3e} \newif\ifAM@pkg@draft \AM@pkg@draftfalse \newif\ifAM@pkg@survey \AM@pkg@surveyfalse \DeclareOption{draft}{\AM@pkg@drafttrue} @@ -37,23 +41,17 @@ \DeclareOption{disable-survey}{\AM@pkg@surveyfalse} \ProcessOptions \def\AM@ifdriverlater{\@ifl@ter{def}} -\def\AM@driver{pdftex} \begingroup \@ifundefined{pdfoutput}{% \@ifundefined{OpMode}{% - \PackageError{pdfpages} - {You are using neither pdfTeX nor VTeX.\MessageBreak - Package pdfpages does not work with other\MessageBreak - TeX implementations} - {Please, change to pdfTeX or VTeX to use this - package!}% - \aftergroup\endinput + \def\AM@driver{null} }{\gdef\AM@driver{vtex}}% -}{} +}{\gdef\AM@driver{pdftex}} \endgroup \RequirePackage{ifthen, graphicx, calc, eso-pic} +\newif\ifAM@DVIoutput\AM@DVIoutputfalse \input{pp\AM@driver.def} -\ifx\AM@endinput\relax\endinput\fi +\ifx\AM@endinput\relax\expandafter\endinput\fi \ifAM@pkg@survey \let\AM@setanchor\AM@anchor@special \RequirePackage{count1to}% @@ -64,6 +62,7 @@ \def\AM@ClearShipoutPicture{\relax}} {\def\AM@AddToShipoutPicture{\AddToShipoutPicture}% \def\AM@ClearShipoutPicture{\ClearShipoutPicture}} + \let\Orig@AM@AddToShipoutPicture\AM@AddToShipoutPicture \newif\ifAM@openright\AM@openrightfalse \newif\ifAM@frame\AM@framefalse \newif\ifAM@landscape\AM@landscapefalse @@ -85,6 +84,8 @@ \newif\ifAM@doublepagestmpi\AM@doublepagestmpifalse \newif\ifAM@linkfilename\AM@linkfilenamefalse \newif\ifAM@signature\AM@signaturefalse +\newif\ifAM@signaturestar\AM@signaturestarfalse +\newif\ifAM@booklet\AM@bookletfalse \newif\ifAM@sigrotate\AM@sigrotatefalse \newif\ifAM@newwindow\AM@newwindowtrue \newif\ifAM@rescale\AM@rescalefalse @@ -104,9 +105,7 @@ \newcommand*{\AM@ARBug@hook}{} \newcommand*{\AM@xrprefix}{} \newcommand*{\AM@picturecommand}{}\newcommand*{\AM@picturecommandstar}{} - \newsavebox{\AM@pagebox} - \newif\ifAM@thumbpdf \newif\ifAM@pdflscape \AtBeginDocument{% @@ -149,7 +148,7 @@ \ifx\AM@currentdocname\relax \edef\AM@currentdocname{\AM@dir#1}% \fi - }% + }{}% }% }% \@tfor \fi @@ -225,22 +224,23 @@ \AM@ClearShipoutPicture } \newcommand{\AM@CheckAtEnd}{% - \ifx\@empty\AM@toclist\else - \PackageWarning{pdfpages}{% - There's something wrong with the entries\MessageBreak - of `addtotoc'. Not all entries were\MessageBreak - processed. Check `addtotoc'}% - \fi - \ifx\@empty\AM@loflist\else - \PackageWarning{pdfpages}{% - There's something wrong with the entries\MessageBreak - of `addtolist'. Not all entries were\MessageBreak - processed. Check `addtolist'}% - \fi + \ifx\@empty\AM@toclist\else + \PackageWarning{pdfpages}{% + There's something wrong with the entries\MessageBreak + of `addtotoc'. Not all entries were\MessageBreak + processed. Check `addtotoc'}% + \fi + \ifx\@empty\AM@loflist\else + \PackageWarning{pdfpages}{% + There's something wrong with the entries\MessageBreak + of `addtolist'. Not all entries were\MessageBreak + processed. Check `addtolist'}% + \fi } \newcommand{\AM@output}[1]{% \c@totalnumber=0 \if@twocolumn\let\AM@twocolumn\relax \onecolumn \fi + \AM@disable@includegraphics \@ifundefined{AM@xnup} {\def\AM@xnup{\@ne}\def\AM@ynup{\@ne}% \def\AM@xnupminusi{\z@}\def\AM@ynupminusi{\z@}}{}% @@ -252,8 +252,6 @@ \ifAM@pkg@draft \setkeys{Gin}{draft=true}% \else \setkeys{Gin}{draft=false}% \fi - \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}} - {}{\AM@getpagecount} \ifthenelse{\boolean{AM@landscape}} {\def\AM@lscape@rot{90}% \@ifundefined{AM@shortnupsyntax}{} @@ -292,7 +290,7 @@ \ifthenelse{\boolean{AM@reflect}} {\let\AM@reflectbox\reflectbox} {\let\AM@reflectbox\relax}% -\setbox\AM@pagebox\null + \setbox\AM@pagebox\null \ifthenelse{\boolean{AM@column}} {\def\AM@xnupi{\@ne}% \def\AM@ynupi{\z@}} @@ -313,9 +311,13 @@ \else \AM@split@options{Gin@noscale}{#1}% \let\AM@filelist@save\@filelist - \setbox\@tempboxa=\hbox{% - \expandafter\includegraphics\expandafter[\the\@temptokena, - page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}% + \ifAM@DVIoutput + \setbox\@tempboxa=\hbox{\rule{597pt}{845pt}} + \else + \setbox\@tempboxa=\hbox{% + \expandafter\includegraphics\expandafter[\the\@temptokena, + page=\AM@page, angle=\AM@lscape@rot]{\AM@docname}}% + \fi \ifthenelse{\boolean{AM@fitpaper}} {\setlength{\AM@pagewidth}{\the\wd\@tempboxa}% \setlength{\AM@pageheight}{\the\ht\@tempboxa}% @@ -551,8 +553,7 @@ \def\AM@region{region}% \ifx\AM@linkfit\AM@region \setlength{\@tempdima}{\the\ht\@tempboxa + \the\dp\@tempboxa}% - \edef\AM@linkfit{fitr width\the\wd\@tempboxa\space - height0pt depth\the\@tempdima}% + \let\AM@linkfit\AM@linkfit@special \fi \ifAM@phantompage \def\AM@shippage{}% @@ -694,6 +695,11 @@ \edef\AM@tempii{\AM@trim@space{#1}}% \expandafter\ifx\expandafter\\\AM@tempii\\ \@tempcntb=\AM@pagecount\relax + \ifAM@DVIoutput + \ifnum\AM@pagecount=1 + \@tempcntb\@tempcnta + \fi + \fi \advance\@tempcntb\@ne \whiledo{\@tempcnta<\@tempcntb}{% \AM@append{\the\@tempcnta}% @@ -720,7 +726,7 @@ \fi \fi } -\newcommand*{\AM@checkpagenumber}[1]{% +\providecommand*{\AM@checkpagenumber}[1]{% \ifnum#1>\AM@pagecount\relax \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}}{% }{% @@ -776,6 +782,7 @@ \@ifundefined{AM@temp}{\def#1{}}{\edef#1{\AM@temp}}% } \def\AM@ReturnAfterFi#1\fi{\fi#1} +\def\AM@ReturnAfterFiFi#1\fi\fi{\fi\fi#1} \newcommand{\AM@getlasti}{} \def\AM@getlasti#1,#2\END{% \ifx\\#2\\% @@ -801,6 +808,30 @@ \repeat \edef\AM@lastnitems{\AM@templist}% } +\newcommand{\AM@split@firstn}{} +\def\AM@split@firstn#1#2{% + \edef\AM@tmp{\expandafter\@gobble\string#1@firstn}% + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname{\the\toks@}% + \@tempcnta=\@ne + \@tempcntb=#2 \divide\@tempcntb\tw@ + \loop\ifnum\@tempcnta<\@tempcntb + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname + {\@nameuse{\AM@tmp},\the\toks@}% + \advance\@tempcnta\@ne + \repeat + \edef\AM@tmp{\expandafter\@gobble\string#1@lastn}% + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname{\the\toks@}% + \@tempcnta=\@ne + \loop\ifnum\@tempcnta<\@tempcntb + \AM@getfirst{#1}% + \expandafter\edef\csname\AM@tmp\endcsname + {\the\toks@,\@nameuse{\AM@tmp}}% + \advance\@tempcnta\@ne + \repeat +} \newif\ifAM@again\AM@againtrue \newcommand{\AM@count}{} \def\AM@count#1{% @@ -991,13 +1022,16 @@ \equal{doublepagestwist*}{\AM@temp}\or \equal{doublepagestwistodd*}{\AM@temp}\or \equal{signature}{\AM@temp}\or + \equal{signature*}{\AM@temp}\or + \equal{booklet}{\AM@temp}\or \equal{pagetemplate}{\AM@temp}\or \equal{rotateoversize}{\AM@temp}\or \equal{picturecommand}{\AM@temp}\or \equal{picturecommand*}{\AM@temp}\or \equal{newwindow}{\AM@temp}\or \equal{reflect}{\AM@temp}\or - \equal{reflect*}{\AM@temp}} + \equal{reflect*}{\AM@temp}\or + \equal{lastpage}{\AM@temp}} {\AM@pdfpages@optionstrue}{}% \ifthenelse{\equal{scale}{\AM@temp}}{\AM@scaletrue}{}% } @@ -1083,6 +1117,15 @@ \def\AM@prepare@signature{% \def\AM@newpagelist{}% \def\AM@newdoclist{}% +\ifAM@booklet + \AM@countpagelist + \@tempcntb=\@tempcnta + \divide\@tempcnta by 4 + \multiply\@tempcnta by 4 + \advance\@tempcntb-\@tempcnta + \ifnum\@tempcntb=0\else \advance\@tempcnta by 4\fi + \edef\AM@signature{\the\@tempcnta}% +\fi \@tempcnta=\AM@signature\relax \divide\@tempcnta by 4 \multiply\@tempcnta by 4 @@ -1105,34 +1148,36 @@ \def\AM@sort{% \def\AM@sigpagelist{}% \def\AM@sigdoclist{}% - \@tempcntb=\AM@signature\relax - \AM@getlastn{\AM@pagelist}{\@tempcntb}% - \edef\AM@lastnpages{\AM@lastnitems}% - \AM@getlastn{\AM@doclist}{\@tempcntb}% - \edef\AM@lastndocs{\AM@lastnitems}% - \@tempcnta=0 + \AM@split@firstn{\AM@pagelist}{\AM@signature}% + \AM@split@firstn{\AM@doclist}{\AM@signature}% \def\AM@first{% - \AM@getfirst{\AM@lastnpages}% + \AM@getfirst{\AM@pagelist@firstn}% \edef\AM@sigpagelist{\AM@sigpagelist,\the\toks@}% - \AM@getfirst{\AM@lastndocs}% + \AM@getfirst{\AM@doclist@firstn}% \edef\AM@sigdoclist{\AM@sigdoclist,\the\toks@}% }% \def\AM@last{% - \AM@getlast{\AM@lastnpages}% - \edef\AM@sigpagelist{\AM@sigpagelist,\AM@lastitem}% - \AM@getlast{\AM@lastndocs}% - \edef\AM@sigdoclist{\AM@sigdoclist,\AM@lastitem}% + \AM@getfirst{\AM@pagelist@lastn}% + \edef\AM@sigpagelist{\AM@sigpagelist,\the\toks@}% + \AM@getfirst{\AM@doclist@lastn}% + \edef\AM@sigdoclist{\AM@sigdoclist,\the\toks@}% }% + \@tempcnta=\z@ + \@tempcntb=\AM@signature\relax \whiledo{\@tempcnta<\@tempcntb}{% \ifAM@landscape - \AM@last\AM@first\AM@last\AM@first + \ifAM@signaturestar + \AM@first\AM@last\AM@first\AM@last + \else + \AM@last\AM@first\AM@last\AM@first + \fi \else \AM@first\AM@last\AM@first\AM@last \fi \advance\@tempcnta by 4 }% - \edef\AM@newpagelist{\AM@sigpagelist\AM@newpagelist}% - \edef\AM@newdoclist{\AM@sigdoclist\AM@newdoclist}% + \edef\AM@newpagelist{\AM@newpagelist\AM@sigpagelist}% + \edef\AM@newdoclist{\AM@newdoclist\AM@sigdoclist}% \ifx\AM@pagelist\@empty \else\expandafter\AM@sort \fi @@ -1224,7 +1269,7 @@ \def\@captype{\AM@lof@list}% \long\def\@makecaption##1##2{}% \let\@fs@capt\relax% float.sty - \caption{\AM@lof@heading}% + \expandafter\caption\expandafter{\AM@lof@heading}% \AM@addtolist@hook \@ifundefined{hyper@@anchor}{}{% \@ifundefined{float@caption}{% @@ -1243,7 +1288,7 @@ \def\AM@parse@loflisti#1,#2,#3,#4,#5\END{% \def\AM@lof@page{\AM@trim@space{#1}}% \def\AM@lof@list{\AM@trim@space{#2}}% - \def\AM@lof@heading{#3}% + \edef\AM@lof@heading{\AM@trim@leadingspace{#3}}% \def\AM@lof@label{\AM@trim@space{#4}}% \AM@checkinteger{\AM@lof@page}% \ifAM@integer\else @@ -1332,7 +1377,13 @@ \fi } \AtBeginDocument{\AM@TeXpower@hook} -\define@key{pdfpages}{pages}{\def\AM@pagestemp{#1}} +\def\AM@CheckValue#1#2{% + \ifx\\#2\\\PackageError{pdfpages} + {Option `#1' must have a non-empty value}% + \fi +} +\define@key{pdfpages}{pages}{\AM@CheckValue{pages}{#1}% + \def\AM@pagestemp{#1}} \define@key{pdfpages}{nup}{\AM@parse@nup#1x\END} \define@key{pdfpages}{deltax}{\AM@parse@deltax#1 \\} \define@key{pdfpages}{deltay}{\AM@parse@deltay#1 \\} @@ -1389,7 +1440,12 @@ \AM@doublepagestmpfalse\AM@doublepagestmpitrue \AM@doublepagestwistxtrue} \define@key{pdfpages}{signature}{\def\AM@signature{#1}} -\define@key{pdfpages}{pagetemplate}{\def\AM@pagetemplate{#1}} +\define@key{pdfpages}{signature*}{\def\AM@signature{#1}% + \AM@signaturestartrue} +\define@key{pdfpages}{booklet}[true]{\setboolean{AM@booklet}{#1}% + \def\AM@signature{x}} +\define@key{pdfpages}{pagetemplate}{\AM@CheckValue{pagetemplate}{#1}% + \def\AM@pagetemplate{#1}} \define@key{pdfpages}{rotateoversize}[true]% {\setboolean{AM@rotateoversize}{#1}} \define@key{pdfpages}{picturecommand}{\def\AM@picturecommand{#1}} @@ -1397,6 +1453,7 @@ \define@key{pdfpages}{newwindow}[true]{\setboolean{AM@newwindow}{#1}} \define@key{pdfpages}{reflect*}[true]{\setboolean{AM@reflect}{#1}} \define@key{pdfpages}{reflect}[true]{\setboolean{AM@reflectall}{#1}} +\define@key{pdfpages}{lastpage}{\def\AM@pagecount{#1}} \newcommand{\AM@parse@nup}{} \def\AM@parse@nup#1x#2\END{% \ifx\\#2\\% @@ -1437,7 +1494,6 @@ } \InputIfFileExists{pdfpages.fix}{% \PackageInfo{pdfpages}{Loading patch file `pdfpages.fix'}}{} - \endinput %% %% End of file `pdfpages.sty'. diff --git a/Master/texmf-dist/tex/latex/pdfpages/ppnull.def b/Master/texmf-dist/tex/latex/pdfpages/ppnull.def new file mode 100644 index 00000000000..a538bc80221 --- /dev/null +++ b/Master/texmf-dist/tex/latex/pdfpages/ppnull.def @@ -0,0 +1,78 @@ +%% +%% This is file `ppnull.def', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% pdfpages.dtx (with options: `ppnulldef') +%% +%% This file is part of the pdfpages package. +%% +%% 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 +%% 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. +%% +%% This work has the LPPL maintenance status `maintained'. +%% +%% The Current Maintainer of this work is Andreas Matthias . +%% +%% Please send error reports and suggestions for improvements to +%% Andreas MATTHIAS . +%% +\def\AM@fileversion{v0.4a} +\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) $ +\ProvidesFile{ppnull.def} + [\AM@filedate\space\AM@fileversion\space + Pdfpages' dummy driver (AM)] +\AM@DVIoutputtrue +\PackageWarningNoLine{pdfpages}{% + I will use a dummy \string\includepdf\space command\MessageBreak + which will NOT insert any pages, because\MessageBreak + you are producing DVI output} +\def\AM@findfile#1{% + \def\AM@currentdocname{#1}% +} +\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}% + \edef\AM@pagecount{1}% + \fi +} +\let\AM@pagewidth\paperwidth +\let\AM@pageheight\paperheight +\def\AM@setpagedimen{% + \setlength{\paperwidth}{\the\wd\@tempboxa}% + \setlength{\paperheight}{\the\ht\@tempboxa}% +} +\let\AM@fitpaper@special\relax +\def\AM@findfile#1{% + \def\AM@currentdocname{}% +} +\let\AM@setlscape\relax +\let\AM@linktodoc@special@begin\relax +\let\AM@linktodoc@special@end\relax +\let\AM@survey@special@begin\relax +\let\AM@survey@special@end\relax +\let\AM@thread@special@begin\relax +\let\AM@thread@special@end\relax +\let\AM@dest@special\relax +\let\AM@anchor@special\relax +\let\AM@linkfit@special\relax +\def\AM@disable@includegraphics{% + \renewcommand\includegraphics[2][]{}% +} +\newcommand*{\AM@checkpagenumber}[1]{} +\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 18fc3c62ac5..537326f7008 100644 --- a/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def +++ b/Master/texmf-dist/tex/latex/pdfpages/pppdftex.def @@ -6,18 +6,31 @@ %% %% pdfpages.dtx (with options: `pppdftexdef') %% -%% This is a package for PDFLaTeX, which makes it -%% easy to insert pages of external PDF documents. -%% %% This file is part of the pdfpages package. %% -%% Copyright (C) 2001-2003 Andreas MATTHIAS. -%% +%% 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 +%% 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. +%% +%% This work has the LPPL maintenance status `maintained'. +%% +%% The Current Maintainer of this work is Andreas Matthias . +%% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% +\def\AM@fileversion{v0.4a} +\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) $ \ProvidesFile{pppdftex.def} - [2004/01/31 v0.3e + [\AM@filedate\space\AM@fileversion\space Pdfpages driver for pdfTeX (AM)] \ifnum\pdftexversion<100 \PackageError{pdfpages} @@ -28,11 +41,7 @@ \expandafter\endinput \fi \ifcase\pdfoutput - \PackageError{pdfpages} - {You produce DVI output but PDF output\MessageBreak - is needed for package pdfpages} - {Set output to PDF. (use: \pdfoutput = 1)} - \let\AM@endinput\relax + \input{ppnull.def} \expandafter\endinput \fi \begingroup @@ -102,7 +111,9 @@ \let\AM@thread@special@end\relax \def\AM@dest@special{\pdfdest name {\AM@linkname.\AM@page} \AM@linkfit} \def\AM@anchor@special{\pdfdest name {pdfpages.\the\count1} fit} - +\edef\AM@linkfit@special{fitr width\the\wd\@tempboxa\space + height0pt depth\the\@tempdima} +\let\AM@disable@includegraphics\relax \endinput %% %% End of file `pppdftex.def'. diff --git a/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def b/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def index a47ec1f4572..484a1aa121d 100644 --- a/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def +++ b/Master/texmf-dist/tex/latex/pdfpages/ppvtex.def @@ -6,18 +6,31 @@ %% %% pdfpages.dtx (with options: `ppvtexdef') %% -%% This is a package for PDFLaTeX, which makes it -%% easy to insert pages of external PDF documents. -%% %% This file is part of the pdfpages package. %% -%% Copyright (C) 2001-2003 Andreas MATTHIAS. -%% +%% 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 +%% 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. +%% +%% This work has the LPPL maintenance status `maintained'. +%% +%% The Current Maintainer of this work is Andreas Matthias . +%% %% Please send error reports and suggestions for improvements to %% Andreas MATTHIAS . %% +\def\AM@fileversion{v0.4a} +\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) $ \ProvidesFile{ppvtex.def} - [2004/01/31 v0.3e + [\AM@filedate\space\AM@fileversion\space Pdfpages driver for VTeX (AM)] \ifnum\VTeXversion<822 \PackageError{pdfpages} @@ -76,7 +89,9 @@ \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} +\let\AM@disable@includegraphics\relax \endinput %% %% End of file `ppvtex.def'. diff --git a/Master/texmf-dist/tpm/pdfpages.tpm b/Master/texmf-dist/tpm/pdfpages.tpm index 227a9b80937..c17390cfa7e 100644 --- a/Master/texmf-dist/tpm/pdfpages.tpm +++ b/Master/texmf-dist/tpm/pdfpages.tpm @@ -3,7 +3,7 @@ pdfpages Package - 2006/01/11 23:56:03 + 2006/08/14 22:59:46 0.2l rahtz Include PDF documents in LaTeX. @@ -22,26 +22,23 @@ pages={3,5-11,20,38}. Support is included for VTeX. Andreas Matthias 590743 - + texmf-dist/tex/latex/pdfpages/pdfpages.sty +texmf-dist/tex/latex/pdfpages/ppnull.def texmf-dist/tex/latex/pdfpages/pppdftex.def texmf-dist/tex/latex/pdfpages/ppvtex.def texmf-dist/tpm/pdfpages.tpm - + +texmf-dist/doc/latex/pdfpages/README texmf-dist/doc/latex/pdfpages/dummy-l.pdf texmf-dist/doc/latex/pdfpages/dummy.pdf -texmf-dist/doc/latex/pdfpages/pdf-ex.pdf texmf-dist/doc/latex/pdfpages/pdf-ex.tex -texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf texmf-dist/doc/latex/pdfpages/pdf-hyp.tex -texmf-dist/doc/latex/pdfpages/pdf-toc.pdf texmf-dist/doc/latex/pdfpages/pdf-toc.tex texmf-dist/doc/latex/pdfpages/pdfpages.pdf -texmf-dist/doc/latex/pdfpages/pic.tex -texmf-dist/doc/latex/pdfpages/readme - + texmf-dist/source/latex/pdfpages/pdfpages.dtx texmf-dist/source/latex/pdfpages/pdfpages.ins diff --git a/Master/texmf/lists/pdfpages b/Master/texmf/lists/pdfpages index c475451df93..552acf731e8 100644 --- a/Master/texmf/lists/pdfpages +++ b/Master/texmf/lists/pdfpages @@ -1,18 +1,15 @@ +eso-pic +texmf-dist/doc/latex/pdfpages/README texmf-dist/doc/latex/pdfpages/dummy-l.pdf texmf-dist/doc/latex/pdfpages/dummy.pdf -texmf-dist/doc/latex/pdfpages/pdf-ex.pdf texmf-dist/doc/latex/pdfpages/pdf-ex.tex -texmf-dist/doc/latex/pdfpages/pdf-hyp.pdf texmf-dist/doc/latex/pdfpages/pdf-hyp.tex -texmf-dist/doc/latex/pdfpages/pdf-toc.pdf texmf-dist/doc/latex/pdfpages/pdf-toc.tex texmf-dist/doc/latex/pdfpages/pdfpages.pdf -texmf-dist/doc/latex/pdfpages/pic.tex -texmf-dist/doc/latex/pdfpages/readme texmf-dist/source/latex/pdfpages/pdfpages.dtx texmf-dist/source/latex/pdfpages/pdfpages.ins texmf-dist/tex/latex/pdfpages/pdfpages.sty +texmf-dist/tex/latex/pdfpages/ppnull.def texmf-dist/tex/latex/pdfpages/pppdftex.def texmf-dist/tex/latex/pdfpages/ppvtex.def texmf-dist/tpm/pdfpages.tpm -- cgit v1.2.3