[latex3-commits] [git/LaTeX3-latex3-graphics-def] master: support [a, b][c, d] in pdftex and luatex (5bd744f)
David Carlisle
d.p.carlisle at gmail.com
Sun Aug 9 16:28:05 CEST 2020
Repository : https://github.com/latex3/graphics-def
On branch : master
Link : https://github.com/latex3/graphics-def/commit/5bd744f62574c5268ab4c423d850d7c828fbcd66
>---------------------------------------------------------------
commit 5bd744f62574c5268ab4c423d850d7c828fbcd66
Author: David Carlisle <d.p.carlisle at gmail.com>
Date: Sun Aug 9 15:28:05 2020 +0100
support [a,b][c,d] in pdftex and luatex
>---------------------------------------------------------------
5bd744f62574c5268ab4c423d850d7c828fbcd66
README.md | 2 +-
luatex.def | 36 ++++++++++++++++++++++++++++++++++--
pdftex.def | 36 ++++++++++++++++++++++++++++++++++--
testfiles/luatex001.luatex.tlg | 4 ++--
testfiles/pdftex001.tlg | 4 ++--
5 files changed, 73 insertions(+), 9 deletions(-)
diff --git a/README.md b/README.md
index 41849da..20abc33 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
LaTeX support for color and graphics
====================================
-Release 2020-03-24
+Release 2020-08-09
This bundle contains the 'engine-dependent' part of support for
color and graphics in LaTeX2e (the code here will also function
diff --git a/luatex.def b/luatex.def
index 84ed110..ae5b9d8 100644
--- a/luatex.def
+++ b/luatex.def
@@ -2,6 +2,7 @@
%% Hans Hagen, Heiko Oberdiek and
%% Martin Schr\"oder
%% Copyright (C) 2016-2018 LaTeX3 project and Heiko Oberdiek
+%% Copyright (C) 2018-2020 LaTeX3 project
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
@@ -18,7 +19,7 @@
%% https://github.com/latex3/graphics-def/issues
%%
\ProvidesFile{luatex.def}
- [2018/01/08 v1.0l Graphics/color driver for luatex]
+ [2020/08/09 v1.1a Graphics/color driver for luatex]
\def\GPT at space{ }
\def\c at lor@arg#1{%
\dimen@#1\p@
@@ -141,10 +142,41 @@
\let\KV at Gin@natheight\KV at Gin@bbllx
\def\KV at Gin@bb{%
\PackageInfo{luatex.def}%
- {Option `bb' equivalent to `viewport' for luatex driver}%
+ {Option `bb' equivalent to `viewport' with the luatex driver}%
\KV at Gin@viewport
}%
+ \let\Gin at iii\Gin at iii@vp
}
+
+%%% this definition will be added to graphics.sty
+\def\Gin at iii@vp[#1,#2][#3,#4]#5{%
+ \begingroup
+ \let\Gin at viewport@code\Gin at viewport
+ \Gin at defaultbp\Gin at vllx{#1}%
+ \Gin at defaultbp\Gin at vlly{#2}%
+ \Gin at defaultbp\Gin at vurx{#3}%
+ \Gin at defaultbp\Gin at vury{#4}%
+ \Ginclude at graphics{#5}%
+ \endgroup}
+
+
+%%% this definition needs moving from graphicx.sty to graphics.sty
+\def\Gin at viewport{%
+ \let\Gin at ollx\Gin at llx
+ \let\Gin at olly\Gin at lly
+ \let\Gin at ourx\Gin at urx
+ \let\Gin at oury\Gin at ury
+ \dimen@\Gin at llx\p@\advance\dimen@ \Gin at vurx\p@
+ \edef\Gin at urx{\strip at pt\dimen@}%
+ \dimen@\Gin at lly\p@\advance\dimen@ \Gin at vury\p@
+ \edef\Gin at ury{\strip at pt\dimen@}%
+ \dimen@\Gin at llx\p@\advance\dimen@ \Gin at vllx\p@
+ \edef\Gin at llx{\strip at pt\dimen@}%
+ \dimen@\Gin at lly\p@\advance\dimen@ \Gin at vlly\p@
+ \edef\Gin at lly{\strip at pt\dimen@}}
+%%% end of temp addition
+
+
\def\Gread at pdftex#1{%
% Use low level test here not \IfFileExists to match \Gread at pdftex in
% pdftex.def and \Gread at eps test in graphics.
diff --git a/pdftex.def b/pdftex.def
index 0c9d2da..3e4ec02 100644
--- a/pdftex.def
+++ b/pdftex.def
@@ -2,6 +2,7 @@
%% Hans Hagen, Heiko Oberdiek and
%% Martin Schr\"oder
%% Copyright (C) 2016-2018 LaTeX3 project and Heiko Oberdiek
+%% Copyright (C) 2018-2020 LaTeX3 project
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3c
@@ -18,7 +19,7 @@
%% https://github.com/latex3/graphics-def/issues
%%
\ProvidesFile{pdftex.def}
- [2018/01/08 v1.0l Graphics/color driver for pdftex]
+ [2020/08/09 v1.1a Graphics/color driver for pdftex]
\def\GPT at space{ }
\def\c at lor@arg#1{%
\dimen@#1\p@
@@ -155,10 +156,41 @@ E \else
\let\KV at Gin@natheight\KV at Gin@bbllx
\def\KV at Gin@bb{%
\PackageInfo{pdftex.def}%
- {Option `bb' equivalent to `viewport' with pdftex driver}%
+ {Option `bb' equivalent to `viewport' with the pdftex driver}%
\KV at Gin@viewport
}%
+ \let\Gin at iii\Gin at iii@vp
}
+
+%%% this definition will be added to graphics.sty
+\def\Gin at iii@vp[#1,#2][#3,#4]#5{%
+ \begingroup
+ \let\Gin at viewport@code\Gin at viewport
+ \Gin at defaultbp\Gin at vllx{#1}%
+ \Gin at defaultbp\Gin at vlly{#2}%
+ \Gin at defaultbp\Gin at vurx{#3}%
+ \Gin at defaultbp\Gin at vury{#4}%
+ \Ginclude at graphics{#5}%
+ \endgroup}
+
+
+%%% this definition needs moving from graphicx.sty to graphics.sty
+\def\Gin at viewport{%
+ \let\Gin at ollx\Gin at llx
+ \let\Gin at olly\Gin at lly
+ \let\Gin at ourx\Gin at urx
+ \let\Gin at oury\Gin at ury
+ \dimen@\Gin at llx\p@\advance\dimen@ \Gin at vurx\p@
+ \edef\Gin at urx{\strip at pt\dimen@}%
+ \dimen@\Gin at lly\p@\advance\dimen@ \Gin at vury\p@
+ \edef\Gin at ury{\strip at pt\dimen@}%
+ \dimen@\Gin at llx\p@\advance\dimen@ \Gin at vllx\p@
+ \edef\Gin at llx{\strip at pt\dimen@}%
+ \dimen@\Gin at lly\p@\advance\dimen@ \Gin at vlly\p@
+ \edef\Gin at lly{\strip at pt\dimen@}}
+%%% end of temp addition
+
+
\def\Gread at pdftex#1{%
\expandafter\ifx\expandafter\relax\pdffilesize{#1}\relax
\expandafter\@secondoftwo
diff --git a/testfiles/luatex001.luatex.tlg b/testfiles/luatex001.luatex.tlg
index ace1f04..c2fcd2a 100644
--- a/testfiles/luatex001.luatex.tlg
+++ b/testfiles/luatex001.luatex.tlg
@@ -104,13 +104,13 @@ Completed box being shipped out [1]
...\TU/lmr/m/n/10 1
...\glue 0.0 plus 1.0fil
<../example-image-a.pdf><../example-image-a.pdf><./az2.pdf>
-Package luatex.def Info: Option `bb' equivalent to `viewport' for luatex driver on input line ....
+Package luatex.def Info: Option `bb' equivalent to `viewport' with the luatex driver on input line ....
<clip-1-2.jpg, id=23, 146.34676pt x 128.8815pt>
File: clip-1-2.jpg Graphic file (type jpg)
<use clip-1-2.jpg>
Package luatex.def Info: clip-1-2.jpg used on input line ....
(luatex.def) Requested size: 49.99988pt x 49.99988pt.
-Package luatex.def Info: Option `bb' equivalent to `viewport' for luatex driver on input line ....
+Package luatex.def Info: Option `bb' equivalent to `viewport' with the luatex driver on input line ....
<clip-1-2.png, id=25, 146.34676pt x 128.8815pt>
File: clip-1-2.png Graphic file (type png)
<use clip-1-2.png>
diff --git a/testfiles/pdftex001.tlg b/testfiles/pdftex001.tlg
index 3eed082..85e4b32 100644
--- a/testfiles/pdftex001.tlg
+++ b/testfiles/pdftex001.tlg
@@ -89,13 +89,13 @@ Completed box being shipped out [1]
...\OT1/cmr/m/n/10 1
...\glue 0.0 plus 1.0fil
<../example-image-a.pdf> <../example-image-a.pdf> <./az2.pdf>
-Package pdftex.def Info: Option `bb' equivalent to `viewport' with pdftex driver on input line ....
+Package pdftex.def Info: Option `bb' equivalent to `viewport' with the pdftex driver on input line ....
<clip-1-2.jpg, id=20, 146.34676pt x 128.8815pt>
File: clip-1-2.jpg Graphic file (type jpg)
<use clip-1-2.jpg>
Package pdftex.def Info: clip-1-2.jpg used on input line ....
(pdftex.def) Requested size: 49.99988pt x 49.99988pt.
-Package pdftex.def Info: Option `bb' equivalent to `viewport' with pdftex driver on input line ....
+Package pdftex.def Info: Option `bb' equivalent to `viewport' with the pdftex driver on input line ....
<clip-1-2.png, id=22, 146.34676pt x 128.8815pt>
File: clip-1-2.png Graphic file (type png)
<use clip-1-2.png>
More information about the latex3-commits
mailing list.