summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-07-13 22:32:59 +0000
committerKarl Berry <karl@freefriends.org>2016-07-13 22:32:59 +0000
commit340fd1eddc14e61d3f7e4b493269dcb960cdb3bc (patch)
treedb43600721c0ef5621e6dd081a7534cf8e6edb6e /Master
parent9ba411b76cebc96643f89f5f0e6d6298c0b4fda8 (diff)
graphics-def (13jul16)
git-svn-id: svn://tug.org/texlive/trunk@41687 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/graphics-def/README.md4
-rw-r--r--Master/texmf-dist/tex/latex/graphics-def/dvipdfmx.def67
-rw-r--r--Master/texmf-dist/tex/latex/graphics-def/dvips.def195
-rw-r--r--Master/texmf-dist/tex/latex/graphics-def/luatex.def21
-rw-r--r--Master/texmf-dist/tex/latex/graphics-def/pdftex.def21
-rw-r--r--Master/texmf-dist/tex/latex/graphics-def/xetex.def49
6 files changed, 283 insertions, 74 deletions
diff --git a/Master/texmf-dist/doc/latex/graphics-def/README.md b/Master/texmf-dist/doc/latex/graphics-def/README.md
index 023a84501e4..0fbf98c58d7 100644
--- a/Master/texmf-dist/doc/latex/graphics-def/README.md
+++ b/Master/texmf-dist/doc/latex/graphics-def/README.md
@@ -1,12 +1,12 @@
# graphics-def
-## 2016/07/02 release
+## 2016/07/11 release
`.def` files for latex color and graphics packages,
contributed by multiple authors, extending the collection
available in latex/required/graphics.
-
+* dvips.def (from latex/required/graphics)
* luatex.def (for luatex > 0.87)
* pdftex.def from https://github.com/ho-tex/pdftex-def
* xetex.def from https://puszcza.gnu.org.ua/projects/latexfmxdef
diff --git a/Master/texmf-dist/tex/latex/graphics-def/dvipdfmx.def b/Master/texmf-dist/tex/latex/graphics-def/dvipdfmx.def
index 735e7f8961c..ab455ad1cd5 100644
--- a/Master/texmf-dist/tex/latex/graphics-def/dvipdfmx.def
+++ b/Master/texmf-dist/tex/latex/graphics-def/dvipdfmx.def
@@ -16,13 +16,30 @@
%% https://github.com/latex3/graphics-def/issues
%%
\ProvidesFile{dvipdfmx.def}
- [2016/07/02 v4.10 LaTeX color/graphics driver for dvipdfmx (L3/ChoF)]
+ [2016/07/11 v4.12 LaTeX color/graphics driver for dvipdfmx (L3/ChoF)]
%
+% miniltx.tex does not define \PackageWarning
+\@ifundefined{PackageWarning}{%
+ \def\PackageWarning#1#2{%
+ \begingroup
+ \def\@spaces{\space\space\space\space}%
+ \ifx\on@line\@undefined\def\on@line{}\fi
+ \newlinechar=10 %
+ \def\MessageBreak{%
+ ^^J(#1)\@spaces\@spaces\@spaces\@spaces
+ }%
+ \immediate\write16{^^JPackage #1 Warning: #2\on@line.^^J}%
+ \endgroup
+ }%
+}{}
+
+\def\GPT@warn{\PackageWarning{dvipdfmx.def}}%
+
\def\c@lor@arg#1{%
\dimen@#1\p@
\ifdim\dimen@<\z@\dimen@\maxdimen\fi
\ifdim\dimen@>\p@
- \PackageError{color}{Argument `#1' not in range [0,1]}\@ehd
+ \PackageError{color}{Argument `#1' not in range [0,1]}{}%
\fi}
\def\color@gray#1#2{%
\c@lor@arg{#2}%
@@ -66,7 +83,7 @@
\def\color@named#1#2{\c@lor@@named#2,,\@@#1}
\def\c@lor@@named#1,#2,#3\@@#4{%
\@ifundefined{col@#1}%
- {\PackageError{color}{Undefined color `#1'}\@ehd}%
+ {\PackageError{color}{Undefined color `#1'}{}}%
{\edef#4{ #1}}%
}
\def\c@lor@to@ps#1 #2\@@{\csname c@lor@ps@#1\endcsname#2 \@@}
@@ -95,18 +112,7 @@
%
% import from pdftex.def
%
-\begingroup\expandafter\expandafter\expandafter\endgroup
-\expandafter\ifx\csname RequirePackage\endcsname\relax
- \input infwarerr.sty\relax
- \input ltxcmds.sty\relax
-\else
- \RequirePackage{infwarerr}[2007/09/09]%
- \RequirePackage{ltxcmds}[2010/12/07]%
-\fi
-
-\def\GPT@error{\@PackageError{dvipdfmx.def}}%
-\def\GPT@warn{\@PackageWarning{dvipdfmx.def}}%
-\let\GPT@pagebox@option\ltx@empty
+\let\GPT@pagebox@option\@empty
\begingroup
\toks@{%
\define@key{Gin}{page}{\def\Gin@page{#1}}
@@ -117,7 +123,7 @@
\expandafter\let\expandafter\GPT@pagebox%
\csname GPT@pagebox@#1\endcsname
\ifx\GPT@pagebox\relax
- \let\GPT@pagebox\ltx@empty
+ \let\GPT@pagebox\@empty
\GPT@warn{%
Unknown value `#1' for `pagebox'.\MessageBreak
Supported values:\MessageBreak
@@ -128,10 +134,10 @@
\fi%
}%
}
-\ltx@IfUndefined{define@key}{
+\@ifundefined{define@key}{
\edef\x{\endgroup
\noexpand\AtBeginDocument{%
- \noexpand\ltx@IfUndefined{define@key}{}{\the\toks@}%
+ \noexpand\@ifundefined{define@key}{}{\the\toks@}%
}%
}\x
}{%
@@ -184,7 +190,7 @@
\@latex@error
{Cannot run pipe command. Try --shell-escape^^J%
(--enable-pipes in MikTeX) option}%
- \@ehc
+ {}%
\else
\loop
\read\@inputcheck to\@tempa
@@ -211,7 +217,7 @@
\@latex@error
{Cannot run pipe command. Try --shell-escape^^J%
(--enable-pipes in MikTeX) option}%
- \@ehc
+ {}%
\else
\loop
\read\@inputcheck to\@tempa
@@ -235,7 +241,7 @@
\else
\@latex@error
{Cannot determine size of image (no BoundingBox)}%
- \@ehc
+ {}%
\gdef\@gtempa{0 0 72 72 }%
\fi
\endgroup
@@ -246,14 +252,14 @@
\def\Gin@page{!}
\def\Gin@mask{!}
\newif\ifGin@interpolate\Gin@interpolatefalse
-\let\GPT@pagebox\ltx@empty
+\let\GPT@pagebox\@empty
\def\Ginclude@pdf#1{%
\message{<#1>}%
\bgroup
\def\@tempa{!}%
\special{pdf:epdf\space
\ifx\Gin@page\@tempa\else page\space\Gin@page\space\fi
- \ifx\GPT@pagebox\ltx@empty\else pagebox\space\GPT@pagebox\space\fi
+ \ifx\GPT@pagebox\@empty\else pagebox\space\GPT@pagebox\space\fi
bbox\space\Gin@llx\space\Gin@lly\space\Gin@urx\space\Gin@ury\space
clip\space\ifGin@clip 1\else 0\fi\space
\ifx\Gin@scalex\@tempa\else width\space\the\Gin@req@width\space\fi
@@ -423,13 +429,20 @@
% v4.10
% Support new (no)setpagesize option of graphics and color.
+% v4.11
+% Use \special{pdf:pagesize ...} instead of \special{papersize=...}
+% to support \mag (dvipdfmx only)
\@ifundefined{ifGin@setpagesize}
{\expandafter\let\csname ifGin@setpagesize\expandafter\endcsname
\csname iftrue\endcsname}
{}
\ifGin@setpagesize
\ifx\paperwidth\@undefined\else
-\AtBeginDocument{\AtBeginDvi{%
+\AtBeginDocument{%
+% If a package has changed \mag, assume it knows what it is doing
+% and leave page size alone
+\ifnum\mag=\@m
+\AtBeginDvi{%
\begingroup
\ifx\stockwidth\@undefined\else
\paperwidth\stockwidth
@@ -437,10 +450,12 @@
\fi
\ifdim\paperwidth>\z@
\ifdim\paperheight>\z@
-\special{papersize=\the\paperwidth,\the\paperheight}%
+\special{pdf:pagesize width \the\paperwidth\space height \the\paperheight}%
\fi
\fi
-\endgroup}}
+\endgroup}%
+\fi
+}
\fi
\fi
diff --git a/Master/texmf-dist/tex/latex/graphics-def/dvips.def b/Master/texmf-dist/tex/latex/graphics-def/dvips.def
new file mode 100644
index 00000000000..b3b65bf8d0f
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/graphics-def/dvips.def
@@ -0,0 +1,195 @@
+%%
+%% This is file `dvips.def',
+%% original generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% drivers.dtx (with options: `dvips,color1,psrulesZ,dosrules,macrules')
+%%
+%% drivers.dtx Copyright (C) 1994 David Carlisle Sebastian Rahtz
+%% Copyright (C) 1995 1996 1997 1998 1999 David Carlisle
+%% Copyright (C) 2000--2016 David Carlisle, LaTeX3 Project
+%%
+%% 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 the LaTeX3 Project.
+%%
+%% https://github.com/latex3/graphics-def/issues
+%%
+\ProvidesFile{dvips.def}
+ [2016/07/10 v3.1a Driver-dependent file (DPC,SPQR)]
+\def\c@lor@arg#1{%
+ \dimen@#1\p@
+ \ifdim\dimen@<\z@\dimen@\maxdimen\fi
+ \ifdim\dimen@>\p@
+ \PackageError{color}{Argument `#1' not in range [0,1]}\@ehd
+ \fi}
+\def\color@gray#1#2{%
+ \c@lor@arg{#2}%
+ \edef#1{gray #2}%
+ }
+\def\color@cmyk#1#2{\c@lor@@cmyk#2\@@#1}
+\def\c@lor@@cmyk#1,#2,#3,#4\@@#5{%
+ \c@lor@arg{#4}%
+ \c@lor@arg{#1}%
+ \c@lor@arg{#2}%
+ \c@lor@arg{#3}%
+ \edef#5{cmyk #1 #2 #3 #4}%
+ }
+\def\color@rgb#1#2{\c@lor@@rgb#2\@@#1}
+\def\c@lor@@rgb#1,#2,#3\@@#4{%
+ \c@lor@arg{#1}%
+ \c@lor@arg{#2}%
+ \c@lor@arg{#3}%
+ \edef#4{rgb #1 #2 #3}%
+ }
+\def\color@RGB#1#2{\c@lor@@RGB#2\@@#1}
+\def\c@lor@@RGB#1,#2,#3\@@#4{%
+ \c@lor@RGB@rgb{#1}\@tempa
+ \c@lor@RGB@rgb{#2}\@tempb
+ \c@lor@RGB@rgb{#3}\@tempc
+ \c@lor@@rgb\@tempa,\@tempb,\@tempc\@@#4%
+ }
+\def\c@lor@RGB@rgb#1#2{%
+ \dimen@#1\p@
+ \divide\dimen@\@cclv
+ \edef#2{\strip@pt\dimen@}}
+\def\color@hsb#1#2{\c@lor@@hsb#2\@@#1}
+\def\c@lor@@hsb#1,#2,#3\@@#4{%
+ \c@lor@arg{#1}%
+ \c@lor@arg{#2}%
+ \c@lor@arg{#3}%
+ \edef#4{hsb #1 #2 #3}%
+ }
+\def\color@named#1#2{\c@lor@@named#2,,\@@#1}
+\def\c@lor@@named#1,#2,#3\@@#4{%
+ \@ifundefined{col@#1}%
+ {\PackageError{color}{Undefined color `#1'}\@ehd}%
+ {\edef#4{ #1}}%
+ }
+\def\c@lor@to@ps#1 #2\@@{\csname c@lor@ps@#1\endcsname#2 \@@}
+\def\c@lor@ps@#1 #2\@@{TeXDict begin #1 end}
+\def\c@lor@ps@rgb#1\@@{#1 setrgbcolor}
+\def\c@lor@ps@hsb#1\@@{#1 sethsbcolor}
+\def\c@lor@ps@cmyk#1\@@{#1 setcmykcolor}
+\def\c@lor@ps@gray#1\@@{#1 setgray}
+\def\current@color{ Black}
+\def\set@color{%
+ \special{color push \current@color
+ }\aftergroup\reset@color}
+\def\reset@color{\special{%
+ color pop}}
+\def\set@page@color{\special{%
+ background \current@color}}
+\def\define@color@named#1#2{%
+ \expandafter\let\csname col@#1\endcsname\@nnil}
+ \def\no@page@color{\special{background \string"newpath clip}}
+\def\Ginclude@eps#1{%
+ \message{<#1>}%
+ \bgroup
+ \def\@tempa{!}%
+ \dimen@\Gin@req@width
+ \dimen@ii.1bp%
+ \divide\dimen@\dimen@ii
+ \@tempdima\Gin@req@height
+ \divide\@tempdima\dimen@ii
+ \special{PSfile="#1"\space
+ llx=\Gin@llx\space
+ lly=\Gin@lly\space
+ urx=\Gin@urx\space
+ ury=\Gin@ury\space
+ \ifx\Gin@scalex\@tempa\else rwi=\number\dimen@\space\fi
+ \ifx\Gin@scaley\@tempa\else rhi=\number\@tempdima\space\fi
+ \ifGin@clip clip\fi}%
+ \egroup}
+\def\Ginclude@bmp#1{%
+ \message{<#1>}%
+ \dimen@\Gin@req@height
+ \advance\dimen@ by-\Gin@lly bp
+ \kern-\Gin@llx bp\raise\Gin@req@height\hbox{%
+ \ifdim\Gin@urx bp=\z@
+ \ifdim\Gin@ury bp=\z@
+ \special{em: graph #1}%
+ \else
+ \special{em: graph #1,\Gin@urx bp}%
+ \fi
+ \else
+ \special{em: graph #1,\Gin@urx bp,\Gin@ury bp}%
+ \fi
+ }%
+}
+\def\oztex@include#1#2{%
+ \dimen@1bp%
+ \divide\Gin@req@width\dimen@
+ \divide\Gin@req@height\dimen@
+ \special{#1=#2\space
+ \@width=\number\Gin@req@width \space
+ \@height=\number\Gin@req@height}}
+\def\Ginclude@pntg{\oztex@include{pntg}}
+\def\Ginclude@pict{\oztex@include{pict}}
+\def\Grot@start{%
+ \special{ps: gsave currentpoint
+ currentpoint translate \Grot@angle\space neg
+ rotate neg exch neg exch translate}}
+\def\Grot@end{\special{ps: currentpoint grestore moveto}}
+\def\Gscale@start{\special{ps: currentpoint currentpoint translate
+ \Gscale@x\space \Gscale@y\space scale neg exch neg exch translate}}
+\def\Gscale@end{\special{ps: currentpoint currentpoint translate
+ 1 \Gscale@x\space div 1 \Gscale@y\space div scale
+ neg exch neg exch translate}}
+\def\Gin@PS@raw#1{\special{ps: #1}}
+\def\Gin@PS@restored#1{\special{" #1}}
+\def\Gin@PS@literal@header#1{\AtBeginDvi{\special{! #1}}}
+\def\Gin@PS@file@header#1{\AtBeginDvi{\special{header=#1}}}
+\@ifundefined{ifGin@setpagesize}
+ {\expandafter\let\csname ifGin@setpagesize\expandafter\endcsname
+ \csname iftrue\endcsname}
+ {}
+\ifGin@setpagesize
+\ifx\paperwidth\@undefined\else
+ \AtBeginDocument{%
+% If a package has changed \mag, assume it knows what it is doing
+% and leave page size alone
+\ifnum\mag=\@m
+ \AtBeginDvi{%
+ \begingroup
+ \ifx\stockwidth\@undefined\else
+ \paperwidth\stockwidth
+ \paperheight\stockheight
+ \fi
+ \ifdim\paperwidth>\z@
+ \ifdim\paperheight>\z@
+ \special{papersize=\the\paperwidth,\the\paperheight}%
+ \fi
+ \fi
+ \endgroup}%
+ \fi
+ }
+\fi
+\fi
+\def\Gin@extensions{.eps,.ps,.eps.gz,.ps.gz,.eps.Z,.mps}
+\@namedef{Gin@rule@.ps}#1{{eps}{.ps}{#1}}
+\@namedef{Gin@rule@.eps}#1{{eps}{.eps}{#1}}
+\@namedef{Gin@rule@.mps}#1{{eps}{.mps}{#1}}
+\@namedef{Gin@rule@.pz}#1{{eps}{.bb}{#1}}
+\@namedef{Gin@rule@.eps.Z}#1{{eps}{.eps.bb}{#1}}
+\@namedef{Gin@rule@.ps.Z}#1{{eps}{.ps.bb}{#1}}
+\@namedef{Gin@rule@.ps.gz}#1{{eps}{.ps.bb}{#1}}
+\@namedef{Gin@rule@.eps.gz}#1{{eps}{.eps.bb}{#1}}
+\@namedef{Gin@rule@*}#1{{eps}{\Gin@ext}{#1}}
+\@namedef{Gin@rule@.pcx}#1{{bmp}{}{#1}}
+\@namedef{Gin@rule@.bmp}#1{{bmp}{}{#1}}
+\@namedef{Gin@rule@.msp}#1{{bmp}{}{#1}}
+\@namedef{Gin@rule@.pict}#1{{pict}{}{#1}}
+\@namedef{Gin@rule@.pntg}#1{{pntg}{}{#1}}
+\endinput
+%%
+%% End of file `dvips.def'.
diff --git a/Master/texmf-dist/tex/latex/graphics-def/luatex.def b/Master/texmf-dist/tex/latex/graphics-def/luatex.def
index a92a37eb074..8978d688320 100644
--- a/Master/texmf-dist/tex/latex/graphics-def/luatex.def
+++ b/Master/texmf-dist/tex/latex/graphics-def/luatex.def
@@ -1,4 +1,4 @@
-\ProvidesFile{luatex.def}[2016/07/01 v0.01f Graphics/Color for luaTeX]
+\ProvidesFile{luatex.def}[2016/07/11 v0.01f Graphics/Color for luaTeX]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% LaTeX Colour and Graphics support for luatex
@@ -61,8 +61,9 @@
% 2016/05/21 Version 0.01c fix for graphics/4472
% 2016/06/24 Version 0.01d support the (no)setpagesize option.
% 2016/06/17 Version 0.01e guards for contributed packages and plain TeX
+% 2016/07/11 Version 0.01f test for \mag added to all drivers, missing \fi in pagebox
%
-% Prefix of internal commands for this file `pdftex.def':
+% Prefix of internal commands for this file `luatex.def':
% \GPT@ (Graphics bundle PdfTex driver, even though this is for luatex)
@@ -115,6 +116,9 @@
\ifGin@setpagesize
\ifx\paperwidth\@undefined\else
\AtBeginDocument{%
+% If a package has changed \mag, assume it knows what it is doing
+% and leave page size alone
+\ifnum\mag=\@m
\ltx@IfUndefined{stockwidth}{%
\ltx@IfUndefined{paperwidth}{%
}{%
@@ -133,6 +137,7 @@
\fi
\fi
}%
+\fi
}
\fi
\fi
@@ -356,6 +361,7 @@
Supported values:\MessageBreak
mediabox, cropbox, bleedbox, trimbox, artbox%
}%
+ \fi
}%
\def\GPT@pagebox@mediabox{mediabox}%
\let\GPT@pagebox@cropbox\ltx@empty
@@ -997,16 +1003,9 @@
\@namedef{Gin@rule@.jpeg}#1{{jpg}{.jpeg}{#1}}%
\@namedef{Gin@rule@.JPG}#1{{jpg}{.JPG}{#1}}%
\@namedef{Gin@rule@.JPEG}#1{{jpg}{.JPEG}{#1}}%
- \@ifpackageloaded{pst-pdf}% hv 20160630
- {\def\Gin@extensions{%
+ \def\Gin@extensions{%
.png,.pdf,.jpg,.mps,.jpeg,.jbig2,.jb2,%
.PNG,.PDF,.JPG,.JPEG,.JBIG2,.JB2}%
- }%
- {\def\Gin@extensions{%
- .png,.pdf,.jpg,.mps,.jpeg,.jbig2,.jb2,%
- .PNG,.PDF,.JPG,.JPEG,.JBIG2,.JB2,%
- .eps}%
- }%
\@namedef{Gin@rule@.jb2}#1{{jbig2}{.jb2}{#1}}%
\@namedef{Gin@rule@.jbig2}#1{{jbig2}{.jbig2}{#1}}%
@@ -1263,6 +1262,8 @@
\ifx\includegraphics\@undefined\else
\@ifpackageloaded{pst-pdf}{}{%
\@ifpackageloaded{pdftricks}{}{%
+ % only add .eps to file extension list if epstopdf is loaded
+ \edef\Gin@extensions{\Gin@extensions,.eps}%
\RequirePackage{epstopdf-base}%
}%
}%
diff --git a/Master/texmf-dist/tex/latex/graphics-def/pdftex.def b/Master/texmf-dist/tex/latex/graphics-def/pdftex.def
index 4b7a517ca10..3fca115295d 100644
--- a/Master/texmf-dist/tex/latex/graphics-def/pdftex.def
+++ b/Master/texmf-dist/tex/latex/graphics-def/pdftex.def
@@ -1,4 +1,4 @@
-\ProvidesFile{pdftex.def}[2016/07/01 v0.06i Graphics/color for pdfTeX]
+\ProvidesFile{pdftex.def}[2016/07/10 v0.06j Graphics/color for pdfTeX]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% LaTeX Colour and Graphics support for PDFTeX
@@ -268,7 +268,11 @@
% * typo
% 2016/06/17 v0.6h (DPC)
% * guards for contributed packages and plain TeX
+% 2016/07/1o v0.6j (DPC)
+% * don't set page size for non standard \mag
%
+
+
% Prefix of internal commands for this file `pdftex.def':
% \GPT@ (Graphics bundle PdfTex driver)
@@ -452,6 +456,9 @@
\ifGin@setpagesize
\ifx\paperwidth\@undefined\else
\AtBeginDocument{%
+% If a package has changed \mag, assume it knows what it is doing
+% and leave page size alone
+\ifnum\mag=\@m
\ltx@IfUndefined{stockwidth}{%
\ltx@IfUndefined{paperwidth}{%
}{%
@@ -470,6 +477,7 @@
\fi
\fi
}%
+\fi
}
\fi
\fi
@@ -1566,16 +1574,9 @@ E \else
\else
\ifnum\driver@release>9 %
\ifnum\pdfminorversion>3 %
- \@ifpackageloaded{pst-pdf}% hv 20160630
- {\def\Gin@extensions{%
+ \def\Gin@extensions{%
.png,.pdf,.jpg,.mps,.jpeg,.jbig2,.jb2,%
.PNG,.PDF,.JPG,.JPEG,.JBIG2,.JB2}%
- }%
- {\def\Gin@extensions{%
- .png,.pdf,.jpg,.mps,.jpeg,.jbig2,.jb2,%
- .PNG,.PDF,.JPG,.JPEG,.JBIG2,.JB2,%
- .eps}%
- }%
\fi
\@namedef{Gin@rule@.jb2}#1{{jbig2}{.jb2}{#1}}%
\@namedef{Gin@rule@.jbig2}#1{{jbig2}{.jbig2}{#1}}%
@@ -1946,6 +1947,8 @@ E \else
\else
\@ifpackageloaded{graphics}{
\ifnum\pdf@shellescape>0 %
+ % only add .eps to file extension list if epstopdf is loaded
+ \edef\Gin@extensions{\Gin@extensions,.eps}%
\RequirePackage{epstopdf-base}[2009/07/12]%
\fi}{}
\fi
diff --git a/Master/texmf-dist/tex/latex/graphics-def/xetex.def b/Master/texmf-dist/tex/latex/graphics-def/xetex.def
index 1ea45571252..f30eebbc99a 100644
--- a/Master/texmf-dist/tex/latex/graphics-def/xetex.def
+++ b/Master/texmf-dist/tex/latex/graphics-def/xetex.def
@@ -22,6 +22,10 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Version History
%%
+%% 2016/07/11 [DPC] [v4.10] \mag test added to all the files
+%% Remove spurious dependency on external packages.
+%% Avoid \@ehd help text (not defined by miniltx)
+%%
%% 2016/07/02 [DPC] [v4.09] support new (no)setpagesize options of
%% color and graphics packages.
%% revert pagecolor code to match dvips
@@ -118,7 +122,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% emacs-page
\ProvidesFile{xetex.def}
- [2016/07/02 v4.09 LaTeX color/graphics driver for XeTeX (L3/RRM/JK)]
+ [2016/07/11 v4.10 LaTeX color/graphics driver for XeTeX (L3/RRM/JK)]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% make sure we can use " with correct catcode
@@ -127,10 +131,11 @@
}
% miniltx.tex does not define \PackageWarning
-% or \PackageWarningNoLine.
\@ifundefined{PackageWarning}{%
\def\PackageWarning#1#2{%
\begingroup
+ \def\@spaces{\space\space\space\space}%
+ \ifx\on@line\@undefined\def\on@line{}\fi
\newlinechar=10 %
\def\MessageBreak{%
^^J(#1)\@spaces\@spaces\@spaces\@spaces
@@ -139,11 +144,9 @@
\endgroup
}%
}{}
-\@ifundefined{PackageWarningNoLine}{%
- \def\PackageWarningNoLine#1#2{%
- \PackageWarning{#1}{#2\@gobble}%
- }%
-}{}
+
+\def\GPT@warn{\PackageWarning{xetex.def}}%
+
\@ifundefined{on@line}{%
\def\on@line{ on input line \the\inputlineno}%
}{}
@@ -167,7 +170,7 @@
\dimen@#1\p@
\ifdim\dimen@<\z@\dimen@\maxdimen\fi
\ifdim\dimen@>\p@
- \PackageError{color}{Argument `#1' not in range [0,1]}\@ehd
+ \PackageError{color}{Argument `#1' not in range [0,1]}{}%
\fi}
\def\color@gray#1#2{%
\c@lor@arg{#2}%
@@ -209,7 +212,7 @@
\def\color@named#1#2{\c@lor@@named#2,,\@@#1}
\def\c@lor@@named#1,#2,#3\@@#4{%
\@ifundefined{col@#1}%
- {\PackageError{color}{Undefined color `#1'}\@ehd}%
+ {\PackageError{color}{Undefined color `#1'}{}}%
{\edef#4{ #1}}%
}
@@ -304,29 +307,17 @@
%
% import from pdftex.def to support pagebox=artbox etc. in XeLaTeX
%
-\begingroup\expandafter\expandafter\expandafter\endgroup
-\expandafter\ifx\csname RequirePackage\endcsname\relax
- \input infwarerr.sty\relax
- \input ltxcmds.sty\relax
-\else
- \RequirePackage{infwarerr}[2007/09/09]%
- \RequirePackage{ltxcmds}[2010/12/07]%
-\fi
-
-\def\GPT@error{\@PackageError{xetex.def}}%
-\def\GPT@warn{\@PackageWarning{xetex.def}}%
-%
% \Gin@XeTeX@page: page number of pdf image or \@empty otherwise.
% This code adapted from pdftex.def
\let\Gin@XeTeX@page\@empty
-\let\GPT@pagebox\ltx@empty
+\let\GPT@pagebox\@empty
\begingroup
\toks@{\define@key{Gin}{page}{\def\Gin@XeTeX@page{#1}}
\define@key{Gin}{pagebox}{%
\expandafter\let\expandafter\GPT@pagebox%
\csname GPT@pagebox@#1\endcsname
\ifx\GPT@pagebox\relax
- \let\GPT@pagebox\ltx@empty
+ \let\GPT@pagebox\@empty
\GPT@warn{%
Unknown value `#1' for `pagebox'.\MessageBreak
Supported values:\MessageBreak
@@ -373,7 +364,7 @@
}%
}\type@ext
\ifx\type@ext\G@pdf@ext
- \ifx\GPT@pagebox\ltx@empty\else
+ \ifx\GPT@pagebox\@empty\else
\edef\picpagebox{ \GPT@pagebox}\fi
\ifx\Gin@XeTeX@page\@empty\else
\edef\picpage{ page\Gin@XeTeX@page}\fi
@@ -502,7 +493,7 @@
\ifx\type@ext\G@pdf@ext
\ifx\Gin@XeTeX@page\@empty \def\picpage{}%
\else \edef\picpage{ page\Gin@XeTeX@page}\fi
- \ifx\GPT@pagebox\ltx@empty \def\picpagebox{}%
+ \ifx\GPT@pagebox\@empty \def\picpagebox{}%
\else \edef\picpagebox{ \GPT@pagebox}\fi
\fi
\setbox0=\hbox{%
@@ -696,8 +687,11 @@
\ifGin@setpagesize
\ifx\paperwidth\@undefined\else
\AtBeginDocument{%
-\ltx@IfUndefined{stockwidth}{%
-\ltx@IfUndefined{paperwidth}{%
+% If a package has changed \mag, assume it knows what it is doing
+% and leave page size alone
+\ifnum\mag=\@m
+\@ifundefined{stockwidth}{%
+\@ifundefined{paperwidth}{%
}{%
\ifdim\paperwidth>0pt\relax
\ifdim\paperheight>0pt\relax
@@ -714,6 +708,7 @@
\fi
\fi
}%
+\fi
}
\fi
\fi