diff options
author | Karl Berry <karl@freefriends.org> | 2010-04-30 18:17:54 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-04-30 18:17:54 +0000 |
commit | 5cc722828d1314a5cb3aaf9c00f2f7cad1988c95 (patch) | |
tree | ed4d66c4b46433779ee208db6d5af7b3b3e85b40 | |
parent | 0e290b30838946f452aa3ea2fd58654e9cc68b1e (diff) |
pdfjam update
git-svn-id: svn://tug.org/texlive/trunk@18056 c570f23f-e606-0410-a88d-b1316a301751
38 files changed, 255 insertions, 155 deletions
diff --git a/Master/texmf-dist/doc/latex/pdfjam/PDFjam-README.html b/Master/texmf-dist/doc/latex/pdfjam/PDFjam-README.html index 7f3a44b711b..14de2cd43f6 100644 --- a/Master/texmf-dist/doc/latex/pdfjam/PDFjam-README.html +++ b/Master/texmf-dist/doc/latex/pdfjam/PDFjam-README.html @@ -10,7 +10,6 @@ <p><em>Author</em>: David Firth, <a href="http://go.warwick.ac.uk/dfirth">http://go.warwick.ac.uk/dfirth</a></p> <p> <strong> This file is kept up to date at <a href="http://go.warwick.ac.uk/pdfjam">http://go.warwick.ac.uk/pdfjam</a>. </strong> </p> - <ul> <li><a href="#overview">Overview</a> </li> <li><a href="#prereq">Pre-requisites</a> </li> @@ -47,7 +46,7 @@ <p> A potential drawback of <tt>pdfjam</tt> and other scripts based upon it is that any hyperlinks in the source PDF are lost. On the positive side, there is no appreciable degradation of image quality in processing PDF files with these programs, unlike some other indirect methods such as <tt>pdf2ps | psnup | ps2pdf</tt> (in the author's experience). </p> -<p> These tools are designed for Unix-like systems, including Linux and Mac OS X. It seems that they will work also on Windows computers with a suitable installation of <a href="http://www.cygwin.com/">Cygwin</a>, but this has not been extensively tested.</p> +<p> These tools are designed for Unix-like systems, including Linux and Mac OS X. It seems that they will work also on Windows computers with a suitable installation of <a href="http://www.cygwin.com/">Cygwin</a> (with the Cygwin <tt>tetex-extras</tt> package installed), but this has not been extensively tested.</p> <p> An alternative set of PDF manipulation tools, which are java-based, is provided by the <a href="http://multivalent.sourceforge.net/">Multivalent</a> project. They do much the same things as <tt>pdfjam</tt>, and quite a bit more. Hyperlinks don't seem to be preserved there either, though, when n-upping a document. </p> @@ -83,13 +82,21 @@ <a name="download"></a> <h2 align="justify">Download</h2> -<p>Download the shell scripts as <a href="http://www2.warwick.ac.uk/fac/sci/statistics/staff/academic/firth/software/pdfjam/pdfjam_2.01.tgz">pdfjam_2.01.tgz</a>. </p> +<p>PDFjam is a project at <a href="http://freshmeat.net/projects/pdfjam/">freshmeat</a>: please subscribe there to receive update announcements. <a name="install"></a>Download the shell scripts as <a href="http://www2.warwick.ac.uk/fac/sci/statistics/staff/academic/firth/software/pdfjam/pdfjam_latest.tgz">pdfjam_latest.tgz</a>. </p> + +<p>(If for some reason you don't want the latest version, you can still get older versions. Since version 2.00 the URLs are all of the form <tt>http://go.warwick.ac.uk/pdfjam/pdfjam_VN.tgz</tt>, with "VN" representing the version number. So "VN" could be 2.00, 2.01, 2.02, 2.03 or 2.04; from PDFjam version 2.05 onwards, the dot will be omitted from the file name, so "VN" will be 205, 206, etc.)</p> -<p> Eduard Bloch has kindly packaged <a href="http://packages.debian.org/unstable/text/pdfjam">PDFjam for Debian</a>. Paul Chvostek has kindly made a <a href="http://www.freebsd.org/cgi/ports.cgi?query=pdfjam">port to FreeBSD</a>. Pander has kindly provided a link to <a href="http://packages.ubuntu.com/search?keywords=pdfjam">Ubuntu packages</a>. Petr Uzel has kindly made available <a href="http://software.opensuse.org/search?baseproject=ALL&p=1&q=pdfjam">openSUSE packages</a>.</p> +<p>Various people have kindly packaged PDFjam for distribution in other ways (and perhaps there are some not listed here?): </p> -<p> For some Mac OS X droplets (based on PDFjam version 1.21), see <a href="#droplets">below</a>. </p> +<ul> + <li>Eduard Bloch has packaged <a href="http://packages.debian.org/unstable/text/pdfjam">PDFjam for Debian</a> </li> + <li>Paul Chvostek has made a <a href="http://www.freebsd.org/cgi/ports.cgi?query=pdfjam">port to FreeBSD</a> </li> + <li>Pander has provided a link to <a href="http://packages.ubuntu.com/search?keywords=pdfjam">Ubuntu packages</a> </li> + <li>Petr Uzel has made available <a href="http://software.opensuse.org/search?baseproject=ALL&p=1&q=pdfjam">openSUSE packages</a> </li> + <li>Karl Berry has kindly provided a <a href="http://mirror.ctan.org/support/pdfjam">CTAN package</a>.</li> +</ul> -<p> PDFjam is a project at <a href="http://freshmeat.net/projects/pdfjam/">freshmeat</a>: please subscribe there to receive update announcements. <a name="install"></a> </p> +<p> To download some stand-alone <em>Mac OS X droplets</em> (based on PDFjam version 1.21), see <a href="#droplets">below</a>. </p> <a name="install"></a><h2 align="justify">Installation/configuration</h2> @@ -97,7 +104,7 @@ <p>The man files in the <em>man1</em> sub-directory should be installed on the <tt>MANPATH</tt> of all who need to read them.</p> -<p> On many unix-like systems the scripts should run without any further configuration, provided that the pre-requisite TeX installation is present. </p> +<p> On many unix-like systems the scripts should run without any further configuration, provided that the pre-requisite TeX installation is present. If you want to check (e.g., prior to installation) that <tt>pdfjam</tt> will work on your system, please unzip the <em>tests</em> sub-directory of the package and follow the instructions that appear in <tt>tests/README-tests.txt</tt>.</p> <p>If configuration <em>is</em> needed, this can be done through a site-wide or user-specific configuration file. This might be necessary if, for example, your site has a non-standard TeX installation, or a non-standard location for temporary files, or a paper size that is different from the A4 international standard.</p> @@ -250,8 +257,24 @@ pdflatex=/path/to/pdflatex <p>Please report any bugs found in these scripts, to d.firth (at warwick.ac.uk).</p> +<h3>Some known problems:</h3> + +<ul> + <li> Use of <tt>pdfjam</tt> in a pipeline does not seem to work in <em>Cygwin</em>. Scripts like <tt>pdfjam-pocketmod</tt>, which use pipelines, therefore do not work there. The problem seems to be with <em>Cygwin</em>'s handling of file descriptors with pipelines.</li> +</ul> + +<p>Solving these problems is on the to-do list: if you have solved one of them already please let me know!</p> + <a name="history"></a> <h2 align="justify">Version history</h2> +<p> <strong>2.05</strong>: changes to the <tt>pdfbook</tt> script — the <tt>--right-edge-binding</tt> option is now redundant, and there's a new <tt>--short-edge</tt> option for binding along the short edge of pages instead of the long edge (thanks to Marco Pessotto for this). The <tt>--preamble</tt> option to <tt>pdfjam</tt> is enhanced, to allow multiple instances which get concatenated. Also various minor corrections to man pages. [2010-04-25] </p> + +<p> <strong>2.04</strong>: various minor improvements suggested by Debian maintainers (thanks to Eduard Bloch for these). The main things are: addition of the <tt>--version</tt> option; liberalisation of <tt>pdfjam</tt> to allow files in <em>JPEG</em> format to be specified as input, as well as PDF (I don't know why or if this might work! but some people have said it does); tidying of the man files; and more use of <tt>exec</tt>, to avoid forking. [2010-04-22] </p> + +<p> <strong>2.03</strong>: fixed a bug which caused problems when your <tt>/bin/sh</tt> is the <em>zsh</em> shell; fixed a bug which prevented the correct representation of many UTF-8 characters in <tt>pdfinfo</tt> data. [2010-04-20] </p> + +<p> <strong>2.02</strong>: more progress on portability; introduced the beginnings of a suite of tests; improvements in the <tt>--keepinfo</tt> functionality, and in the treatment of file permissions (thanks to Marco Pessotto for these). [2010-04-14] </p> + <p> <strong>2.01</strong>: fixed a silly bug (thoughtless use of "<tt>test -a</tt>" in a couple of places) which seriously affected portability. [2010-04-13] </p> <hr color="grey" /> diff --git a/Master/texmf-dist/doc/latex/pdfjam/VERSION b/Master/texmf-dist/doc/latex/pdfjam/VERSION index d507853e573..793cf9a340d 100644 --- a/Master/texmf-dist/doc/latex/pdfjam/VERSION +++ b/Master/texmf-dist/doc/latex/pdfjam/VERSION @@ -1 +1 @@ -This is PDFjam 2.01
\ No newline at end of file +This is PDFjam 2.05
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/pdfjam/pdfjam.conf b/Master/texmf-dist/doc/latex/pdfjam/pdfjam.conf index dbebf73ce67..9b8f90c12e1 100644 --- a/Master/texmf-dist/doc/latex/pdfjam/pdfjam.conf +++ b/Master/texmf-dist/doc/latex/pdfjam/pdfjam.conf @@ -70,8 +70,8 @@ paper='a4paper' ## for ISO A4 paper ## DEFAULT PATH FOR THE --outfile OPTION ## outFile="$pwd" ## the obvious default -# outFile="$HOME/Documents" ## another possibility, perhaps -# outFile=/dev/stdout ## for easy pipes +# outFile="$HOME/Documents" ## (another possibility, perhaps) +# outFile=/dev/stdout ## (for easy pipes) ## ############################################################### ## @@ -87,5 +87,7 @@ landscape='false' ## overridden by '--landscape' in the call twoside='false' ## overridden by '--twoside' in the call # twoside='true' ## the alternative ## +preamble='' ## concatenate other strings to this by using '--preamble' +## ############################################################### ## END OF FILE: that's all you can configure here! diff --git a/Master/texmf-dist/doc/latex/pdfjam/tests.zip b/Master/texmf-dist/doc/latex/pdfjam/tests.zip Binary files differnew file mode 100644 index 00000000000..2f4b644de5d --- /dev/null +++ b/Master/texmf-dist/doc/latex/pdfjam/tests.zip diff --git a/Master/texmf-dist/scripts/pdfjam/pdf180 b/Master/texmf-dist/scripts/pdfjam/pdf180 index a9f4b7a250d..860be220297 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdf180 +++ b/Master/texmf-dist/scripts/pdfjam/pdf180 @@ -4,8 +4,8 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## -pdfjam --suffix rotated180 --angle 180 --fitpaper true "$@" +exec pdfjam --suffix rotated180 --angle 180 --fitpaper true "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdf270 b/Master/texmf-dist/scripts/pdfjam/pdf270 index bca6c57b02b..07e211fbe66 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdf270 +++ b/Master/texmf-dist/scripts/pdfjam/pdf270 @@ -4,8 +4,8 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## -pdfjam --suffix rotated270 --angle 270 --fitpaper true --rotateoversize true "$@" +exec pdfjam --suffix rotated270 --angle 270 --fitpaper true --rotateoversize true "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdf90 b/Master/texmf-dist/scripts/pdfjam/pdf90 index ac38aa490f3..7158aa5c9bb 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdf90 +++ b/Master/texmf-dist/scripts/pdfjam/pdf90 @@ -4,8 +4,8 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## -pdfjam --suffix rotated90 --angle 90 --fitpaper true --rotateoversize true "$@" +exec pdfjam --suffix rotated90 --angle 90 --fitpaper true --rotateoversize true "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfbook b/Master/texmf-dist/scripts/pdfjam/pdfbook index 8d032d3a351..2bd3e0fecbf 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfbook +++ b/Master/texmf-dist/scripts/pdfjam/pdfbook @@ -1,19 +1,55 @@ -#!/bin/sh +#!/bin/sh ## ## pdfbook: Rearrange pages of one or more PDF files into 2-up signatures ## -## Author David Firth (http://go.warwick.ac.uk/dfirth) +## Author David Firth (http://go.warwick.ac.uk/dfirth), with help +## from Marco Pessotto ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## -case "${1}" in - --right-edge-binding) +case $1 in + --short-edge) + shortedge=true ; shift ; - pdfjam --suffix book --signature* 4 --landscape "$@" ;; - *) - pdfjam --suffix book --signature 4 --landscape "$@" ;; + ;; + *) + ;; esac - +for arg +do + case $arg in + --signature*) + ## catches both --signature and --signature* + signature=true ; break + ;; + *) ;; + esac +done +## +## If $signature is empty, we need to use a default: +## +if test -z "$signature" ; then + signature="--signature 4" +else + signature="" +fi +## +## Make the call to pdfjam: +## +if test -z "$shortedge" +then + exec pdfjam --landscape --suffix book $signature "$@" +else + (kpsewhich everyshi.sty >/dev/null) || { + echo "the 'everyshi' package is not installed."; exit 1 + } + exec pdfjam --landscape --suffix book $signature \ + --preamble '\usepackage{everyshi} +\makeatletter +\EveryShipout{\ifodd\c@page\pdfpageattr{/Rotate 180}\fi} +\makeatother +' "$@" +fi diff --git a/Master/texmf-dist/scripts/pdfjam/pdfflip b/Master/texmf-dist/scripts/pdfjam/pdfflip index 125c4adea9c..8643abcd07e 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfflip +++ b/Master/texmf-dist/scripts/pdfjam/pdfflip @@ -4,6 +4,6 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## -pdfjam --suffix flipped --reflect true --fitpaper true "$@" +exec pdfjam --suffix flipped --reflect true --fitpaper true "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfjam b/Master/texmf-dist/scripts/pdfjam/pdfjam index 52641909681..439040d6bc8 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfjam +++ b/Master/texmf-dist/scripts/pdfjam/pdfjam @@ -1,5 +1,5 @@ -#! /bin/sh -version=2.01 +#!/bin/sh +version=2.05 ######################################################################### ## ## ## pdfjam: A shell-script interface to the "pdfpages" LaTeX package ## @@ -18,10 +18,11 @@ version=2.01 ## do not accept that, then you must not use it. ## ## ## ## The path searched for site-wide configuration files can be set ## -## through the following variable: ## +## by editing the following variable: ## ## ## configpath='/etc:/usr/share/etc:/usr/local/share:/usr/local/etc' ## ## ## +## Nothing else in this file should need to be changed. ## ## ## ######################################################################### ## @@ -35,11 +36,16 @@ version=2.01 ## --- or whether all configuration files should be ignored. ## verbose=true -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --quiet | -q | --configpath) verbose=false ; ;; + --version | -V) + echo "$version" + exit 0 ; + ;; --batch) batch=true ; ;; @@ -56,7 +62,7 @@ done ## ## Check to see whether this is a "secondary" call to pdfjam: ## -if test "$PDFJAM_CALL_NUMBER" = "" ## not a secondary call +if test -z "$PDFJAM_CALL_NUMBER" ## not a secondary call then PDFJAM_CALL_NUMBER=0 fi @@ -81,8 +87,6 @@ newline=' ## Define a function to escape tricky characters in file names etc: ## escape_chars () { - ## use 'printf "%q" if available -# (printf "%q" "${1}") || (printf "%s" "${1}" | sed 's/[^a-zA-Z0-9._/\-]/\\&/g') } ## @@ -105,15 +109,15 @@ prattle () { ## second argument here is non-null for continuation lines lineCounter=`expr $lineCounter + 1` ; if test $lineCounter -eq 1 && test ! -n "${2}" ; then - if test -e "$PDFJAM_MESSAGES_FILE" - then printf "$prefix1$indent %b\n" "$line" 1>/dev/null >> \ + if test -w "$PDFJAM_MESSAGES_FILE" + then printf "$prefix1$indent %s\n" "$line" 1>/dev/null >> \ "$PDFJAM_MESSAGES_FILE" else messages="$messages$prefix1$indent $line$newline" ## msg file not made yet fi else - if test -e "$PDFJAM_MESSAGES_FILE" - then printf "$prefix2$indent %b\n" "$line" 1>/dev/null >> \ + if test -w "$PDFJAM_MESSAGES_FILE" + then printf "$prefix2$indent %s\n" "$line" 1>/dev/null >> \ "$PDFJAM_MESSAGES_FILE" else messages="$messages$prefix2$indent $line$newline" ## msg file not made yet @@ -183,10 +187,12 @@ checkfiles='false' ## Don't use the Unix 'file -Lb' utility to ## identify PDF files from their contents; ## rely on the .pdf or .PDF extension instead. ## -suffix='pdfjam' ## Default filename suffix to be used when +suffix='pdfjam' ## Default filename suffix to be used when ## --outfile is either (a) a directory, or (b) ## not specified in a --batch call. ## +preamble='' ## Default LaTeX preamble string. +## paper='a4paper' ## Default paper size is ISO A4. ## ## END OF SETTINGS MADE DIRECTLY WITHIN THE SCRIPT @@ -215,7 +221,7 @@ then IFS="$OIFS" PDFJAM_CONFIG=`printf "%s" "$PDFJAM_CONFIG" | sed 's/^/ /'` if test "$batch" = true ; then export PDFJAM_CONFIG ; fi - if test "$PDFJAM_CONFIG" = "" + if test -z "$PDFJAM_CONFIG" then prattle "(none found)" 1 else @@ -273,6 +279,9 @@ where --configpath Output the 'configpath' variable and exit immediately; no processing of PDF files. + --version (or -V) + Output the version number of pdfjam and exit immediately; no + processing of PDF files. --quiet (or -q) Suppress verbose commentary on progress. --batch @@ -319,8 +328,10 @@ where line. An example: pdfjam --nup 2x2 myfile.pdf -o myfile-4up.pdf \\ --preamble '\usepackage{fancyhdr} \pagestyle{fancy}' - The --preamble option can be used, for example, to load LaTeX - packages and/or to set global options. + The '--preamble' option can be used, for example, to load + LaTeX packages and/or to set global options. If '--preamble' + is used more than once in the call, the supplied preamble + strings are simply concatenated. --keepinfo --no-keepinfo Preserve (or not) Title, Author, Subject and Keywords @@ -392,9 +403,10 @@ where * '--' can be used to signal that there are no more options to come. Defaults for the options '--suffix', '--keepinfo', '--paper', '--outfile', -'--landscape', '--twoside', '--tidy' and '--checkfiles' can be set in -site-wide or user-specific configuration files. The path that is searched -for site-wide configuration files (named pdfjam.conf) at this installation is +'--landscape', '--twoside', '--tidy', '--checkfiles' and '--preamble' can be +set in site-wide or user-specific configuration files. The path that is +searched for site-wide configuration files (named pdfjam.conf) at this +installation is $configpath This configuration path can be changed by editing the pdfjam script if necessary. Any user-specific configuration should be put in a file named @@ -422,7 +434,7 @@ E_CONFIG=78 # configuration error ## Define a function to print an error message and exit: ## error_exit () { - if (test -e "$PDFJAM_MESSAGES_FILE") + if (test -r "$PDFJAM_MESSAGES_FILE") then cat "$PDFJAM_MESSAGES_FILE" >&2 else printf "$messages" 1>&2 fi @@ -451,8 +463,9 @@ optionsFinished="" ## ## First note any '--checkfiles' or '--no-checkfiles' option ## -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --checkfiles) checkfiles=true ; callOptions="$callOptions --checkfiles" ; @@ -467,7 +480,7 @@ while test -n "${1}${2}"; do argUnmatched="" if test "$optionsFinished" != true then - case "${1}" in + case ${1} in --) ## signals end of command-line options optionsFinished=true ; shift ; @@ -485,7 +498,7 @@ while test -n "${1}${2}"; do fileSpec=`printf "%s" "$fileSpec" | sed 's/|awaited/|-/g'` pageSpecAwaited=false fi - case "${1}" in + case ${1} in --batch) batch=true ; ;; @@ -575,11 +588,11 @@ while test -n "${1}${2}"; do --paper) paper="${2}" callOptions="$callOptions ${1} ${2}" ; - shift;; + shift ;; --pagecolor) pagecolor="${2}" ; callOptions="$callOptions ${1} ${2}" ; - shift;; + shift ;; --a4paper | --a5paper | --b5paper | --letterpaper | \ --executivepaper | --legalpaper) ## standard LaTeX paper sizes @@ -589,7 +602,7 @@ while test -n "${1}${2}"; do --a0paper | --a1paper | --a2paper | --a3paper | \ --a6paper | --b0paper | --b1paper | --b2paper | \ --b3paper | --b4paper | --b6paper) - ## the 'geonetry' package is needed + ## the 'geometry' package is needed if test "$geometry" != false ; then paper=`printf "%s" "${1}" | sed 's/^--//'` ; @@ -598,7 +611,7 @@ while test -n "${1}${2}"; do fi ; ;; --papersize) - ## the 'geonetry' package is needed + ## the 'geometry' package is needed if test "$geometry" != false ; then papersize="papersize=${2}" ; @@ -623,8 +636,7 @@ while test -n "${1}${2}"; do callOptions="$callOptions --no-twoside" ; ;; --preamble) - preamble="${2}" ; - callOptions="$callOptions ${1} '$preamble'" ; + preamble="$preamble${2}" ; shift ;; --*) ## options for \includepdfmerge @@ -642,9 +654,9 @@ while test -n "${1}${2}"; do ;; esac fi - if test "$optionsFinished" = true || test "$argUnmatched" = true + if test "$optionsFinished" = true || test "$argUnmatched" = true then - case "${1}" in + case ${1} in "" | /dev/stdin) fileSpec="${fileSpec}${newline}/dev/stdin|awaited" pageSpecAwaited=true @@ -663,13 +675,16 @@ while test -n "${1}${2}"; do if test "$checkfiles" = true ; ## not always available then case `file -Lb "${1}"` in - "PDF document"*) ## it's a PDF file as expected + "PDF document"*|"JPEG image data"*) + ## it's a PDF file as expected fileSpec="$fileSpec${newline}"${1}"|awaited" pageSpecAwaited=true ;; *) - case "${1}" in - *.[pP][dD][fF]) ## should be PDF file, but isn't + case ${1} in + *.[pP][dD][fF] | *.[jJ][pP][eE][gG] | \ + *.[jJ][pP][gG]) + ## should be PDF file, but isn't error_exit "no PDF file found at ${1}" \ $E_NOINPUT ;; @@ -688,8 +703,9 @@ while test -n "${1}${2}"; do ;; esac else ## no checking of file contents; rely on .pdf extension - case "${1}" in - *.[pP][dD][fF]) ## assume it's a PDF file + case ${1} in + *.[pP][dD][fF] | *.[jJ][pP][eE][gG] | *.[jJ][pP][gG]) + ## assume it's a PDF file test -f "${1}" || error_exit \ "${1} not found" $E_NOINPUT fileSpec="$fileSpec"$newline${1}"|"awaited @@ -722,7 +738,7 @@ fileSpec=`printf "%s" "$fileSpec" | sed '/^$/d; s/^ //; s/|awaited$/|-/'` if test $PDFJAM_CALL_NUMBER -eq 0 && test "$inputFromStdin" != true then ## the special argument '/dev/stdin' was not used - if test "$fileSpec" = "" ; then + if test -z "$fileSpec" ; then ## no argument specifying a PDF source was given inputFromStdin=true fileSpec="/dev/stdin|-" @@ -734,19 +750,22 @@ fi ## miscOptions=`printf "%s" "$miscOptions" | sed 's/^,//'` ## +if test -n "$preamble" +then callOptions="$callOptions --preamble '$preamble'" +fi ## Delete leading space from $callOptions: ## callOptions=`printf "%s" "$callOptions" | sed 's/^ //'` ## ## Set up a document options variable: ## -case "$landscape" in +case $landscape in true) orientation=landscape ;; *) orientation="" ;; esac -case "$twoside" in +case $twoside in true) twoside=twoside ;; *) @@ -755,11 +774,11 @@ esac if test "$geometry" != false then ## we haven't already found that geometry.sty is missing - case "$paper" in + case $paper in a0paper | a1paper | a2paper | a3paper | \ a6paper | b0paper | b1paper | b2paper | \ b3paper | b4paper | b6paper) - ## the 'geonetry' package is needed + ## the 'geometry' package is needed geometry=true ; ;; *) @@ -780,7 +799,7 @@ documentOptions=`printf "%s" "$documentOptions" | sed 's/^,//' | sed 's/,$//'` if test $PDFJAM_CALL_NUMBER -eq 0 ## not a secondary call then ## Check whether there's a pdflatex, if "$pdflatex" is still unset: - case "$pdflatex" in + case $pdflatex in "not found") error_exit "can't find pdflatex!" $E_UNAVAILABLE ;; @@ -853,7 +872,7 @@ then else if test "$keepinfo" = true then - case "$pdfinfo" in + case $pdfinfo in "not found") if test $PDFJAM_CALL_NUMBER -eq 0 then @@ -891,6 +910,7 @@ fi ## Use mktemp if possible; otherwise fall back on mkdir, ## with random name to make file collisions less likely. ## +original_umask=`umask` umask 177 if test $PDFJAM_CALL_NUMBER = 0 ## don't repeat this work for secondary calls then @@ -925,8 +945,9 @@ then messages="" ## we won't be using this variable again! else PDFJAM_TEMP_DIR="$PDFJAM_TEMP_DIR"/"file$PDFJAM_CALL_NUMBER" - umask 077 && mkdir "$PDFJAM_TEMP_DIR" + (umask 077 && mkdir "$PDFJAM_TEMP_DIR") fi +umask $original_umask ## ## TEMPORARY DIRECTORY ALL DONE ## @@ -1012,7 +1033,7 @@ counter=0 ## stdinUnread=true IFS="$newline" -for k in $fileSpec +for k in ${fileSpec} do counter=`expr $counter + 1` sourcePath=`printf "%s" "$k" | sed 's/|[^|]*$//'` @@ -1028,7 +1049,7 @@ do then error_exit "invalid page spec $pageSpec" $E_USAGE fi - case "$sourcePath" in + case $sourcePath in /dev/stdin) uniqueName="$PDFJAM_TEMP_DIR"/stdin.pdf if test "$stdinUnread" = true @@ -1044,7 +1065,7 @@ do ;; *) pdfName=`basename "$sourcePath"` - sourceDir=`dirname "$sourcePath"` + sourceDir=`dirname "$sourcePath"` ## zsh on Mac OS 10.5 chokes here cd "$sourceDir" || exit 1 ## just to get the full path sourceDir=`pwd` cd "$pwd" || exit 1 @@ -1069,13 +1090,17 @@ then prattle "Calling ${pdfinfo}..." ; PDFinfo=`pdfinfo "$uniqueName"`; pdftitl=`printf "%s" "$PDFinfo" | \ - grep -e '^Title:'| sed s/^Title:\\\s\*//`; + grep -e '^Title:'| sed s/^Title:\\\s\*// | \ + sed -e 's/[#$%^&_{}~]/\\\&/g'`; pdfauth=`printf "%s" "$PDFinfo" | \ - grep -e '^Author:'| sed s/^Author:\\\s\*//`; + grep -e '^Author:'| sed s/^Author:\\\s\*// | \ + sed -e 's/[#$%^&_{}~]/\\\&/g'`; pdfsubj=`printf "%s" "$PDFinfo" | \ - grep -e '^Subject:'| sed s/^Subject:\\\s\*//`; + grep -e '^Subject:'| sed s/^Subject:\\\s\*// | \ + sed -e 's/[#$%^&_{}~]/\\\&/g'`; pdfkeyw=`printf "%s" "$PDFinfo" | \ - grep -e '^Keywords:'| sed s/^Keywords:\\\s\*//`; + grep -e '^Keywords:'| sed s/^Keywords:\\\s\*// | \ + sed -e 's/[#$%^&_{}~]/\\\&/g'`; fi if test -n "$pdfTitle" ; then pdftitl="$pdfTitle" @@ -1102,11 +1127,12 @@ tempFile="$PDFJAM_TEMP_DIR"/temp.tex \documentclass[$documentOptions]{article} \usepackage{color} \definecolor{bgclr}{RGB}{$pagecolor} \pagecolor{bgclr} \usepackage[$papersize]{geometry} +\usepackage[utf8]{inputenc} \usepackage{hyperref} -\hypersetup{pdftitle=$pdftitl} -\hypersetup{pdfauthor=$pdfauth} -\hypersetup{pdfsubject=$pdfsubj} -\hypersetup{pdfkeywords=$pdfkeyw} +\hypersetup{pdftitle={$pdftitl}} +\hypersetup{pdfauthor={$pdfauth}} +\hypersetup{pdfsubject={$pdfsubj}} +\hypersetup{pdfkeywords={$pdfkeyw}} \usepackage{pdfpages} $preamble \begin{document} @@ -1120,13 +1146,13 @@ if test "$hyperref" = false; then ## we don't need hyperref sed '/\\\hypersetup.*/d' > "${texFile}" rm $tempFile fi -if test ! -n "$geometry" ; then geometry=false ; fi +if test -z "$geometry" ; then geometry=false ; fi if test "$geometry" = false; then ## geometry package is not to be used cp $texFile $tempFile cat $tempFile | sed '/\\\usepackage.*{geometry}/d' > $texFile rm $tempFile fi -if test "$pagecolor" = ""; then ## color package is not needed +if test -z "$pagecolor"; then ## color package is not needed cp $texFile $tempFile cat $tempFile | sed '/\\\usepackage.*{color}/d' > $texFile rm $tempFile @@ -1136,7 +1162,7 @@ fi ## ######################################################################### ## -## RUN PDFLATEX AND COPY THE RESULTING PDF FILE TO STDOUT +## RUN PDFLATEX AND COPY THE RESULTING PDF FILE ## prattle "Calling ${pdflatex}..." ; cd "$PDFJAM_TEMP_DIR" || exit 1 @@ -1147,11 +1173,10 @@ If '--no-tidy' was used, you can examine the log file at $fileName.log to try to diagnose the problem." -if ! ("$pdflatex" "$texFile" > "$msgFile") -then +$pdflatex $texFile > $msgFile || { prattle "$failureText" - error_exit "Output file not written" $E_SOFTWARE -fi + error_exit "Output file not written" $E_SOFTWARE +} cd "$pwd" || exit 1 if test -f "$fileName".pdf ## if LaTeX didn't choke then @@ -1172,7 +1197,7 @@ then separator="-" if test "$pageSpec" != "-" then - separator="-$pageSpec" + separator=-"$pageSpec"- fi outFile=`printf "%s" "$outFile" | sed 's/\/$//'` ## (delete any trailing slash) @@ -1188,8 +1213,9 @@ if test -f "$outFile" && test ! -w "$outFile" then error_exit "no write permission at ${outFile}" $E_CANTCREATE fi +#fileSize=`wc -c < "$fileName.pdf" | sed 's/^\ *//'` (cat "$fileName".pdf > "$outFile" 2>/dev/null) && - prattle "Finished. Output was to ${outFile}." || + prattle "Finished. Output was to '${outFile}'." || error_exit "cannot write output at ${outFile}" $E_CANTCREATE if (test "$PDFJAM_CALL_NUMBER" = "0") && ## not a secondary call (test $verbose = true) diff --git a/Master/texmf-dist/scripts/pdfjam/pdfjam-pocketmod b/Master/texmf-dist/scripts/pdfjam/pdfjam-pocketmod index 0bebe86961c..864f4821140 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfjam-pocketmod +++ b/Master/texmf-dist/scripts/pdfjam/pdfjam-pocketmod @@ -6,15 +6,16 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for (three runs of) pdfjam, version 2.01 +## This is a simple wrapper for (three runs of) pdfjam, version 2.05 ## ## ## It's hard (?) to set up this particular script to read from /dev/stdin, ## so we'll just insist that the first argument is a file: ## E_USAGE=64 ## for a command line usage error -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --batch) printf "pdfjam-pocketmod ERROR: the --batch option is not allowed\n" 1>&2 ; exit "$E_USAGE" ;; @@ -22,6 +23,8 @@ for arg in "$@"; do n='--no-tidy' ;; --quiet | -q) q='-q' ;; + --vanilla) + v='--vanilla' ;; --checkfiles) c='--checkfiles' ;; *) @@ -43,12 +46,12 @@ fi ## That's all the argument checking! ## pageSpec="1-8" ## the default page spec -case "${1}" in +case ${1} in --* | "") ## no page spec was given ;; *) ## a page spec was given, so use it pageSpec="$1" ; shift ;; esac -pdfjam $n $q $c -o /dev/stdout "$sourceFile" "$pageSpec" | pdfjam --angle 180 $n $q -o /dev/stdout /dev/stdin '1,8,7,6' | pdfjam --nup 4x2 --landscape --frame true "$sourceFile" '2-5' /dev/stdin "$@" +pdfjam $n $q $c $v -o /dev/stdout "$sourceFile" "$pageSpec" | pdfjam --angle 180 $n $q $v -o /dev/stdout /dev/stdin '1,8,7,6' | pdfjam --nup 4x2 --landscape --frame true "$sourceFile" '2-5' /dev/stdin "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfjam-slides3up b/Master/texmf-dist/scripts/pdfjam/pdfjam-slides3up index 3bd461c8883..f6736bede44 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfjam-slides3up +++ b/Master/texmf-dist/scripts/pdfjam/pdfjam-slides3up @@ -5,13 +5,13 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## footskip=3.1cm ## default setting pagecommand='{\thispagestyle{empty}}' ## default setting -case "${1}" in +case ${1} in --pagenumbering) - case "${2}" in + case ${2} in false) continue ;; true) @@ -20,10 +20,10 @@ case "${1}" in pagecommand='{\thispagestyle{plain}}' ; footskip="$2" ;; esac ; - shift 2 ;; + shift; shift ;; *) continue ;; esac -pdfjam --suffix 3up --nup 1x3 --frame true --noautoscale false \ +exec pdfjam --suffix 3up --nup 1x3 --frame true --noautoscale false \ --delta "0cm 0.2cm" --scale 0.87 --offset "-3.8cm 0cm" \ --preamble "\footskip $footskip" --pagecommand "$pagecommand" "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfjam-slides6up b/Master/texmf-dist/scripts/pdfjam/pdfjam-slides6up index 47fa2ea1ec8..3dd9136b81f 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfjam-slides6up +++ b/Master/texmf-dist/scripts/pdfjam/pdfjam-slides6up @@ -5,13 +5,13 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## footskip=2.7cm ## default setting pagecommand='{\thispagestyle{empty}}' ## default setting -case "${1}" in +case ${1} in --pagenumbering) - case "${2}" in + case ${2} in false) continue ;; true) @@ -20,11 +20,11 @@ case "${1}" in pagecommand='{\thispagestyle{plain}}' ; footskip="$2" ;; esac ; - shift 2 ;; + shift; shift ;; *) continue ;; esac -pdfjam --suffix 6up --nup 2x3 --frame true --noautoscale false \ +exec pdfjam --suffix 6up --nup 2x3 --frame true --noautoscale false \ --delta "0.2cm 0.3cm" --scale 0.95 --preamble "\footskip $footskip" \ --pagecommand "$pagecommand" "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfjoin b/Master/texmf-dist/scripts/pdfjam/pdfjoin index 02c397fc31d..d475cd4e28a 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfjoin +++ b/Master/texmf-dist/scripts/pdfjam/pdfjoin @@ -4,11 +4,12 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## E_USAGE=64 ## for a command line usage error -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --batch) printf "pdfjoin ERROR: the --batch option is not allowed\n" 1>&2; exit "$E_USAGE" ;; @@ -20,6 +21,6 @@ for arg in "$@"; do *) continue ;; esac done -pdfjam --fitpaper true --rotateoversize true --suffix joined "$@" +exec pdfjam --fitpaper true --rotateoversize true --suffix joined "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfnup b/Master/texmf-dist/scripts/pdfjam/pdfnup index a4744a112fd..0b551d34fb5 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfnup +++ b/Master/texmf-dist/scripts/pdfjam/pdfnup @@ -4,11 +4,12 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for pdfjam, version 2.01 +## This is a simple wrapper for pdfjam, version 2.05 ## E_USAGE=64 ## for a command line usage error -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --orient) ## this was allowed in previous versions of pdfnup printf "pdfnup ERROR: the --orient option is not allowed,\n" 1>&2; printf " use --landscape or --no-landscape to specify\n" 1>&2; @@ -23,6 +24,6 @@ for arg in "$@"; do *) continue ;; esac done -pdfjam --suffix nup --nup 2x1 --landscape "$@" +exec pdfjam --suffix nup --nup 2x1 --landscape "$@" diff --git a/Master/texmf-dist/scripts/pdfjam/pdfpun b/Master/texmf-dist/scripts/pdfjam/pdfpun index eee08a05d33..aea8ff87eec 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfpun +++ b/Master/texmf-dist/scripts/pdfjam/pdfpun @@ -5,13 +5,14 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for (three runs of) pdfjam, version 2.01 +## This is a simple wrapper for (three runs of) pdfjam, version 2.05 ## ## E_USAGE=64 ## for a command line usage error ## -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --batch) printf "pdfpun ERROR: the --batch option is not allowed\n" 1>&2; exit "$E_USAGE" ;; @@ -29,7 +30,7 @@ shift ; ## ## Some (very) minimal checking of the first argument: ## -if test ! -e "$sourceFile" ; +if test ! -f "$sourceFile" ; then printf "pdfpun ERROR: first argument must be a PDF file\n" ; exit $E_USAGE ; @@ -45,21 +46,21 @@ fi ## That's all the argument checking! ## pageSpec="-" ## the default -case "${1}" in +case ${1} in --* | "") ;; *) ## a page spec was given pageSpec="$1" ; shift ;; esac -case "${1}" in +case ${1} in --outfile) outFile="$2" ; - shift 2 ;; + shift; shift ;; *) ;; esac -if test "$outFile" = "" ; +if test -z "$outFile" ; then printf "pdfpun ERROR: no output file specified\n" 1>&2 ; exit "$E_USAGE" ; diff --git a/Master/texmf/doc/man/man1/pdf180.1 b/Master/texmf/doc/man/man1/pdf180.1 index 86bcc0b8535..08f47b5a9c0 100644 --- a/Master/texmf/doc/man/man1/pdf180.1 +++ b/Master/texmf/doc/man/man1/pdf180.1 @@ -17,15 +17,15 @@ Source files are processed sequentially into a single output unless the '--batch' option is used, in which case they are processed separately. .PP -pdf180 operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdf180 operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-rotated180' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdf180 --suffix '-upturned' --batch myfile1.pdf myfile2.pdf +.B pdf180 --suffix 'upturned' --batch myfile1.pdf myfile2.pdf .RE .PP will result in files named 'myfile1-upturned.pdf' and 'myfile2-upturned.pdf'. diff --git a/Master/texmf/doc/man/man1/pdf180.man1.pdf b/Master/texmf/doc/man/man1/pdf180.man1.pdf Binary files differnew file mode 100644 index 00000000000..27293eb740e --- /dev/null +++ b/Master/texmf/doc/man/man1/pdf180.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdf270.1 b/Master/texmf/doc/man/man1/pdf270.1 index d27f76cce90..b229678cf82 100644 --- a/Master/texmf/doc/man/man1/pdf270.1 +++ b/Master/texmf/doc/man/man1/pdf270.1 @@ -17,10 +17,10 @@ Source files are processed sequentially into a single output unless the '--batch' option is used, in which case they are processed separately. .PP -pdf270 operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdf270 operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have -the suffix '-rotated270' applied to their names by default. To change +the suffix 'rotated270' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP diff --git a/Master/texmf/doc/man/man1/pdf270.man1.pdf b/Master/texmf/doc/man/man1/pdf270.man1.pdf Binary files differnew file mode 100644 index 00000000000..f6efd0710d6 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdf270.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdf90.1 b/Master/texmf/doc/man/man1/pdf90.1 index d0b433c2cc0..c04a36137af 100644 --- a/Master/texmf/doc/man/man1/pdf90.1 +++ b/Master/texmf/doc/man/man1/pdf90.1 @@ -17,10 +17,10 @@ Source files are processed sequentially into a single output unless the '--batch' option is used, in which case they are processed separately. .PP -pdf90 operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdf90 operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have -the suffix '-rotated90' applied to their names by default. To change +the suffix 'rotated90' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP diff --git a/Master/texmf/doc/man/man1/pdf90.man1.pdf b/Master/texmf/doc/man/man1/pdf90.man1.pdf Binary files differnew file mode 100644 index 00000000000..ac294fd42b7 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdf90.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfbook.1 b/Master/texmf/doc/man/man1/pdfbook.1 index bf87ada1cc2..f0be4b73ed3 100644 --- a/Master/texmf/doc/man/man1/pdfbook.1 +++ b/Master/texmf/doc/man/man1/pdfbook.1 @@ -3,17 +3,20 @@ pdfbook \- put the pages of PDF files into 2-up signatures .SH "SYNOPSIS" .PP -pdfbook [--right-edge-binding] [OPTION [OPTION] \&.\&.\&.] [SRC [PAGESPEC] [SRC [PAGESPEC]] \&.\&.\&.] +pdfbook [--short-edge] [OPTION [OPTION] \&.\&.\&.] [SRC [PAGESPEC] [SRC [PAGESPEC]] \&.\&.\&.] .PP .SH "DESCRIPTION" .PP pdfbook makes 2-up versions of PDF files, with the pages ordered as signatures. The default signature size is 4: to change this, use the -option '--signature N', where N is a multiple of 4. +option '--signature N', where N is a multiple of 4 (alternatively use '--signature* N' for +right-edge binding). .PP -The default is to make files suitable for left-edge binding. For right-edge -binding, use the '--right-edge-binding' argument; in that case, to change -the default signature is changed by using the option '--signature* N'. +The default is to make pages suitable for long-edge binding. For short-edge +binding, use '--short-edge' as the first argument; this will only work if the LaTeX package 'everyshi' is installed. +.PP +The default output page orientation is +landscape. To change this, use the '--no-landscape' option. .PP If no source PDF file ('SRC') is specified, input is from /dev/stdin. If 'PAGESPEC' is omitted, all pages are processed. @@ -27,14 +30,14 @@ many of the capabilities of the pdfpages package for pdflatex\&. A working installation of pdflatex, with the pdfpages package, is required\&. .PP -pdfbook operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdfbook operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-book' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdfbook --suffix '-sig4' --batch myfile1.pdf myfile2.pdf +.B pdfbook --suffix 'sig4' --batch myfile1.pdf myfile2.pdf .RE .PP will result in files named 'myfile1-sig4.pdf' and 'myfile2-sig4.pdf'. diff --git a/Master/texmf/doc/man/man1/pdfbook.man1.pdf b/Master/texmf/doc/man/man1/pdfbook.man1.pdf Binary files differnew file mode 100644 index 00000000000..2e6d334c676 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfbook.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfflip.1 b/Master/texmf/doc/man/man1/pdfflip.1 index 842da1c7fba..9761790d9f6 100644 --- a/Master/texmf/doc/man/man1/pdfflip.1 +++ b/Master/texmf/doc/man/man1/pdfflip.1 @@ -16,15 +16,15 @@ Source files are processed sequentially into a single output unless the '--batch' option is used, in which case they are processed separately. .PP -pdfflip operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdfflip operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-flipped' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdfflip --suffix '-reflected' --batch myfile1.pdf myfile2.pdf +.B pdfflip --suffix 'reflected' --batch myfile1.pdf myfile2.pdf .RE .PP will result in files named 'myfile1-reflected.pdf' and 'myfile2-reflected.pdf'. diff --git a/Master/texmf/doc/man/man1/pdfflip.man1.pdf b/Master/texmf/doc/man/man1/pdfflip.man1.pdf Binary files differnew file mode 100644 index 00000000000..bbb3f40b418 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfflip.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfjam-pocketmod.1 b/Master/texmf/doc/man/man1/pdfjam-pocketmod.1 index 40c72cbf10d..4c51ef78806 100644 --- a/Master/texmf/doc/man/man1/pdfjam-pocketmod.1 +++ b/Master/texmf/doc/man/man1/pdfjam-pocketmod.1 @@ -41,8 +41,7 @@ http://go.warwick.ac.uk/pdfjam \&. .PP .SH "LIMITATIONS AND BUGS" .PP -pdfjam-pocketmod does not work with encrypted PDF files, and does not -preserve hyperlinks. +pdfjam-pocketmod does not work with encrypted PDF files, and does not preserve hyperlinks. .PP The '--keepinfo' option does not work. .PP diff --git a/Master/texmf/doc/man/man1/pdfjam-pocketmod.man1.pdf b/Master/texmf/doc/man/man1/pdfjam-pocketmod.man1.pdf Binary files differnew file mode 100644 index 00000000000..5244569a60a --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfjam-pocketmod.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfjam-slides3up.1 b/Master/texmf/doc/man/man1/pdfjam-slides3up.1 index 4602b680e2c..09227631a10 100644 --- a/Master/texmf/doc/man/man1/pdfjam-slides3up.1 +++ b/Master/texmf/doc/man/man1/pdfjam-slides3up.1 @@ -32,14 +32,14 @@ many of the capabilities of the pdfpages package for pdflatex\&. A working installation of pdflatex, with the pdfpages package, is required\&. .PP -pdfjam-slides3up operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdfjam-slides3up operates on one or more PDF files, and (either with +the '--batch' option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-3up' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdfjam-slides3up --suffix '-1x3' --batch myslides1.pdf myslides2.pdf +.B pdfjam-slides3up --suffix '1x3' --batch myslides1.pdf myslides2.pdf .RE .PP will result in files named 'myslides1-1x3.pdf' and 'myslides2-1x3.pdf'. diff --git a/Master/texmf/doc/man/man1/pdfjam-slides3up.man1.pdf b/Master/texmf/doc/man/man1/pdfjam-slides3up.man1.pdf Binary files differnew file mode 100644 index 00000000000..9e7478dca0f --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfjam-slides3up.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfjam-slides6up.1 b/Master/texmf/doc/man/man1/pdfjam-slides6up.1 index 1508369a807..6e90363bc6f 100644 --- a/Master/texmf/doc/man/man1/pdfjam-slides6up.1 +++ b/Master/texmf/doc/man/man1/pdfjam-slides6up.1 @@ -31,14 +31,14 @@ many of the capabilities of the pdfpages package for pdflatex\&. A working installation of pdflatex, with the pdfpages package, is required\&. .PP -pdfjam-slides6up operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdfjam-slides6up operates on one or more PDF files, and (either with +the '--batch' option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-6up' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdfjam-slides6up --suffix '-2x3' --batch myslides1.pdf myslides2.pdf +.B pdfjam-slides6up --suffix '2x3' --batch myslides1.pdf myslides2.pdf .RE .PP will result in files named 'myslides1-2x3.pdf' and 'myslides2-2x3.pdf'. diff --git a/Master/texmf/doc/man/man1/pdfjam-slides6up.man1.pdf b/Master/texmf/doc/man/man1/pdfjam-slides6up.man1.pdf Binary files differnew file mode 100644 index 00000000000..f10fe83610c --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfjam-slides6up.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfjam.man1.pdf b/Master/texmf/doc/man/man1/pdfjam.man1.pdf Binary files differnew file mode 100644 index 00000000000..47e1b5e01d7 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfjam.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfjoin.man1.pdf b/Master/texmf/doc/man/man1/pdfjoin.man1.pdf Binary files differnew file mode 100644 index 00000000000..a3d180b3176 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfjoin.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfnup.1 b/Master/texmf/doc/man/man1/pdfnup.1 index 51d7aad203e..86953387e89 100644 --- a/Master/texmf/doc/man/man1/pdfnup.1 +++ b/Master/texmf/doc/man/man1/pdfnup.1 @@ -21,15 +21,15 @@ Source files are processed sequentially into a single output unless the '--batch' option is used, in which case they are processed separately. .PP -pdfnup operates on one or more PDF files, and (either with the -'--batch' option or with '--outfile DIR' where 'DIR' is a directory) the +pdfnup operates on one or more PDF files, and (either with the '--batch' +option or with '--outfile DIR' where 'DIR' is a directory) the resulting files have the suffix '-nup' applied to their names by default. To change the suffix, use the '--suffix' option, for example .PP .RS -.B pdfnup --nup 2x2 --suffix '-2x2' --batch myfile1.pdf myfile2.pdf +.B pdfnup --nup 2x2 --suffix '2x2' --batch myfile1.pdf myfile2.pdf .RE .PP will result in files named 'myfile1-2x2.pdf' and 'myfile2-2x2.pdf'. diff --git a/Master/texmf/doc/man/man1/pdfnup.man1.pdf b/Master/texmf/doc/man/man1/pdfnup.man1.pdf Binary files differnew file mode 100644 index 00000000000..f49eb2532cf --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfnup.man1.pdf diff --git a/Master/texmf/doc/man/man1/pdfpun.man1.pdf b/Master/texmf/doc/man/man1/pdfpun.man1.pdf Binary files differnew file mode 100644 index 00000000000..e1023beee12 --- /dev/null +++ b/Master/texmf/doc/man/man1/pdfpun.man1.pdf diff --git a/Master/tlpkg/libexec/ctan2tds b/Master/tlpkg/libexec/ctan2tds index 651cbc117cd..a45d2e945bc 100755 --- a/Master/tlpkg/libexec/ctan2tds +++ b/Master/tlpkg/libexec/ctan2tds @@ -2182,6 +2182,7 @@ sub domans my $manpatt = $specialmans{$package}; return unless $manpatt; &install ("$TOPDEST/texmf/doc/man/man1/", $manpatt); + &tl_man_to_pdf (); # make pdfs for them } # When a package has man pages, we want to update the pdf versions of @@ -2201,7 +2202,11 @@ sub tl_man_to_pdf for my $man (<$pkg_man/man1/*>) { (my $pdf_man = $man) =~ s,^.*/,,; # just foo.1, no directories $pdf_man =~ s/1$/man1.pdf/; # foo.1 -> foo.man1.pdf - &SYSTEM ("$CP $Master_man/man1/$pdf_man $pkg_man/man1"); # copy existing + # + my $Master_pdf_man = "$Master_man/man1/$pdf_man"; + if (-r $Master_pdf_man) { + &SYSTEM ("$CP $Master_pdf_man $pkg_man/man1/"); # copy existing + } } &SYSTEM ("cd $pkg_man && make DIR=man1"); # build new pdfs |