diff options
author | Norbert Preining <preining@logic.at> | 2007-11-20 07:25:42 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2007-11-20 07:25:42 +0000 |
commit | c604ce2ab534f3df0a81c4184b32a2ce523d8edf (patch) | |
tree | a9172a7b66f447544a866c9d0de327d213f4695d /Master/texmf-dist | |
parent | 489720d920005785b27c5f6583835d818473dfce (diff) |
update gmeometric (07-11-20)
git-svn-id: svn://tug.org/texlive/trunk@5519 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.pdf | bin | 245700 -> 83304 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.tex | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/gmeometric/gmeometric.sty | 232 |
3 files changed, 224 insertions, 10 deletions
diff --git a/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.pdf b/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.pdf Binary files differindex f716e553f94..ecaf45567a2 100644 --- a/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.pdf +++ b/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.pdf diff --git a/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.tex b/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.tex index 7852bb48f88..7268ba978eb 100644 --- a/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.tex +++ b/Master/texmf-dist/doc/latex/gmeometric/gmeometricDoc.tex @@ -1,4 +1,4 @@ -\documentclass[noindex]{gmdocc} +\documentclass[noindex, pagella]{gmdocc} \twocoltoc \begin{document} \GetFileInfo{gmeometric.sty} diff --git a/Master/texmf-dist/tex/latex/gmeometric/gmeometric.sty b/Master/texmf-dist/tex/latex/gmeometric/gmeometric.sty index 61ad56414ce..7724b616d3e 100644 --- a/Master/texmf-dist/tex/latex/gmeometric/gmeometric.sty +++ b/Master/texmf-dist/tex/latex/gmeometric/gmeometric.sty @@ -24,12 +24,14 @@ % \CheckSum{61} % \chschange{v0.69}{2007/4/26}{40} % \chschange{v0.70}{2007/4/29}{36} +% \chschange{v0.71}{2007/11/16}{41} +% \chschange{v0.72}{2007/11/17}{239} % %% \FileInfo \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{gmeometric} - [2007/04/29 v0.70 to allow the `geometry' macro in the document (GM)] + [2007/11/17 v0.72 to allow the `geometry' macro in the document (GM)] %% % @@ -59,14 +61,20 @@ %% You may use \pk{gmeometric} just like \pk{geometry} i.e., to specify %% the layout as the package options: they shall be passed to %% \pk{geometry}. -% +%% +%% This package also checks if the engine is \XeTeX\ and sets the +%% proper driver if so. Probably it's redundant since decent \XeTeX\ +%% packages provide their \pk{geometry.cfg} file that does that. +%% % % \begin{gmlonely} % \subdivision{Installation} -% -% Just put the \pk{gmeometric.sty} somewhere in the \file{texmf/\:tex/\:latex} -% branch. Creating a~\file{texmf/\:tex/\:latex/\:gm} directory may be advisable -% if you consider using other packages written by me. +% +% Unpack the \file{gmeometric.tds.zip} archive in a~\file{texmf} +% directory or put the \pk{gmeometric.sty} somewhere in the +% \file{texmf/\:tex/\:latex} branch on your own. Creating +% a~\file{texmf/\:tex/\:latex/\:gm} directory may be advisable if +% you consider using other packages written by me. % % Then you should refresh your \TeX\ distribution's files' database % most probably. @@ -81,7 +89,8 @@ % \pk{gmeometric.sty}\\ % \pk{README}\\ % \pk{gmeometricDoc.tex}\\ -% \pk{gmeometricDoc.pdf} +% \pk{gmeometricDoc.pdf}\\ +% \pk{gmeometric.tds.zip} % \end{verse} % % @@ -106,7 +115,7 @@ % \end{gmlonely} % % -% \division{Usage} The only use of this package is to allow the +% \division{Usage} The main use of this package is to allow the % |\geometry| command also inside the \env{document} (originally it's % |\@onlypreamble|). To make |\geometry| work properly is quite % a~different business. It may be advisable to `commit' the layout @@ -135,7 +144,7 @@ %\end{verbatim} % % In some cases it doesn't work perfectly -% anyway. Well, the license \acro{(LPPL)} warns about it. +% anyway. Well, the \acro{(LPPL)} license warns about it. % % \division{The Code} @@ -153,16 +162,217 @@ \StoreMacro\@onlypreamble \let\@onlypreamble\@gobble +% To make it work properly in \XeTeX: +\@ifXeTeX{% + \@ifundefined{pdfoutput}{\newcount\pdfoutput}{}% + \PassOptionsToPackage{dvipdfm}{geometry}% +}{} + \RequirePackageWithOptions{geometry} % Restore |\@onlypreamble|: \RestoreMacro\@onlypreamble +% Hypothesis: |\ifx...\@undefined| fails in the document because +% something made |\csname Gm@lines\endcsname|. So we change the test +% to decent. And i~think I've found the guilty: |\@ifundefined| in +% |\Gm@showparams|. So I~change it to the more elegant +% |\ifx\@undefined|. +%^^A at first I~rewrote \cs{Gm@process}, let it be, maybe +%^^A one day I'll rewrite entire \pk{geometry} +%^^A \def\Gm@process{% +%^^A \ifGm@pass +%^^A \Gm@dorg +%^^A \else +%^^A \Gm@processdimlist +%^^A \@ifundefined{Gm@hmarginratio}{% +%^^A \if@twoside +%^^A \edef\Gm@hmarginratio{\Gm@Dhratiotwo}% +%^^A \else +%^^A \edef\Gm@hmarginratio{\Gm@Dhratio}% +%^^A \fi +%^^A }{}% +%^^A \@ifundefined{Gm@vmarginratio}{% +%^^A \edef\Gm@vmarginratio{\Gm@Dvratio}% +%^^A }% +%^^A \Gm@checkpaper +%^^A \ifGm@sworient +%^^A \@tempdima=\paperwidth +%^^A \paperwidth=\paperheight +%^^A \paperheight=\@tempdima +%^^A \Gm@setpaper(\strip@pt\paperwidth,\strip@pt\paperheight){pt}% +%^^A \Gm@sworientfalse +%^^A \fi +%^^A \advance\paperwidth by-\Gm@bindingoffset +%^^A \ifGm@includemp +%^^A \Gm@mpfix +%^^A \fi +%^^A \ifGm@hbody +%^^A \@ifundefined{Gm@width}{% +%^^A \@ifundefined{Gm@hscale}{% +%^^A \edef\Gm@width{\Gm@Dhscale\paperwidth}% +%^^A }{% +%^^A \edef\Gm@width{\Gm@hscale\paperwidth}% +%^^A }% +%^^A }% +%^^A \@ifundefined{Gm@textwidth}{}{% +%^^A \setlength\@tempdima{\Gm@textwidth}% +%^^A \ifGm@includemp +%^^A \advance\@tempdima\Gm@wd@mp +%^^A \fi +%^^A \edef\Gm@width{\the\@tempdima}% +%^^A }% +%^^A \fi +%^^A \ifGm@vbody +%^^A \@ifundefined{Gm@height}{% +%^^A \@ifundefined{Gm@vscale}{% +%^^A \edef\Gm@height{\Gm@Dvscale\paperheight}% +%^^A }{% +%^^A \edef\Gm@height{\Gm@vscale\paperheight}% +%^^A }% +%^^A }{}% +%^^A \@ifundefined{Gm@lines}{}{% +%^^A \@tempdima=\baselineskip +%^^A \multiply\@tempdima\Gm@lines +%^^A \advance\@tempdima by\topskip +%^^A \advance\@tempdima by-\baselineskip +%^^A \edef\Gm@textheight{\the\@tempdima}% +%^^A }% +%^^A \@ifundefined{Gm@textheight}{}{% +%^^A \@tempdima=\Gm@textheight +%^^A \ifGm@includehead +%^^A \advance\@tempdima by\headheight +%^^A \advance\@tempdima by\headsep +%^^A \fi +%^^A \ifGm@includefoot +%^^A \addtolength\@tempdima{\footskip}% +%^^A \fi +%^^A \edef\Gm@height{\the\@tempdima}% +%^^A }% +%^^A \fi +%^^A \Gm@detall{h}{width}{lmargin}{rmargin}% +%^^A \Gm@detall{v}{height}{tmargin}{bmargin}% +%^^A \setlength\textwidth{\Gm@width}% +%^^A \setlength\textheight{\Gm@height}% +%^^A \setlength\topmargin{\Gm@tmargin}% +%^^A \setlength\oddsidemargin{\Gm@lmargin}% +%^^A \addtolength\oddsidemargin{-1\Gm@truedimen in}% +%^^A \ifGm@includemp +%^^A \advance\textwidth-\Gm@wd@mp +%^^A \advance\oddsidemargin\Gm@odd@mp +%^^A \fi +%^^A \if@mparswitch +%^^A \setlength\evensidemargin{\Gm@rmargin}% +%^^A \addtolength\evensidemargin{-1\Gm@truedimen in}% +%^^A \ifGm@includemp +%^^A \advance\evensidemargin\Gm@even@mp +%^^A \fi +%^^A \ifGm@compatii +%^^A \@ifundefined{Gm@twosideshift}{% +%^^A \def\Gm@twosideshift{20\Gm@truedimen pt}% +%^^A }% +%^^A \addtolength\oddsidemargin{\Gm@twosideshift}% +%^^A \addtolength\evensidemargin{-\Gm@twosideshift}% +%^^A \fi +%^^A \else +%^^A \evensidemargin\oddsidemargin +%^^A \fi +%^^A \advance\oddsidemargin\Gm@bindingoffset +%^^A \addtolength\topmargin{-1\Gm@truedimen in}% +%^^A \ifGm@includehead +%^^A \addtolength\textheight{-\headheight}% +%^^A \addtolength\textheight{-\headsep}% +%^^A \else +%^^A \addtolength\topmargin{-\headheight}% +%^^A \addtolength\topmargin{-\headsep}% +%^^A \fi +%^^A \ifGm@includefoot +%^^A \addtolength\textheight{-\footskip}% +%^^A \fi +%^^A \ifGm@heightrounded +%^^A \setlength\@tempdima{\textheight}% +%^^A \addtolength\@tempdima{-\topskip}% +%^^A \@tempcnta\@tempdima +%^^A \@tempcntb\baselineskip +%^^A \divide\@tempcnta\@tempcntb +%^^A \setlength\@tempdimb{\baselineskip}% +%^^A \multiply\@tempdimb\@tempcnta +%^^A \advance\@tempdima-\@tempdimb +%^^A \multiply\@tempdima\tw@ +%^^A \ifdim\@tempdima>\baselineskip +%^^A \addtolength\@tempdimb{\baselineskip}% +%^^A \fi +%^^A \addtolength\@tempdimb{\topskip}% +%^^A \textheight\@tempdimb +%^^A \fi +%^^A \addtolength\paperwidth{\Gm@bindingoffset}% +%^^A \fi}% + +\def\Gm@showparams{% \changes{v0.72}{2007/11/17}{a~bug fix: + %% \cs{@ifundefined\{Gm@lines\}} raised an error when \cs{geometry} + %% used inside the \env{document}, I~change it to + %% \cs{ifx}\cs{@undefined}} + -------------------- Geometry parameters^^J% + \ifGm@pass + 'pass' is specified!! (disables the geometry layouter)^^J% + \else + paper: \ifx\Gm@paper\@undefined class default\else\Gm@paper\fi^^J% + \Gm@checkbool{landscape}% + twocolumn: \if@twocolumn\Gm@true\else--\fi^^J% + twoside: \if@twoside\Gm@true\else--\fi^^J% + asymmetric: \if@mparswitch --\else\if@twoside\Gm@true\else --\fi\fi^^J% + h-parts: \Gm@lmargin, \Gm@width, \Gm@rmargin% + \ifnum\Gm@cnth=\z@\space(default)\fi^^J% + v-parts: \Gm@tmargin, \Gm@height, \Gm@bmargin% + \ifnum\Gm@cntv=\z@\space(default)\fi^^J% + hmarginratio: \ifnum\Gm@cnth<5 \ifnum\Gm@cnth=3--\else% + \Gm@hmarginratio\fi\else--\fi^^J% + vmarginratio: \ifnum\Gm@cntv<5 \ifnum\Gm@cntv=3--\else% + \Gm@vmarginratio\fi\else--\fi^^J% + lines: \ifx\Gm@lines\@undefined--\else\Gm@lines\fi^^J% here + % I~(natror) fix the bug: it was \inverb|\@ifundefined| that of + % course was assigning \inverb|\relax| to \inverb|\Gm@lines| and + % that resulted in an error when \inverb|\geometry| was used inside + % document. + \Gm@checkbool{heightrounded}% + bindingoffset: \the\Gm@bindingoffset^^J% + truedimen: \ifx\Gm@truedimen\@empty --\else\Gm@true\fi^^J% + \Gm@checkbool{includehead}% + \Gm@checkbool{includefoot}% + \Gm@checkbool{includemp}% + driver: \Gm@driver^^J% + \fi + -------------------- Page layout dimensions and switches^^J% + \string\paperwidth\space\space\the\paperwidth^^J% + \string\paperheight\space\the\paperheight^^J% + \string\textwidth\space\space\the\textwidth^^J% + \string\textheight\space\the\textheight^^J% + \string\oddsidemargin\space\space\the\oddsidemargin^^J% + \string\evensidemargin\space\the\evensidemargin^^J% + \string\topmargin\space\space\the\topmargin^^J% + \string\headheight\space\the\headheight^^J% + \string\headsep\@spaces\the\headsep^^J% + \string\footskip\space\space\space\the\footskip^^J% + \string\marginparwidth\space\the\marginparwidth^^J% + \string\marginparsep\space\space\space\the\marginparsep^^J% + \string\columnsep\space\space\the\columnsep^^J% + \string\skip\string\footins\space\space\the\skip\footins^^J% + \string\hoffset\space\the\hoffset^^J% + \string\voffset\space\the\voffset^^J% + \string\mag\space\the\mag^^J% + \if@twocolumn\string\@twocolumntrue\space\fi% + \if@twoside\string\@twosidetrue\space\fi% + \if@mparswitch\string\@mparswitchtrue\space\fi% + \if@reversemargin\string\@reversemargintrue\space\fi^^J% + (1in=72.27pt, 1cm=28.45pt)^^J% + -----------------------} + % Add restore to BeginDocument: \@xa\AtBeginDocument\@xa{\@xa\RestoreMacros\gme@tobestored} \endinput +% \ChangesGeneral % % \changes{v0.70}{2007/04/29}{Back to the v0.68 settings because % \cs{not@onlypreamble} was far too little. Well, in this version the @@ -170,6 +380,10 @@ % commands depend on the particular situation so defining only two % options doesn't seem advisable} % +% \changes{v0.71}{2007/11/17}{a~\acro{TDS}-compliant \file{zip} +% archive made} +% +% % \NoEOF % (For my GNU Emacs:) |