summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/gentombow
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-09-25 20:56:00 +0000
committerKarl Berry <karl@freefriends.org>2020-09-25 20:56:00 +0000
commit27e9cd38b110db74f7c9b10286f08660cea47695 (patch)
treed25bc88dcf7d16bc5e6ba229a2d49d4cc34cfa96 /Master/texmf-dist/tex/latex/gentombow
parent1d5b081799ba2c186771a3e7ad5196e2cdf48ba8 (diff)
gentombow (25sep20)
git-svn-id: svn://tug.org/texlive/trunk@56429 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/gentombow')
-rw-r--r--Master/texmf-dist/tex/latex/gentombow/bounddvi.sty37
1 files changed, 30 insertions, 7 deletions
diff --git a/Master/texmf-dist/tex/latex/gentombow/bounddvi.sty b/Master/texmf-dist/tex/latex/gentombow/bounddvi.sty
index 35432df5f05..3e355d63c1d 100644
--- a/Master/texmf-dist/tex/latex/gentombow/bounddvi.sty
+++ b/Master/texmf-dist/tex/latex/gentombow/bounddvi.sty
@@ -1,7 +1,7 @@
%
% bounddvi.sty
-% 2016/12/28 v7.2-v7.0 h.y.acetaminophen@gmail.com
-% 2004/12/15 v6.0-v1.0 inoue@ma.ns.tcu.ac.jp
+% 2020/09/25 v8.0-v7.0 h.y.acetaminophen [at] gmail.com
+% 2004/12/15 v6.0-v1.0 inoue [at] ma.ns.tcu.ac.jp
%
% This package, originally written by Koichi Inoue
% and modified by Hironobu Yamashita, is distributed
@@ -10,7 +10,7 @@
%
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{bounddvi}[2016/12/28 v7.2 bounddvi]
+\ProvidesPackage{bounddvi}[2020/09/25 v8.0 bounddvi]
% catcode trick to hide \iftombow ... \else ... \fi
% since \iftombow is defined only in pLaTeX.
@@ -50,6 +50,33 @@ Q \fi
% reset catcode trick
\catcode`\Q=11\relax
+%% Since LaTeX2e 2020-10-01, \@begindocumenthook is deprecated
+%% and \UseHook{begindocument} etc. are used.
+%% This code appends papersize special to the _end_ of the hook.
+%% (Note: support for old dvips is removed.)
+\ifx\AddToHook\@undefined\else
+ \AtBeginDocument{\AtBeginDvi{%
+ \begingroup
+ % if \stockwidth/\stockheight are defined & have effective
+ % values, copy them to \paperwidth/\paperheight
+ % for current group
+ \ifx\stockwidth\@undefined\else \ifdim\stockwidth>\z@
+ \paperwidth\stockwidth
+ \fi\fi
+ \ifx\stockheight\@undefined\else \ifdim\stockheight>\z@
+ \paperheight\stockheight
+ \fi\fi
+ % adjust for \mag and emit papersize special
+ \divide\paperwidth\@m\multiply\paperwidth\mag
+ \divide\paperheight\@m\multiply\paperheight\mag
+ \special{papersize=\the\paperwidth,\the\paperheight}%
+ \endgroup}}
+ \expandafter\endinput
+\fi
+
+%% The rest of this package is meant for
+%% LaTeX2e 2020-02-02 PL5 or older.
+
% following code is almost equivalent to
% \AtBeginDocument{\AtBeginDvi{...}}
% however, we append the specification to the _beginning_ of
@@ -59,16 +86,12 @@ Q \fi
\def\@prependto@begindocumenthook{\global\setbox\@begindvibox
\vbox{\csname yoko\endcsname\unvbox\@begindvibox
\begingroup
- % if \stockwidth/\stockheight are defined & have effective
- % values, copy them to \paperwidth/\paperheight
- % for current group
\ifx\stockwidth\@undefined\else \ifdim\stockwidth>\z@
\paperwidth\stockwidth
\fi\fi
\ifx\stockheight\@undefined\else \ifdim\stockheight>\z@
\paperheight\stockheight
\fi\fi
- % adjust for \mag and emit papersize special
\divide\paperwidth\@m\multiply\paperwidth\mag
\divide\paperheight\@m\multiply\paperheight\mag
\special{papersize=\the\paperwidth,\the\paperheight}%