diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/geometry/geometry.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/geometry/geometry.sty | 34 |
1 files changed, 30 insertions, 4 deletions
diff --git a/Master/texmf-dist/tex/latex/geometry/geometry.sty b/Master/texmf-dist/tex/latex/geometry/geometry.sty index b46f4eea148..13084e18d21 100644 --- a/Master/texmf-dist/tex/latex/geometry/geometry.sty +++ b/Master/texmf-dist/tex/latex/geometry/geometry.sty @@ -8,6 +8,8 @@ %% %% Copyright (C) 1996-2010 %% by Hideo Umeki <latexgeometry@gmail.com> +%% Copyright (C) 2018 +%% by Hideo Umeki and David Carlisle https://github.com/davidcarlisle/geometry %% %% This work may be distributed and/or modified under the conditions of %% the LaTeX Project Public License, either version 1.3c of this license @@ -18,14 +20,14 @@ %% version 2005/12/01 or later. %% %% This work is "maintained" (as per the LPPL maintenance status) -%% by Hideo Umeki. +%% by David Carlisle. %% %% This work consists of the files geometry.dtx and %% the derived files: geometry.{sty,ins,drv}, geometry-samples.tex. %% \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{geometry} - [2010/09/12 v5.6 Page Geometry] + [2018/03/24 v5.7 Page Geometry] \RequirePackage{keyval}% \RequirePackage{ifpdf}% \RequirePackage{ifvtex}% @@ -72,6 +74,7 @@ \def\Gm@dvips{dvips}% \def\Gm@dvipdfm{dvipdfm}% \def\Gm@pdftex{pdftex}% +\def\Gm@luatex{luatex}% \def\Gm@xetex{xetex}% \def\Gm@vtex{vtex}% \def\Gm@true{true}% @@ -592,6 +595,8 @@ \Gm@doifelse{dvipdfm}{#1}{\Gm@setdriver{dvipdfm}}{\Gm@unsetdriver{dvipdfm}}}}% \define@key{Gm}{pdftex}[true]{\ifGm@preamble{pdftex}{% \Gm@doifelse{pdftex}{#1}{\Gm@setdriver{pdftex}}{\Gm@unsetdriver{pdftex}}}}% +\define@key{Gm}{luatex}[true]{\ifGm@preamble{luatex}{% + \Gm@doifelse{luatex}{#1}{\Gm@setdriver{luatex}}{\Gm@unsetdriver{luatex}}}}% \define@key{Gm}{xetex}[true]{\ifGm@preamble{xetex}{% \Gm@doifelse{xetex}{#1}{\Gm@setdriver{xetex}}{\Gm@unsetdriver{xetex}}}}% \define@key{Gm}{vtex}[true]{\ifGm@preamble{vtex}{% @@ -809,7 +814,11 @@ \ifx\Gm@driver\@empty \typeout{*geometry* driver: auto-detecting}% \ifpdf - \Gm@setdriver{pdftex}% + \ifx\pdfextension\@undefined + \Gm@setdriver{pdftex}% + \else + \Gm@setdriver{luatex}% + \fi \else \Gm@setdriver{dvips}% \fi @@ -1030,7 +1039,7 @@ \setlength\pdfpagewidth{\Gm@pw}% \setlength\pdfpageheight{\Gm@ph}}% \ifnum\mag=\@m\else - \@tempdima=\mag sp% + \@tempdima=\mag sp \@ifundefined{pdfhorigin}{}{% \divide\pdfhorigin\@tempdima \multiply\pdfhorigin\@m @@ -1042,6 +1051,23 @@ \fi \fi \fi + \ifx\Gm@driver\Gm@luatex + \setlength\pagewidth{\Gm@pw}% + \setlength\pageheight{\Gm@ph}% + \ifnum\mag=\@m\else + \@tempdima=\mag sp + \edef\Gm@horigin{\pdfvariable horigin}% + \edef\Gm@vorigin{\pdfvariable vorigin}% + \divide\Gm@horigin\@tempdima + \multiply\Gm@horigin\@m + \divide\Gm@vorigin\@tempdima + \multiply\Gm@vorigin\@m + \ifx\Gm@truedimen\Gm@true + \setlength\paperwidth{\Gm@pw}% + \setlength\paperheight{\Gm@ph}% + \fi + \fi + \fi \ifx\Gm@driver\Gm@vtex \@ifundefined{mediawidth}{}{% \mediawidth=\paperwidth |