summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/gmutils/gmtypos.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/gmutils/gmtypos.sty')
-rw-r--r--Master/texmf-dist/tex/latex/gmutils/gmtypos.sty2027
1 files changed, 2027 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/gmutils/gmtypos.sty b/Master/texmf-dist/tex/latex/gmutils/gmtypos.sty
new file mode 100644
index 00000000000..3992e1af62b
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/gmutils/gmtypos.sty
@@ -0,0 +1,2027 @@
+%%
+%% \iffalse ^^A we skip the debug setting
+\IfFileExists{\string~/bin/gen_and_xela}{\errorcontextlines=1000 }{}
+%% \fi
+%% ^^A $Id: TheUltimateMaster.gmd,v 0.250 2010/10/24 14:42:35 natror Exp natror $
+%% This is file “gmtypos.sty” generated with the DocStrip utility.
+%%
+%%
+%% The original source files were:
+%%
+%% gmutils/gmutils.gmd (with options: `typos')
+%%
+%%
+%% Copyright ©
+%% by Grzegorz ‘Natror’ Murzynowski
+%% natror (at) o2 (dot) pl
+%%
+%% This program is subject to the LaTeX Project Public License.
+%% See http://www.ctan.org/tex-archive/help/Catalogue/licenses.lppl.html
+%% for the details of that license.
+%%
+%% LPPL status: "author-maintained".
+%%
+%%
+%%
+%% For the documentation please refer to the file(s)
+%% gmutils.{gmd,pdf}.
+%%
+%%
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{gmtypos}
+ [2010/10/24 v0.993 a collection of macros, mosltly typographical (GM)]
+
+
+%%
+%%
+%% ^^A\typeout{\unexpanded{#4}}%%
+
+\RequirePackage{gmcommand, gmnotonlypream}
+
+\unless\ifcsname ifgmu@quiet\endcsname
+ \@xa\newif\csname ifgmu@quiet\endcsname
+\fi
+
+\DeclareOption{quiet}{\gmu@quiettrue}
+
+\ProcessOptions
+
+
+
+\AtBeginDocument{%
+ \@ifpackageloaded{fontspec}{%
+ \pdef\udigits{%
+ \addfontfeature{Numbers=Uppercase}}%
+ }{%
+ \emptify\udigits}}
+
+
+\def\Xedekfracc{\gmu@ifstar\gmu@xedekfraccstar\gmu@xedekfraccplain}
+ % (plain) The starless version turns the font feature |frac| on.
+ %
+ % (\*) But nor my modification of Minion Pro neither \TeX\ Gyre
+ % Pagella doesn't feature the
+ % |frac| font feature properly so, with the starred version of the
+ % declaration we use the characters from the font where available
+ % (see the |\@namedef|s below) and the |numr| and |dnom| features
+ % with the fractional slash otherwise (via |\gmu@dekfracc|).
+ %
+ % (\*\*) But Latin Modern Sans Serif Quotation doesn't support the
+ % numerator and denominator positions so we provide the double
+ % star version for it, which takes the char from font if it exist
+ % and typesets with lowers and kerns otherwise.
+
+\def\gmu@xedekfraccstar{%
+ \def\gmu@xefraccdef##1##2{%
+ \iffontchar\font ##2
+ \@namedef{gmu@xefracc##1}{\char##2 }%
+ \else
+ \n@melet{gmu@xefracc##1}{relax}%
+ \fi}%
+ %
+ \def\gmu@dekfracc##1/##2{%
+ {\addfontfeature{VerticalPosition=Numerator}##1}\gmu@numeratorkern
+ \char"2044 \gmu@denominatorkern
+ {\addfontfeature{VerticalPosition=Denominator}##2}}%
+ %
+ % We define the fractional macros. Since Adobe Minion Pro doesn't
+ % contain $\frac n5$ nor $\frac n6$, we don't provide them here.
+ \gmu@xefraccdef{1/4}{"BC}%
+ \gmu@xefraccdef{1/2}{"BD}%
+ \gmu@xefraccdef{3/4}{"BE}%
+ \gmu@xefraccdef{1/3}{"2153}%
+ \gmu@xefraccdef{2/3}{"2154}%
+ \gmu@xefraccdef{1/5}{"2155}%
+ \gmu@xefraccdef{2/5}{"2156}%
+ \gmu@xefraccdef{3/5}{"2157}%
+ \gmu@xefraccdef{4/5}{"2158}%
+ \gmu@xefraccdef{1/6}{"2159}%
+ \gmu@xefraccdef{5/6}{"215A}%
+ \gmu@xefraccdef{1/8}{"215B}%
+ \gmu@xefraccdef{3/8}{"215C}%
+ \gmu@xefraccdef{5/8}{"215D}%
+ \gmu@xefraccdef{7/8}{"215E}%
+ \pdef\dekfracc@args##1/##2{%
+ \gmu@ifundefined{gmu@xefracc\detokenize{##1/##2}}{%
+ \gmu@dekfracc{##1}/{##2}}{%
+ \csname gmu@xefracc\detokenize{##1/##2}\endcsname}%
+ \if@gmu@mmhbox\egroup\fi
+ }% of |\dekfracc@args|.
+ \gmu@ifstar{\let\gmu@dekfracc\gmu@dekfraccsimple}{}%
+ }
+
+\def\gmu@xedekfraccplain{% `else' of the main |\gmu@ifstar|
+ \pdef\dekfracc@args##1/##2{%
+ \ifmmode\hbox\fi{%
+ \addfontfeature{Fractions=On}%
+ ##1/##2}%
+ \if@gmu@mmhbox\egroup\fi
+ }% of |\dekfracc@args|
+ }
+
+\newif\if@gmu@mmhbox% we'll use this switch for |\dekfracc| and also
+
+\pdef\dekfracc{% \changes{v0.94}{2008/09/14}{made to work also in math
+ % mode, even with math-active digits}
+ \ifmmode\hbox\bgroup\@gmu@mmhboxtrue\fi
+ \dekfracc@args}
+
+\def\gmu@numeratorkern{\kern-.055em\relax}
+\def\gmu@denominatorkern{\kern-.05em\relax}
+
+
+
+\pdef\textsuperscript@@#1{%
+ \@textsuperscript{\selectfont#1}}%
+\def\@textsuperscript#1{%
+ {\m@th\ensuremath{^{\mbox{\fontsize\sf@size\z@#1}}}}}
+
+\let\textsuperscript@@\textsuperscript
+
+\def\GMtextsuperscript{%
+ \@ifXeTeX{%
+ \DeclareCommand\textsuperscript{sm}{%
+ \IfValueTF{##1}{\textsuperscript@@{##2}}%
+ {%
+ \begingroup
+ \addfontfeature{VerticalPosition=Numerator}##2%
+ \endgroup}}%
+ }{\truetextsuperscript}}
+
+\def\truetextsuperscript{%
+ \let\textsuperscript\textsuperscript@@
+}
+
+
+
+\def\gmu@getfontstring{%
+ \xdef\gmu@fontstring{%
+ \gmu@fontstring@}}
+
+\def\gmu@fontstring@{%
+ \@xa\@xa\@xa\gmu@fontstring@@\@xa\meaning\the\font\@nil}
+
+\def\gmu@fontstring@@#1"#2"#3\@nil{"#2"}
+
+\def\gmu@getfontscale#1Scale#2=#3,{%
+ \ifx\gmu@getfontscale#3\else
+ \def\gmu@tempa{MatchLowercase}%
+ \def\gmu@tempb{#3}%
+ \ifx\gmu@tempa\gmu@tempb
+ \gmu@calc@scale{5}%
+ \@xa\@firstoftwo
+ \else
+ \def\gmu@tempa{MatchUppercase}%
+ \ifx\gmu@tempa\gmu@tempb
+ \gmu@calc@scale{8}%
+ \afterfifi\@firstoftwo
+ \else\afterfifi\@secondoftwo
+ \fi
+ \fi
+ {\xdef\gmu@fontscalebr{[\gmu@fontscale] }}%
+ {\xdef\gmu@fontscalebr{[#3] }}%
+ \afterfi\gmu@getfontscale
+ \fi
+}
+
+\def\gmu@getfontdata#1{%
+ \global\emptify\gmu@fontscalebr
+ \begingroup
+ #1%
+ \@xa\@xa\@xa\gmu@getfontscale
+ \csname zf@family@options\f@family\endcsname
+ ,Scale=\gmu@getfontscale,%
+ \gmu@getfontstring
+ \xdef\gmu@theskewchar{\the\skewchar\font}%
+ \endgroup}
+
+\def\gmu@stripchar#1"{"}
+
+\DeclareCommand\gmath@getfamnum{C{\gmath@fam}}{%
+ \edef\gmath@famnum{\@xa\gmu@stripchar\meaning#1}%
+}
+
+
+\DeclareCommand\gmathFams{o % the name of math version
+ C{\NoValue} % ‘rescue’ font. Will be accessible via
+ % \inverb|\symgmathRoman⁄<version>| (math family) and
+ % \inverb|\gmath@fontt⁄<version>| (font).
+}{%
+ \IfValueT{#1}{%
+ \DeclareMathVersion{#1}% this sets the defaults so no need to
+ % define them explicitly
+ }% of if |#1| given
+ %
+ \gmu@getfontdata{\rmfamily\itshape}%
+ %
+ \edef\gmu@tempa{%
+ \IfValueTF{#1}{\@nx\SetSymbolFont{letters}{#1}}%
+ {\@nx\DeclareSymbolFont{letters}}%
+ {\encodingdefault}{gmathit\PutIfValue{#1}}{m}{it}%
+ \IfValueT{#1}{%
+ \@nx\DeclareSymbolFont{letters#1}%
+ {\encodingdefault}{gmathit\PutIfValue{#1}}{m}{it}%
+ }%
+ \@nx\DeclareFontFamily{\encodingdefault}{gmathit\PutIfValue{#1}}{%
+ \skewchar\font\gmu@theskewchar\space}%
+ \@nx\DeclareFontShape{\encodingdefault}{gmathit\PutIfValue{#1}}{m}{it}{%
+ <-> \gmu@fontscalebr \gmu@fontstring}{}%
+ \IfValueT{#1}{%
+ \@nx\SetMathAlphabet\@nx\mathit{#1}{\encodingdefault}{gmathit#1}{m}{it}}%
+ }\gmu@tempa
+ %
+ \IfValueT{#2}{%
+ \gmu@getfontdata{#2\gmu@ifstored{\upshape}{\storedcsname{upshape}}{\upshape}}%
+ \edef\gmu@tempa{%
+ \@nx\DeclareSymbolFont{gmathRoman\PutIfValue{#1}}%
+ {\encodingdefault}{gmathRm\PutIfValue{#1}}{m}{n}%
+ \@nx\DeclareFontFamily{\encodingdefault}{gmathRm\PutIfValue{#1}}{%
+ \skewchar\font\gmu@theskewchar\space}%
+ \@nx\DeclareFontShape{\encodingdefault}{gmathRm\PutIfValue{#1}}{m}{n}{%
+ <-> \gmu@fontscalebr \gmu@fontstring}{}%
+ }\gmu@tempa
+ \@xa\font\csname gmath@fontt\PutIfValue{#1}\endcsname
+ =\gmu@fontstring\relax
+ % \stanza
+ \gmu@getfontdata{#2\gmu@ifstored{\itshape}{\storedcsname{itshape}}{\itshape}}%
+ \edef\gmu@tempa{%
+ \@nx\DeclareSymbolFont{gmathItalic\PutIfValue{#1}}%
+ {\encodingdefault}{gmathIt\PutIfValue{#1}}{m}{n}%
+ \@nx\DeclareFontFamily{\encodingdefault}{gmathIt\PutIfValue{#1}}{%
+ \skewchar\font\gmu@theskewchar\space}%
+ \@nx\DeclareFontShape{\encodingdefault}{gmathIt\PutIfValue{#1}}{m}{n}{%
+ <-> \gmu@fontscalebr \gmu@fontstring}{}%
+ }\gmu@tempa
+ }% of if |#2| given
+ % \stanza
+ \gmu@getfontdata{\rmfamily\upshape}%
+ \edef\gmu@tempa{%
+ \IfValueTF{#1}{\@nx\SetSymbolFont{gmathroman}{#1}}%
+ {\@nx\DeclareSymbolFont{gmathroman}}%
+ {\encodingdefault}{gmathrm\PutIfValue{#1}}{m}{n}%
+ \@nx\DeclareFontFamily{\encodingdefault}{gmathrm\PutIfValue{#1}}{%
+ \skewchar\font\gmu@theskewchar\space}%
+ \@nx\DeclareFontShape{\encodingdefault}{gmathrm\PutIfValue{#1}}{m}{n}{%
+ <-> \gmu@fontscalebr \gmu@fontstring}{}%
+ \IfValueT{#1}{%
+ \@nx\SetMathAlphabet\@nx\mathrm{#1}{\encodingdefault}{gmathrm#1}{m}{n}}%
+ }\gmu@tempa
+ \@xa\font\csname gmath@font\PutIfValue{#1}\endcsname
+ =\gmu@fontstring\relax
+ \gmathfamshook
+}
+
+\emptify\gmathfamshook
+
+\DeclareCommand\gmathbase{oC{\NoValue}}{%
+ \gmathFams[#1](#2)%
+ \DeclareCommand\gmath@do{%
+ m % (1) the character or \CS\ to be declared,
+ o % (2) the Unicode to be assigned,
+ m % (3) math type (\CS like \cs{mathord} etc.)
+ C{\gmath@fam} % font family
+ }{%\
+ %
+ \gmath@getfamnum(##4)%
+ \IfValueTF{##2}{%
+ \edef\gmu@tempa{%
+ = \mathchar@type##3\space
+ \gmath@famnum\space
+ "##2\relax}%
+ \if\relax\@nx##1%
+ \gmu@ifstored{##1}{}{\Store@Macro##1}%
+ \edef\gmu@tempa{%
+ \XeTeXmathchardef \@nx##1\gmu@tempa}%
+ \else
+ \edef\gmu@tempa{%
+ \XeTeXmathcode `##1 \gmu@tempa}
+ \fi%
+ }%
+ {% no value of |##2|
+ \edef\gmu@tempa{%
+ \XeTeXmathcode `##1 =
+ \mathchar@type##3\space
+ \gmath@famnum\space
+ `##1\relax}%
+ }%
+ \gmu@tempa
+ }% of \incs{gmath@do}
+ %
+ \DeclareCommand\gmath@doif{%
+ m % (1) the Unicode hex of char enquired,
+ m % (2) the char or \CS\ to be declared,
+ m % (3) math type \CS (\cs{mathord} etc.),
+ o % (4) second-choice Unicode (taken if first-choice is absent),
+ o % (5) third-choice Unicode (as above if second-choice is absent from font).
+ B{\gmath@fam} % (6) never used in this package. Why?
+ C{\NoValue}
+ }{%
+ \gmu@storeifnotyet{##2}%
+ \@xa\let\@xa\gmath@ft\csname
+ gmath@font%
+ \ifx\gmath@fam##6\else t\fi
+ \gmath@version
+ \endcsname
+ \iffontchar\gmath@ft"##1 \gmath@do##2[##1]##3(##6)%
+ \else
+ \IfValueTF{##4}{%
+ \iffontchar\gmath@ft"##4 \gmath@do##2[##4]##3(##6)%
+ \else
+ \IfValueTF{##5}{%
+ \iffontchar\gmath@ft"##5 \gmath@do##2[##5]##3(##6)%
+ \else
+ \gmath@restore{##1}{##2}{##3}{##4}{##5}{##7}%
+ \fi}%
+ {\gmath@restore{##1}{##2}{##3}{##4}{##5}{##7}}%
+ \fi}%
+ {\gmath@restore{##1}{##2}{##3}{##4}{##5}{##7}}%
+ \fi
+ }% of |\gmath@doif|
+ % In the command above we try to define math char or a~\CS in the
+ % family given as |##6|. If there're no respective chars, we try
+ % the same with the family given (as a~word) in |##7|.
+ \def\gmath@restore##1##2##3##4##5##6{%
+ \IfValueT{##6}%
+ {\ifcsname ##6\endcsname
+ \edef\gmu@tempa{%
+ \unexpanded{\gmath@doif{##1}{##2}{##3}[##4][##5]}%
+ {\@xanxcs{##6}}\relax
+ }\gmu@tempa
+ \@xa\@gobbletwo % if family |##6| is defined, we gobble the
+ % other branch
+ \fi
+ }%
+ \firstofone
+ {\if\relax\@nx##2%
+ \Restore@Macro##2%
+ \fi
+ }%
+ }%
+ %
+\iffalse % doesn't work in a~non-math font.
+ \DeclareCommand\gmath@delc{mo}{%\
+ % \begin{enumargs*}
+ % \mand the char or \CS\ to be declared,
+ % \opt the Unicode (if not the same as the char).
+ % \end{enumargs*}
+ %
+ \gmath@getfamnum
+ \IfValueTF{##2}{%
+ \edef\gmu@tempa{%
+ = \gmath@famnum\space "##2\relax}%
+ \edef\gmu@tempa{%
+ \XeTeXdelcode `##1 \gmu@tempa}
+ }%
+ {%
+ \edef\gmu@tempa{%
+ \XeTeXdelcode `##1 =
+ \gmath@famnum\space
+ `##1\relax}%
+ }%
+ \gmu@tempa
+ }% of \incs{gmath@delc}
+ %
+ \def\gmath@delcif##1##2{%\
+ % \begin{enumargs*}
+ % \mand the Unicode enquired,
+ % \item the char to be delcode-declared
+ % \end{enumargs*}
+ %
+ \iffontchar\gmath@font"##1 \gmath@delc##2[##1]\fi}
+\fi% of iffalse
+ %
+ \def\gmath@delimif##1##2##3{%\
+ % \begin{enumargs*}
+ % \item the Unicode enquired,
+ % \item the \CS\ defined as \cs{XeTeXdelimiter},
+ % \item the math type \CS\ (probably \incs{mathopen} or
+ % \incs{mathclose}).
+ % \end{enumargs*}
+ \iffontchar\gmath@font"##1
+ \gmath@getfamnum
+ \protected\edef##2{\@nx\ensuremath{%
+ \XeTeXdelimiter \mathchar@type##3\space
+ \gmath@famnum\space "##1\relax}}%
+ \fi}% of \cs{gmath@delimif}.
+ %
+ \pdef\rmopname##1##2##3{%
+ \mathop {##1\kern \z@ \mathrm{##3}}\csname n##2limits@\endcsname
+ }%
+ %
+ \DeclareCommand\gmu@dogmathbase{oC{\NoValue}}{%
+ \Restore@Macro\mathchar@type%
+ %
+ \IfValueT{##1}{\mathversion{##1}}%
+ %
+ \edef\gmath@version{\PutIfValue{##1}}%
+ %
+ \@xa\let\@xa\gmath@fam\csname symgmathroman%
+ \endcsname
+ \edef\gmath@famm{symgmathRoman\gmath@version}% as you see, this is
+ % not a~font family (number) but a~macro containing the name: of
+ % the secondary (‘rescue’) family.
+ %
+ \typeout{@@@ gmutils.sty: taking some math chars from the font^^J \gmu@fontstring@}%
+ \gmath@do+\mathbin
+ \gmath@doif{2212}-\mathbin[2013](\gmath@famm)% minus sign if present or else en dash
+ \gmath@do=\mathrel
+ \gmath@do0\mathord
+ \gmath@do1\mathord
+ \gmath@do2\mathord
+ \gmath@do3\mathord
+ \gmath@do4\mathord
+ \gmath@do5\mathord
+ \gmath@do6\mathord
+ \gmath@do7\mathord
+ \gmath@do8\mathord
+ \gmath@do9\mathord
+ %%
+ \gmath@doif{2264}\le\mathrel(\gmath@famm)%
+ \let\leq\le
+ \let\leeng\le
+ \gmath@doif{2265}\ge\mathrel(\gmath@famm)%
+ \let\geq\ge
+ \let\geeng\ge
+ \gmath@doif{2A7D}\xleq\mathrel(\gmath@famm)%
+ \gmath@doif{2A7E}\xgeq\mathrel(\gmath@famm)%
+ \@ifpackageloaded{polski}{%
+ \ifdefined\xleq
+ \gmu@storeifnotyet\leq
+ \let\leq=\xleq
+ \let\le=\leq
+ \fi
+ \ifdefined\xgeq
+ \gmu@storeifnotyet\geq
+ \let\geq=\xgeq
+ \let\ge=\geq
+ \fi}{}%
+ %
+ \gmath@do.\mathpunct
+ \gmath@do,\mathpunct
+ \gmath@do;\mathpunct
+ \gmath@do…\mathpunct
+ \gmath@do(\mathopen
+ \gmath@do)\mathclose
+ \gmath@do[\mathopen
+ \gmath@do]\mathclose
+ %
+ \gmath@doif{00D7}×\mathbin (\gmath@famm)%
+ \gmath@do:\mathrel
+ \gmath@doif{00B7}·\mathbin(\gmath@famm)%
+ \gmath@doif{22C6}*\mathbin(\gmath@famm)% % low star
+ \gmath@doif{2300}\varnothing\mathord(\gmath@famm)%
+ \gmath@doif{221E}\infty\mathord(\gmath@famm)%
+ \gmath@doif{2248}\approx\mathrel(\gmath@famm)%
+ \gmath@doif{2260}\neq\mathrel(\gmath@famm)%
+ \let\ne\neq
+ \gmath@doif{00AC}\neg\mathbin(\gmath@famm)%
+ \gmath@doif{00AC}\nego\mathord(\gmath@famm)%
+ \gmath@do/\mathop
+ \gmath@do<\mathrel
+ \gmath@do>\mathrel
+ \gmath@doif{2329}\langle\mathopen(\gmath@famm)%
+ \gmath@doif{232A}\rangle\mathclose(\gmath@famm)%
+ \gmath@doif{2202}\partial\mathord(\gmath@famm)%
+ \gmath@doif{00B1}\pm\mathbin(\gmath@famm)%
+ \gmath@doif{007E}\sim\mathrel(\gmath@famm)%
+ \gmath@doif{2190}\leftarrow\mathrel(\gmath@famm)%
+ \gmath@doif{2192}\rightarrow\mathrel(\gmath@famm)%
+ \gmath@doif{2194}\leftrightarrow\mathrel(\gmath@famm)%% if not present,
+ % \incs{gmathfurther} will take care
+ % of it if left and right arrows are present.
+ \gmath@doif{2191}\uparrow\mathrel(\gmath@famm)%% it should be a~delimiter
+ % (declared with \incs{gmath@delimif}) % but in a~non-math
+ % font the delimiters don't work (2008/11/19) and I~don't think
+ % I'll ever need up- and down- arrows as delimiters.
+ \gmath@doif{2193}\downarrow\mathrel(\gmath@famm)%
+ %
+ \gmath@doif{2208}\in\mathrel[03F5][0454](\gmath@famm)%%
+ % As a~fan of modal logics I~allow redefinition of \incs{lozenge}
+ % and \incs{square} iff both are in the font. I~don't accept
+ % the ‘ballot box’ U+2610.
+ \if\iffontchar\gmath@font"25CA 0\else 1\fi
+ \iffontchar\gmath@font"25FB 0\else\iffontchar\gmath@font"25A1 0\else 2\fi\fi
+ \gmath@do\lozenge[25CA]\mathord
+ \gmath@doif{25FB}\square\mathord[25A1](\gmath@famm)%% ‘medium white square (modal
+ % operator)’ of just ‘white square’.
+ \fi
+ \gmath@doif{EB08}\bigcircle\mathbin(\gmath@famm)%
+ \gmath@doif{2227}\wedge\mathbin(\gmath@famm)%
+ \gmath@doif{2228}\vee\mathbin(\gmath@famm)%
+ %
+ \gmath@doif{0393}\Gamma\mathalpha(\gmath@famm)%
+ \gmath@doif{0394}\Delta\mathalpha(\gmath@famm)%
+ \gmath@doif{0398}\Theta\mathalpha(\gmath@famm)%
+ \gmath@doif{039B}\Lambda\mathalpha(\gmath@famm)%
+ \gmath@doif{039E}\Xi\mathalpha(\gmath@famm)%
+ \gmath@doif{03A3}\Sigma\mathalpha(\gmath@famm)%
+ \gmath@doif{03A5}\Upsilon\mathalpha(\gmath@famm)%
+ \gmath@doif{03А6}\Phi\mathalpha(\gmath@famm)%
+ \gmath@doif{03A8}\Psi\mathalpha(\gmath@famm)%
+ \gmath@doif{03A9}\Omega\mathalpha(\gmath@famm)%
+ %
+ \@xa\let\@xa\gmath@fam\csname symletters\gmath@version%
+ \endcsname
+ \edef\gmath@famm{symgmathItalic\gmath@version}%
+ %
+ \gmath@doif{03B1}\alpha\mathalpha(\gmath@famm)%
+ \gmath@doif{03B2}\beta\mathalpha(\gmath@famm)%
+ \gmath@doif{03B3}\gamma\mathalpha(\gmath@famm)%
+ \gmath@doif{03B4}\delta\mathalpha(\gmath@famm)%
+ \gmath@doif{03F5}\epsilon\mathalpha(\gmath@famm)%
+ \gmath@doif{03B5}\varepsilon\mathalpha(\gmath@famm)%
+ \gmath@doif{03B6}\zeta\mathalpha(\gmath@famm)%
+ \gmath@doif{03B7}\eta\mathalpha(\gmath@famm)%
+ \gmath@doif{03B8}\theta\mathalpha(\gmath@famm)%
+ \gmath@doif{03D1}\vartheta\mathalpha(\gmath@famm)%
+ \gmath@doif{03B9}\iota\mathalpha(\gmath@famm)%
+ \gmath@doif{03BA}\kappa\mathalpha(\gmath@famm)%
+ \gmath@doif{03BB}\lambda\mathalpha(\gmath@famm)%
+ \gmath@doif{03BC}\mu\mathalpha(\gmath@famm)%
+ \gmath@doif{03BD}\nu\mathalpha(\gmath@famm)%
+ \gmath@doif{03BE}\xi\mathalpha(\gmath@famm)%
+ \gmath@doif{03C0}\pi\mathalpha(\gmath@famm)%
+ \gmath@doif{03A0}\Pi\mathalpha(\gmath@famm)%
+ \gmath@doif{03C1}\rho\mathalpha(\gmath@famm)%
+ \gmath@doif{03C3}\sigma\mathalpha(\gmath@famm)%
+ \gmath@doif{03DA}\varsigma\mathalpha(\gmath@famm)%% 03C2?
+ \gmath@doif{03C4}\tau\mathalpha(\gmath@famm)%
+ \gmath@doif{03C5}\upsilon\mathalpha(\gmath@famm)%
+ \gmath@doif{03D5}\phi\mathalpha(\gmath@famm)%
+ \gmath@doif{03C7}\chi\mathalpha(\gmath@famm)%
+ \gmath@doif{03C8}\psi\mathalpha(\gmath@famm)%
+ \gmath@doif{03C9}\omega\mathalpha(\gmath@famm)%
+ %
+ \if 1 1%
+ \iffontchar\gmath@font"221A
+ \fontdimen61\gmath@font=1pt
+ \edef\sqrtsign{%
+ \XeTeXradical \@xa\gmu@stripchar\meaning\symgmathroman\space "221A\relax}%
+ \fi
+ \fi% of if 1 1.
+ \def\max{\rmopname \relax m{max}}%
+ \def\min{\rmopname \relax m{min}}%
+ \def\lim{\rmopname \relax m{lim}}%
+ \def\sin{\rmopname \relax o{sin}}%
+ \def\cos{\rmopname \relax o{cos}}%
+ \def\tg{\rmopname \relax o{tg}}%
+ \def\ctg{\rmopname \relax o{ctg}}%
+ \def\tan{\rmopname \relax o{tan}}%
+ \def\ctan{\rmopname \relax o{ctan}}%
+ }% of |\gmu@dogmathbase|
+ \AtBeginDocument{\gmu@dogmathbase[#1](#2)%
+ \let\gmathbase\gmu@dogmathbase
+ }% of atbd
+ \not@onlypreamble\gmathbase
+}% of \cs{gmathbase}
+
+
+\@onlypreamble\gmathbase
+
+\pdef\gmathfurther{% \HideDef
+ % \changes{v0.94}{2008/10/4}{removed definition of
+ % \cs{}\<letter>s and \cs{}\<digit>s}
+ % \changes{v0.96}{2008/11/7}{Greek letters completed. Wrapped with
+ % \cs{addtotoks} to allow using in any order with \cs{garamath}
+ % and others}
+ %
+ \def\do##1##2##3{\gmu@storeifnotyet##1%
+ \def##1{%
+ \mathop{\mathchoice{\hbox{%
+ \rm
+ \edef\gma@tempa{\the\fontdimen8\font}%
+ \larger[3]%
+ \lower\dimexpr(\fontdimen8\font-\gma@tempa)/2 %
+ \hbox{##2}}}{\hbox{%
+ \rm
+ \edef\gma@tempa{\the\fontdimen8\font}%
+ \larger[2]%
+ \lower\dimexpr(\fontdimen8\font-\gma@tempa)/2 %
+ \hbox{##2}}}%
+ {\mathrm{##2}}{\mathrm{##2}}}##3}}%
+ \iffontchar\gmath@font"2211 \do\sum{\char"2211}{}\fi%
+ \do\forall{\gma@quantifierhook \rotatebox[origin=c]{180}{A}%
+ \gmu@forallkerning
+ }{\nolimits}%
+ \def\gmu@forallkerning{\setbox0=\hbox{A}\setbox2=\hbox{\scriptsize x}%
+ \kern\dimexpr\ht2/3*2 -\wd0/2\relax}% to be able to redefine it
+ % when the big quantifier is Bauhaus-like.
+ \do\exists{\rotatebox[origin=c]{180}{\gma@quantifierhook E}}\nolimits%
+ %
+ \def\do##1##2##3{\gmu@storeifnotyet##1%
+ \def##1{##3{%
+ \mathchoice{\hbox{\rm##2}}{\hbox{\rm##2}}%
+ {\hbox{\rm\scriptsize##2}}{\hbox{\rm\tiny##2}}}}}%
+ %
+ \unless\iffontchar\gmath@font"2227
+ \do\vee{\rotatebox[origin=c]{90}{<}}\mathbin%
+ \fi
+ \unless\iffontchar\gmath@font"2228
+ \do\wedge{\rotatebox[origin=c]{-90}{<}}\mathbin
+ \fi
+ %
+ \unless\iffontchar\gmath@font"2194
+ \if\iffontchar\gmath@font"2190 0\else1\fi
+ \iffontchar\gmath@font"2192 0\else2\fi
+ \do\leftrightarrow{\char"2190\kern-0,1em \char"2192}\mathrel
+ \fi\fi
+ %
+ \def\do##1##2##3{\gmu@storeifnotyet##1%
+ \def##1####1{##2{\hbox{%
+ \rm
+ \setbox0=\hbox{####1}%
+ \edef\gma@tempa{\the\ht0}%
+ \edef\gma@tempb{\the\dp0}%
+ ##3%
+ \setbox0=\hbox{####1}%
+ \lower\dimexpr(\ht0 + \dp0)/2-\dp0 -((\gma@tempa+\gma@tempb)/2-\gma@tempb) %
+ \box0}}}}%
+ \do\bigl\mathopen\larger
+ \do\bigr\mathclose\larger
+ \do\Bigl\mathopen\largerr
+ \do\Bigr\mathclose\largerr
+ \do\biggl\mathopen{\larger[3]}%
+ \do\biggr\mathclose{\larger[3]}%
+ \do\Biggl\mathopen{\larger[4]}%
+ \do\Biggr\mathclose{\larger[4]}%
+ %
+ %
+ \addtotoks\everymath{% \changes{v0.96}{2008/11/20}{the
+ % \cs{everymath}'s left brace moved here:
+ % earlier all the stuff was put into \cs{everymath}}
+ \def\do##1##2{\gmu@storeifnotyet##1%
+ \def##1{\ifmmode##2{\mathchoice
+ {\hbox{\rm\char`##1}}{\hbox{\rm\char`##1}}%
+ {\hbox{\rm\scriptsize\char`##1}}{\hbox{\rm\tiny\char`##1}}}%
+ \else\char`##1\fi}}%
+ \do\{\mathopen
+ \do\}\mathclose
+ %
+ \def\={\mathbin{=}}%
+ \def\neqb{\mathbin{\neq}}%
+ \let\neb\neqb
+ \def\do##1{\gmu@storeifnotyet##1%
+ \edef\gma@tempa{%
+ \def\@xanxcs{\@xa\gobble\string##1r}{%
+ \@nx\mathrel{\@nx##1}}}%
+ \gma@tempa}%
+ \do\vee \do\wedge \do\neg
+ \def\fakern{\mkern-3mu}%
+ \thickmuskip=8mu plus 4mu\relax
+ %
+ \gma@gmathhook
+ }% of |\everymath|.
+ \everydisplay\everymath
+ \ifdefined\Url
+ \ampulexdef\Url{\let\do}\@makeother
+ {\everymath{}\let\do\@makeother}% I~don't know why but the
+ % \pk{url} package's \incs{url} typesets the argument inside
+ % a~math which caused digits not to be typewriter but Roman and
+ % lowercase.
+ \fi% of |\ifdefined\Url|.
+}% of |\def\gmathfurther|. \ResumeDef
+
+\Store@Macro\mathchar@type
+
+\DeclareCommand\gmath{oC{\NoValue}}{%
+ \gmathbase[#1](#2)%
+ \gmathfurther
+ \IfValueT{#1}{\csname gmathhook#1\endcsname}% this allows adding
+ % version-specific stuff (I~first used this for Fell fonts rescued
+ % with Garamond Premier)
+}
+
+\pdef\gmathscripts{% \changes{v0.96}{2008/11/11}{added}
+ \addtotoks\everymath{\catcode`\^=7\relax \catcode`\_=8\relax }%
+ \everydisplay\everymath}
+
+\pdef\gmathcats{%
+ \addtotoks\everymath{\gmu@septify}%
+ \everydisplay\everymath}
+
+\emptify\gma@quantifierhook
+\def\quantifierhook#1{%
+ \def\gma@quantifierhook{#1}}
+
+\emptify\gma@gmathhook
+\def\gmathhook#1{\addtomacro\gma@gmathhook{#1}}
+
+\def\gma@dollar$#1${{\gmath$#1$}}%
+\def\gma@bare#1{\gma@dollar$#1$}%
+\def\gma@checkbracket{\@ifnextchar\[%^^A\]
+ \gma@bracket\gma@bare}
+\def\gma@bracket\[#1\]{{\gmath\[#1\]}\@ifnextchar\par{}{\noindent}}
+\def\gma{\@ifnextchar$%^^A $
+ \gma@dollar\gma@checkbracket}
+
+ %^^B trial composition
+\def\bgcolor{\color{white}}
+
+\DeclareCommand\garamath{%
+ O{\rm}% the font command
+}{%
+ % Before 2009/10/19 all the stuff was added to |\everymath| which
+ % didn't work.
+ \quantifierhook{\addfontfeature{OpticalSize=800}}%
+ %
+ \def\gma@arrowdash{{%
+ \setbox0=\hbox{\char"2192}\copy0\kern-0,6\wd0
+ \bgcolor\rule[-\dp0]{0,6\wd0}{\dimexpr1,07\ht0+\dp0}\kern-0,6\wd0}}%
+ %
+ \def\gma@gmathhook{%
+ \def\do####1####2####3{\gmu@storeifnotyet####1%
+ \def####1{####3{%
+ \mathchoice{\hbox{#1####2}}{\hbox{#1####2}}%
+ {\hbox{#1\scriptsize####2}}{\hbox{#1\tiny####2}}}}}%
+ \do\mapsto{\rule[0,4ex]{0,1ex}{0,4ex}\kern-0,05em%
+ \gma@arrowdash\kern-0,05em\char"2192}\mathrel
+ \do\cup{\scshape u}\mathbin
+ \do\varnothing{\setbox0=\hbox{\gma@quantifierhook\addfontfeature{Scale=1.272727}0}%
+ \setbox2=\hbox{\char"2044}%
+ \copy0 \kern-0,5\wd0 \kern-0,5\wd2 \lower0,125\wd0 \copy2
+ \kern0,5\wd0\kern-0,5\wd2}{}% of |\varnothing|
+ \do\leftarrow{\char"2190\kern-0,05em\gma@arrowdash}\mathrel
+ \do\shortleftarrow{\char"2190}\mathrel
+ \do\rightarrow{\gma@arrowdash\kern-0,05em\char"2192}\mathrel
+ \do\shortrightarrow{\char"2192\relax}\mathrel
+ \do\in{\gma@quantifierhook\char"0454}\mathbin
+ \do\prec{\gma@quantifierhook
+ \rotatebox[origin=c]{-90}{%
+ \glyphname{u03A5.a}}}\mathrel % added 2009/9/11
+ }% of |\gma@gmathhook|
+}% of |\garamath|.
+
+
+
+\def\gmu@tempa{\kern-0,08em\penalty10000\hskip0sp\relax
+ s\penalty10000\hskip0sp\relax}
+
+\protected\edef\Vs{V\gmu@tempa}
+
+\protected\edef\Ws{W\gmu@tempa}
+
+\pdef\Wz{W\kern-0,05em\penalty10000\hskip0sp\relax z}
+
+
+\pdef\leftslanting@{%
+ \def\litdimen{\strip@pt\fontdimen1\font ex}%
+ \def\litcorrection{%
+ \ifhmode\null\nobreak\hskip\litdimen\relax\fi}%
+ \def\litkern{% note it's to be used inside the left slanted font,
+ % unlike \incmd\litcorrection, intended to be used \emph{before}
+ % switching to left slant/italic.
+ \leavevmode\null
+ \kern-\litdimen\relax}%
+ \def\dilitkern{\kern\litdimen\litkern}%
+ % \stanza
+ \pdef\litshape{% \changes{v0.93}{2008/08/22}{copied here from
+ % E.~Szarzyński's \ty{The Letters}}
+ \litcorrection
+ \itshape
+ \@tempdima=-2\fontdimen1\font
+ \advance\leftskip by\strip@pt\fontdimen1\font ex % to assure at
+ % least the lowercase letters not to overshoot to the (left)
+ % margin. Note this has any effect only if there is a~\incs{par} in
+ % the scope.
+ \litcorrection
+ \edef\gmu@tempa{%
+ \@nx\addfontfeature{FakeSlant=\strip@pt\@tempdima}}%^^B
+ % \ilrr when not \incs{edef}ed, it caused an error, which is
+ % perfectly understandable.
+ \gmu@tempa}%
+ %
+ %
+ \pdef\textlit##1{% \changes{v0.93}{2008/08/22}{added}
+ {\litshape##1}}%
+ %
+ \pdef\lit{\rm\litshape}%
+ %
+ %
+ \pdef\lsl{{%
+ \litcorrection
+ \it
+ % \changes{v0.93}{2008/08/22}{copied here from E.~Szarzyński's \ty{The
+ % Letters}}
+ \@tempdima=-\fontdimen1\font
+ \litcorrection
+ \xdef\gmu@tempa{%
+ \@nx\addfontfeature{RawFeature={slant=\strip@pt\@tempdima}}}}%
+ \rm % Note in this declaration we left-slant the basic Roman font
+ % not the itshape of the current family.
+ \gmu@tempa}%
+ %
+ % Now we can redefine \cs{em} and \cs{emph} to use left Italic for
+ % nested emphasis. In Polish typesetting there is bold in nested
+ % emphasis as I~have heard but we don't like bold since it perturbs
+ % homogeneous greyness of a~page. So we introduce a~three-cycle
+ % instead of two-: Italic, left Italic, upright.
+ %
+ \pdef\em{%\changes{v0.93}{2008/08/22}{added}
+ \ifdim\fontdimen1\font=\z@ \itshape
+ \else
+ \ifdim\fontdimen1\font>\z@ \litshape
+ \else \upshape
+ \fi
+ \fi}%
+ %
+ %
+ \pdef\emph##1{% \changes{v0.93}{2008/08/22}{added}
+ {\em##1}}%
+}% of \cs{leftslanting@}.
+
+\pdef\leftslanting{\AtBeginDocument\leftslanting@}
+
+\AtBeginDocument{\let\leftslanting\leftslanting@}
+
+
+\def\romorzero#1{%
+ \ifnum#1=0 zero\else\romannumeral#1 \fi}
+
+\DeclareCommand\fakeonum{%
+ o % fake bold for the digit »2« (for which emboldening improves
+ % look),
+ >Pm % the text to fake old-style numbers in.
+}{%\
+ % I~tried to use this command as a~declaration but active digits are
+ % very uncomfortable, e.g.\ you can't define macros with arguments.
+ % \chgs{2008/12/04 v0.98 added}
+ \gmu@if@onum{#2}{%
+ \begingroup
+ \edef\gmu@tempa{#2}%
+ \makeatletter%
+ \IfValueT{#1}{%
+ \prependtomacro\fake@onum@ii{%
+ \begingroup\addfontfeature{FakeBold=#1}}%
+ \addtomacro\fake@onum@ii\endgroup
+ }%
+ \endlinechar\m@ne % to suppress the line end added by
+ % |\scantokens|, especially in active |^^M|'s scopes.
+ \gmu@dofakeonum
+ \@xa\scantokens\@xa{\gmu@tempa}%
+ \endgroup
+ }% of |\gmu@ifonum| ‘else’.
+}% of |\fakeonum|.
+
+\def\gmu@dofakeonum{%
+ \def\do##1{%
+ \catcode`##1\active
+ \scantokens{%
+ \@xa\let\@xa##1%
+ \csname fake@onum@\@xa\romorzero\string##1\endcsname\empty}}%
+ \do0\do1\do2\do3\do4\do5\do6\do7\do8\do9%
+}
+
+\def\do#1#2{%
+ \@namedef{fake@onum@\romorzero#1}{#2}}
+
+\def\gmu@tempa#1{%
+ \do#1{\leavevmode
+ \gmu@calculateslant{#1}% uses \incs{gmu@tempa} and
+ % \incs{gmu@tempb}, therefore goes first. And defines \incs{gmu@tempd}.
+ \gmu@measurewd{#1}% the width of char |#1| is in \incs{gmu@tempa}
+ % without kerning and in \incs{gmu@tempb} with kerning.
+ %
+ \edef\gmu@tempc{\the\fontcharht\font`#1}%
+ \hbox to \gmu@tempb {%
+ \hss\resizebox{\gmu@tempa}%
+ {\dimexpr\fontdimen5\font+\gmu@tempc-\fontdimen8\font}%
+ {\gmu@tempd#1}\hss}}}
+
+\gmu@tempa0 % |\fake@onum@zero|
+\gmu@tempa1 % |\fake@onum@i|
+\gmu@tempa2 % |\fake@onum@ii|
+
+\def\gmu@tempa#1{%
+ \do#1{\leavevmode
+ \gmu@measurewd{#1}%
+ \lower
+ \dimexpr\fontdimen8\font-\fontdimen5\font\relax
+ \hbox to \gmu@tempb {\hss#1\hss}}%
+}
+
+\gmu@tempa3 % |\fake@onum@iii|
+\gmu@tempa4 % |\fake@onum@iv|
+\gmu@tempa5 % |\fake@onum@v|
+\gmu@tempa7 % |\fake@onum@vii|
+\gmu@tempa9 % |\fake@onum@ix|
+
+\def\gmu@tempa#1{% to preserve pseudo-kerning in digits sequences.
+ \do#1{\leavevmode
+ \gmu@measurewd#1%
+ \hbox to \gmu@tempb {\hss#1\hss}}}
+
+\gmu@tempa6 % |\fake@onum@vi|
+\gmu@tempa8 % |\fake@onum@viii|
+
+\protected\def\gmu@if@onum{%
+ \edef\gmu@tempa{\@xa\meaning\the\font}%
+ \@xa\@ifinmeaning\detokenize{+onum}\of\gmu@tempa
+}
+
+\pdef\gmu@getslant{% we define |\gmu@tempa| to the (fake) slant of current font.
+ \edef\gmu@tempa{\@xa\meaning\the\font\detokenize{slant=0,}}%
+ \edef\gmu@tempb{%
+ \def\@nx\gmu@tempb####1%
+ \detokenize{slant=}%
+ ####2,####3}%
+ \gmu@tempb\@nil{##2}%
+ \edef\gmu@tempa{\@xa\gmu@tempb\gmu@tempa\@nil pt}%
+}
+
+\def\gmu@calculateslant#1{%
+ \gmu@getslant
+ \edef\gmu@tempa{\the\numexpr\dimexpr\fontdimen1\font + \gmu@tempa}%\
+ % \incs{gmu@tempa} bears the number of scaled points of total slant
+ % (\inverb|\fontdimen1\font|${}+$\inverb|slant=…| if present) per 1pt
+ % of \inhash1.\ilrr
+ \edef\gmu@tempa{\the\numexpr \gmu@tempa *
+ \numexpr\fontdimen5\font\relax/\numexpr\fontcharht\font`#1
+ \relax}%\
+ % we scale the total slant of \inverb|#1| by the ratio of original
+ % and scaled height of \inverb|#1|.
+ \edef\gmu@tempd{%
+ \the\dimexpr \gmu@tempa sp - \fontdimen1\font}%\
+ % and we subtract slant-fontdimen from the scaled total slant.
+ \ifdim\gmu@tempd=\z@ \emptify\gmu@tempd
+ \else\edef\gmu@tempd{%
+ \@nx\addfontfeature{FakeSlant=\strip@pt\dimexpr\gmu@tempd}}%
+ \fi}
+
+\DeclareCommand\gmu@cepstnof{O{\gmu@tempa}% a~cs to be |\xdef|ed the
+ % font specification,
+ s% not used really,
+ m% |\fontspec| token or name of feature font (\inverb|Italic|, \inverb|Bold|,
+ % \inverb|SmallCaps|, \inverb|BoldItalic| ),
+ O{, Scale=MatchLowercase}% \pk{fontspec} font features (key=val)
+}
+{% |\gmu@cepstnof|'s body
+ \def\gmu@cepstnof@resc##1:##2:\@nil{%
+ \ifx:##2:\else RawFeature={\gmu@maybestripcomma##2,,\@nil} \fi}%
+ % \stanza
+ \def\gmu@cepstnof@resd##1/##2/\@nil{% to check whether font name
+ % contains |/| (which may not be true!)
+ \ifx&##2&\@xa\@firstoftwo\else\@xa\@secondoftwo\fi}%
+ % \stanza
+ \def\gmu@cepstnof@rese##1:##2:\@nil{% to check whether the font name
+ % contains |:| when it doesn't contain |/|.
+ \ifx&##2&\@xa\@firstoftwo\else\@xa\@secondoftwo\fi}%
+ % \stanza
+ \edef\gmu@cepstnof@resa{%
+ % now, reserved B parses the font name and features. It uses an
+ % auxiliary reserved C because after |/| may be or may not be
+ % features specification.
+ \@xa\@xa\@xa\gmu@cepstnof@resd\@xa\meaning\the\font//\@nil
+ {% font name doesn't contain a~slash
+ \@xa\@xa\@xa\gmu@cepstnof@rese\@xa\meaning\the\font::\@nil
+ {% nor does it contain a~colon
+ \def\@nx\gmu@cepstnof@resb\detokenize{select font
+ "}####1\detokenize{"}####2\@nx\@nil{%
+ \ifx\fontspec#3%
+ \@nx\@nx\@nx\fontspec[\@gobble#4\@empty]{####1}% gobble a~comma
+ \else
+ #3Font={####1}, #3Features={\@gobble #4\@empty}%
+ \fi
+ }%
+ }%
+ {% no slash but there is a~colon
+ \def\@nx\gmu@cepstnof@resb\detokenize{select font
+ "}####1:####2\detokenize{"}####3\@nx\@nil{%
+ \ifx\fontspec#3%
+ \@nx\@nx\@nx\fontspec[\@nx\gmu@cepstnof@resc####2::\@nx\@nil#4]{####1}%
+ \else
+ #3Font={####1}, #3Features={\@nx\gmu@cepstnof@resc####2::\@nx\@nil#4}%
+ \fi
+ }%
+ }%
+ }% of ‘no slash’ case
+ {% font name contains a~slash
+ \def\@nx\gmu@cepstnof@resb\detokenize{select font
+ "}####1/####2\detokenize{"}####3\@nx\@nil{%
+ \ifx\fontspec#3%
+ \@nx\@nx\@nx\fontspec[\@nx\gmu@cepstnof@resc####2::\@nx\@nil#4]{####1}%
+ \else
+ #3Font={####1}, #3Features={\@nx\gmu@cepstnof@resc####2::\@nx\@nil#4}%
+ \fi
+ }% of |\gmu@cepstnof@resb|
+ }% of ‘slash present’ case
+ }\gmu@cepstnof@resa
+ \xdef#1{\@xa\@xa\@xa\gmu@cepstnof@resb\@xa\meaning\the\font\@nil}%
+}%
+
+\def\gmu@stripcomma#1,{#1}
+
+\def\gmu@maybestripcomma#1,,#2\@nil{#1}
+
+\pdef\gmu@setbasefont{\@xa\let\@xa\gmu@basefont\the\font}
+
+\let\setbasefont\gmu@setbasefont
+
+\DeclareCommand\gmu@calc@scale{%
+ O{1}% a~factor,
+ m% number of the fontdimen
+ }
+{\begingroup
+ % We ‘descale’ the current font:\nostanza
+ \gmu@cepstnof\fontspec[, Scale=1]\gmu@tempa
+ \@xa\let\@xa\gmu@currfont@descaled\the\font
+ \gmu@basefont
+ \gmu@cepstnof\fontspec[, Scale=1]\gmu@tempa
+ % \nostanza now also the base font is descaled.
+ \xdef\gmu@fontscale{%
+ \strip@pt
+ \dimexpr 1pt *
+ \numexpr\dimexpr#1\fontdimen#2\font\relax\relax /
+ \numexpr\fontdimen#2\gmu@currfont@descaled\relax
+ \relax}%
+ \endgroup}
+
+
+\def\gmu@tilde{%
+ \leavevmode\lower.8ex\hbox{$\,\widetilde{\mbox{ }}\,$}}
+\AtBeginDocument{% to bypass redefinition of |\~| as a~text command
+ % with various encodings
+ \pdef\texttilde{%
+ % \changes{v0.83}{2007/08/22}{postponed to
+ % \cs{begin\{document\}} to avoid overwriting by a~text command
+ % and
+ % made sensible to a~subsequent
+ % /} % \changes{v0.86}{2007/12/11}{renamed from \cmd\~
+ % since the latter is one of \LaTeX's\ accents}
+ \@ifnextchar/{\gmu@tilde\kern-0,1667em\relax}\gmu@tilde}}
+
+\foone{\catcode`\^^M\active}% the comment signs here are crucial.
+{\def\defobeylines{\catcode`\^^M=13 \def^^M{\par}}}
+
+
+\def\deksmallskip{\vskip\smallskipamount}
+\def\undeksmallskip{\vskip-\smallskipamount}
+\def\dekmedbigskip{\vskip\glueexpr \medskipamount+\smallskipamount}
+\def\dekmedskip{\vskip\medskipamount}
+\def\dekbigskip{\vskip\bigskipamount}
+
+\def\hfillneg{\hskip 0pt plus -1fill\relax}
+
+\newcommand*{\TODO}[1][]{{%
+ \sffamily\bfseries\huge TO-DO!\if\relax#1\relax\else\space\fi#1}}
+
+
+\newcommand*\twocoltoc{%
+ \RequirePackage{multicol}%
+ \def\@starttoc##1{%
+ \begin{multicols}{2}\makeatletter
+ \NamedInput % changed from |\@input| 2010/8/13.
+ {\jobname .##1}%
+ \if@filesw \@xa \newwrite \csname tf@##1\endcsname
+ \immediate \openout \csname tf@##1\endcsname \jobname .##1\relax
+ \fi
+ \@nobreakfalse\end{multicols}%
+ }% of |\starttoc|
+}
+
+\@onlypreamble\twocoltoc
+
+
+\pdef\equals{\hunskip${}={}$\ignorespaces}
+\pdef\eequals{\hunskip${}=={}$\ignorespaces}
+
+\pdef\·{\hunskip${}·{}$\ignorespaces}
+
+
+\def\freeze@actives{%
+ \count\z@\z@
+ %
+ \@whilenum\count\z@<\@cclvi\do{%
+ \ifnum\catcode\count\z@=\active
+ \uccode`\~=\count\z@
+ \uppercase{\let~\relax}%
+ \fi
+ \advance\count\z@\@ne}}
+
+
+\newcommand*\ShowFont[1][6]{%
+ \begin{multicols}{#1}[The current font (the \f@encoding\ encoding):]
+ \parindent\z@
+ \count\z@\m@ne
+ \@whilenum\count\z@<\@cclv\do{
+ \advance\count\z@\@ne
+ \ \the\count\z@:~\char\count\z@\par}
+ \end{multicols}}
+
+\newcommand*\liturgiques[1][red]{% Requires the \pk{color} package.
+ \gmu@RPfor{xcolor}\color%
+ \newcommand*\czerwo{\small\color{#1}}% environment
+ \newcommand{\czer}[1]{\leavevmode{\czerwo##1}}% we leave
+ % vmode because if we don't, then \env{verse}'s |\everypar| would be
+ % executed in a~group and thus its effect lost.
+ \Store@Macro\*%
+ \def\*{\czer{\storedcsname{*}}}%
+ \def\+{\czer{†}}%
+ \newcommand*\nieczer[1]{\textcolor{black}{##1}}%
+}
+
+\newcommand*\gmu@RPfor[3][]{% \changes{v0.93}{2008/08/30}{renamed from
+ % \cs{gmu@RPif} and \#3 changed from a~csname to \CS}
+ \ifx\relax#1\relax\emptify\gmu@resa
+ \else \def\gmu@resa{[#1]}%
+ \fi
+ \@xa\RequirePackage\gmu@resa{#2}}
+
+\AtBeginDocument{%
+ \renewcommand*\gmu@RPfor[3][]{%
+ \unless\ifdefined#3%
+ \@ifpackageloaded{#2}{}{%
+ \typeout{^^J! Package `#2' not loaded!!! (\on@line)^^J}}%
+ \fi}}
+
+\pprovide\continuum{%
+ \gmu@RPfor{eufrak}\mathfrak\ensuremath{\mathfrak{c}}}
+
+\def\iteracro{%
+ \pdef\acro##1{%
+ \begingroup
+ \acropresetting
+ \gmu@acrospaces##1 \gmu@acrospaces
+ \endgroup
+ }%
+}
+
+\emptify\acropresetting
+
+\iteracro
+
+\def\gmu@acrospaces#1 #2\gmu@acrospaces{%
+ \gmu@acroiter#1\gmu@acroiter
+ \ifx\relax#2\relax\else
+ \space
+ \afterfi{\gmu@acrospaces#2\gmu@acrospaces}% when |#2| is nonempty,
+ % it is ended with a~space. Adding one
+ % more space in this line resulted in
+ % an infinite loop, of course.
+ \fi}
+
+\def\gmu@acroiter#1{%
+ \gmu@notif {x\@xa\@xa} {\@firstofmany#1\@undefined\@nil \gmu@acroiter}
+ {\gmu@acrokernel{#1}%
+ % and iterate
+ \gmu@acroiter
+ }% of if sentinel or not
+ {}%
+}
+
+\def\gmu@acrokernel#1{%
+ \gmu@if {cat} {a\@xanx\@firstofmany#1\@undefined\@nil}
+ {\gmu@if {num} {`#1=\uccode`#1\space }% a space to delimit numer
+ % (without it further macros were
+ % expanded which in this case are
+ % |\expandafter\@firstoftwo\else\@secondoftwo| and this made the test didn't work.)
+ {{\acrocore{#1}}}%
+ {{#1}}% tu było |\smallerr|
+ }%
+ {#1}%
+}
+
+\pdef\acrocore{\smaller % was: |\scshape\lowercase|
+}
+
+
+\def\IMHO{\acro{IMHO}}
+\def\AKA{\acro{AKA}}
+
+\pdef\usc#1{{\addfontfeature{Letters=UppercaseSmallCaps}#1}}
+
+\def\uscacro{\let\acrocore\usc}
+
+
+
+\def\gmu@dekfraccsimple#1/#2{\leavevmode\kern.1em
+ \raise.7ex\hbox{%^^A \udigits
+ \gmu@fracfontsetup#1}\gmu@numeratorkern
+ \dekfraccslash\gmu@denominatorkern
+ {%^^A\udigits
+ \gmu@fracfontsetup#2}%
+ \if@gmu@mmhbox\egroup\fi}
+
+\def\gmu@fracfontsetup{%
+ \smaller[3]\addfontfeature{FakeBold=1}}
+
+\def\dekfraccsimple{% \label{2292}
+ \let\dekfracc@args\gmu@dekfraccsimple
+}
+\@ifXeTeX{\def\dekfraccslash{\char"2044 }}
+{\def\dekfraccslash{/}} % You can define it as the fraction slash,
+\dekfraccsimple
+
+
+
+\newcommand*\ikern{\,\penalty\@M\hskip\z@skip\relax}
+
+
+\def\gmu@scapLetters#1{%
+ \ifx#1\relax\relax\else% two |\relax|es to cover the case of empty |#1|.
+ \ifcat a\@nx#1\relax
+ \ifnum\the\lccode`#1=`#1\relax
+ {\fakescapscore\MakeUppercase{#1}}% not Plain |\uppercase|
+ % because that works bad with \pk{inputenc}.
+ \else#1%
+ \fi
+ \else#1%
+ \fi%
+ \@xa\gmu@scapLetters
+ \fi}%
+\def\gmu@scapSpaces#1 #2\@nil{%
+ \ifx#1\relax\relax
+ \else\gmu@scapLetters#1\relax
+ \fi
+ \ifx#2\relax\relax
+ \else\afterfi{\ \gmu@scapSpaces#2\@nil}%
+ \fi}
+\def\gmu@scapss#1\@nil{{\def~{{\nobreakspace}}%
+ \gmu@scapSpaces#1 \@nil}}%|% \def\\{{\newline}}\relax|
+
+\pdef\fakescaps#1{{\gmu@scapss#1\@nil}}
+
+\let\fakescapscore\gmu@scalematchX
+
+\def\tinycae{{\tiny\AE}}% to use in |\fakescaps[\tiny]{…}|
+
+\RequirePackage{calc}
+
+
+\@ifpackageloaded{fontspec}{%
+ \def\gmu@scalar{1.0}%
+ \def\zf@scale{}%
+ \def\gmu@scalematchX{%
+ \begingroup
+ \ifx\zf@scale\empty\def\gmu@scalar{1.0}%
+ \else\let\gmu@scalar\zf@scale\fi
+ \setlength\@tempdima{\fontdimen5\font}% 5---ex height
+ \setlength\@tempdimb{\fontdimen8\font}% 8---\XeTeX\ synthesised
+ % uppercase height.
+ \divide\@tempdimb by1000\relax
+ \divide\@tempdima by\@tempdimb
+ \setlength{\@tempdima}{\@tempdima*\real{\gmu@scalar}}%
+ \gmu@ifundefined{fakesc@extrascale}{}{%
+ \setlength{\@tempdima}{\@tempdima*\real{\fakesc@extrascale}}}%
+ \@tempcnta=\@tempdima
+ \divide\@tempcnta by 1000\relax
+ \@tempcntb=-1000\relax
+ \multiply\@tempcntb by\@tempcnta
+ \advance\@tempcntb by\@tempdima
+ \xdef\gmu@scscale{\the\@tempcnta.%
+ \ifnum\@tempcntb<100 0\fi
+ \ifnum\@tempcntb<10 0\fi
+ \the\@tempcntb}%^^A{\strip@pt\@tempdimc}%
+ \endgroup
+ \addfontfeature{Scale=\gmu@scscale}%
+ }}{\let\gmu@scalematchX\smallerr}
+
+\def\fakescextrascale#1{\def\fakesc@extrascale{#1}}
+
+\newcommand*\wyzejnizej[1]{%
+ \edef\gmu@tempa{\gmu@ifundefined{r@#1}{\arabic{page}}{%
+ \@xa\@xa\@xa\@secondoftwo\csname r@#1\endcsname}}%
+ \ifnum\gmu@tempa<\arabic{page}\relax wy\.zej\fi
+ \ifnum\gmu@tempa>\arabic{page}\relax ni\.zej\fi
+ \ifnum\gmu@tempa=\arabic{page}\relax \@xa\ignorespaces\fi
+}
+
+
+\def\napapierkistretch{0,3pt}% It's quite much for 11/13pt leading.
+
+\def\napapierkicore{\advance\baselineskip%
+ by 0ptplus\napapierkistretch\relax}
+
+\DeclareEnvironment{napapierki}{s}{%
+ % \chgs{2009/01/05 v0.98 added optional star controlling globalness}
+ \par\IfValueT{#1}{\global}%
+ %
+ \napapierkicore}
+{%
+ \par
+ \IfValueT{#1}{\global\baselineskip=1\baselineskip\relax
+ }%
+}% so that you can use \inverb|\napapierki*›…\endnapapierki*|
+
+\newcount\gmu@luzniej
+
+\newcommand*\luzniejcore[1][1]{%
+ \advance\gmu@luzniej\@ne% We use this count to check whether we open
+ % the environment or just set |\looseness| inside it again.
+ \ifnum\gmu@luzniej=\@ne \multiply\tolerance by 2 \fi
+ \looseness=#1\relax}
+
+\newenvironment*{luzniej}{\par\luzniejcore}{\par}
+
+\newenvironment*{luzniej*}[1][1]{%
+ \multiply\tolerance by 2\relax
+ \everypar{\looseness=#1\relax}}{\par}
+
+\newcommand*\nawj{\kern0,1em\relax}% a~kern to be put between
+
+\def\pauza@skipcore{\hskip0.2em plus0.1em\relax
+ \pauzacore
+ \@ifnextchar,{% 2009/11/22 added a special case of a comma following pauza
+ }{\hskip.2em plus0.1em\relax\ignorespaces}}%
+\def\ppauza@skipcore{\unskip\penalty10000\hskip0.2em plus0.1em\relax
+ \ppauza@dash\hskip.2em plus0.1em\ignorespaces}
+
+\AtBeginDocument{%
+ \pdef\pauza{%
+ \ifhmode
+ \unskip\penalty10000
+ \hskip0.2em plus0.1em\relax
+ \pauzacore\hskip.2em plus0.1em\relax\ignorespaces%
+ \else
+ \pauzadial
+ \fi
+ }%
+ %
+ % According to \tytul{Instrukcja technologiczna.\ Skład ręczny ^^B
+ % i~maszynowy} the dialogue dash (in Polish) should be followed by
+ % a~rigid hskip of \dekfracc1/2\,em.
+ \pdef\pauzadial{%
+ \leavevmode\pauzacore\penalty10000\hskip0,5em\ignorespaces}
+ %
+ % And a~version with no space at the left, to begin a~|\noindent|ed
+ % paragraph explaining e.g.\ a~quotation:
+ \pdef\lpauza{%
+ \leavevmode
+ \pauzacore\hskip.2em plus0.1em\ignorespaces}%
+ %
+ % We define |\ppauza| as an en dash surrounded with thin stretchable
+ % spaces and sticking to the upper line or bare but discretionary
+ % depending on the next token being space${}_10$. Of course you'll
+ % never get such a~space after a~literal \CS so an explicit |\ppauza|
+ % will always result with a~bare discretionary en dash, but if we
+ % |\let–\ppauza|…
+ % \stanza
+ \pdef\ppauza{%
+ \ifvmode \PackageError{gmutils}{%
+ command \bslash ppauza (en dash) not intended for vmode.}{%
+ Use \bslash ppauza (en dash) only in number and numeral ranges.}%
+ \else
+ \unskip\discretionary
+ {\ppauza@dash}{\ppauza@dash}{\ppauza@dash}%
+ \fi}%
+}% of at begin document
+
+\ifdefined\XeTeXversion
+\AtBeginDocument{% to be independent of moment of loading of \pk{polski}.
+ \pdef\—{%
+ \ifhmode
+ \unskip\penalty10000
+ \afterfi{%
+ \@ifnextspace{\pauza@skipcore}%
+ {\@ifnextchar,{\pauza@skipcore}% a special case of comma added 2009/11/22
+ {\@ifnextMac{\pauza@skipcore}%
+ {\pauzacore\penalty\hyphenpenalty\hskip\z@skip}}}%
+ }% of |\afterfi|'s argument
+ \else
+ % \nostanza According to \tytul{Instrukcja technologiczna.\ Skład ręczny ^^B
+ % i~maszynowy} the dialogue dash should be followed by a~rigid
+ % hskip of \dekfracc1/2\,em.\nostanza
+ \leavevmode\pauzacore\penalty10000\hskip0,5em\ignorespaces
+ \fi
+ }%
+ % The next command's name consists of letters and therefore it eats
+ % any spaces following it, so |\@ifnextspace| would always be
+ % false, therefore we don't use it.\nostanza
+ \pdef\–{%
+ \ifvmode \PackageError{gmutils}{%
+ command \bslash ppauza (en dash) not intended for vmode.}{%
+ Use \bslash ppauza (en dash) only in number and numeral ranges.}%
+ \else
+ \afterfi{%
+ \@ifnextspace{\ppauza@skipcore}{%
+ \@ifnextMac\ppauza@skipcore
+ {\unskip\discretionary
+ {\ppauza@dash}{\ppauza@dash}{\ppauza@dash}}}%
+ }%
+ \fi
+ }%
+ %
+ \def\emdash{\char`\—}
+}% of at begin document
+
+\def\longpauza{\def\pauzacore{—}}
+\longpauza
+\def\shortpauza{%
+ \def\pauzacore{\hbox{–\kern,23em\relax\llap{–}}}}%
+\def\ppauza@dash{–}%
+
+\else % not \XeTeX
+\def\longpauza{\def\pauzacore{---}}
+\longpauza
+\def\shortpauza{%
+ \def\pauzacore{--\kern,23em\relax\llap{--}}}%
+\def\ppauza@dash{--}%
+
+\fi% of if \XeTeX\ or not.
+
+\ifdefined\XeTeXversion
+
+\foone{\catcode`—\active \catcode`–\active \catcode`-\active}{%\label{not@ifundef}
+ \def\adashes{\AtBeginDocument\adashes}% because |\pauza|
+ % is defined at begin document.
+ \AtBeginDocument{\def\adashes{%
+ \catcode`—\active \def—{\—}%
+ \catcode`–\active \def–{\–}%
+ \addtomacro\dospecials{\do\–\do\—}%
+ \addtomacro\@sanitize{\@makeother\–\@makeother\—}%
+ \addtomacro\gmu@septify{\do\–13\do\—13\relax}%
+}}}
+\else
+\relaxen\adashes
+\fi
+
+
+\def\gmu@dywiz{\ifmmode-\else
+ \ifvmode-\else\afterfifi\dywiz\fi\fi}%
+
+\foone{\catcode`-\active}{% aktivnyj diefis aktywny dywiz active hyphen
+ \def\ahyphen{\let-\gmu@dywiz\catcode`\-\active}}
+
+\newcommand*\czas[1][.]{%
+ \the\numexpr(\time-30)/60\relax#1%
+ \@tempcnta=\numexpr\time-(\time-30)/60*60\relax
+ \ifnum\@tempcnta<10 0\fi\the\@tempcnta}
+
+\newenvironment*{tytulowa}{\newpage}{\par\thispagestyle{empty}\newpage}
+
+\def\nazwired{\quad\textsc}
+
+
+\pdef\polskadata{%
+ \DeclareCommand\gmu@datefsl{%
+ ##1 Q{0123456789\bgroup}>iT{/-} % year
+ ##2 Q{0123456789\bgroup}>iT{/-} % month
+ ##3 Q{0123456789\bgroup} % day
+ ##4 T{,}
+ ##5 K{##1\gmu@datefsl} % additional stuff after comma
+ }{%
+ \IfValueF{##2}{\PutIfValue{##3}}%
+ \IfValueT{##2}{%
+ \@tempcnta=0##3\relax\the\@tempcnta
+ \ifcase##2\relax\or\ stycznia\or\ lutego%
+ \or\ marca\or\ kwietnia\or\ maja\or\ czerwca\or\ lipca\or\ sierpnia%
+ \or\ września\or\ października\or\ listopada\or\ grudnia\else
+ {}%
+ \fi}%
+ \IfValueT{##1}{\space ##1}%
+ \PutIfValue{##4}\IfValueT{##5}{ ##5}%
+ }% of \incs{gmu@datefsl}.
+ }% of |\polskadata|
+
+\polskadata
+
+\pdef\englishdate{%
+ \DeclareCommand\gmu@datefsl{%
+ Q{0123456789\bgroup}>iT{/-} % (1) year
+ Q{0123456789\bgroup}>iT{/-} % (2) month
+ Q{0123456789\bgroup} % (3) day
+ T{,} K{##1\gmu@datefsl} % (4, 5) additional stuff after comma
+ }{%
+ \IfValueF{##2}{\PutIfValue{##3}}%
+ \IfValueT{##2}{%
+ \ifcase##2\relax\or January\or February%
+ \or March\or April\or May\or June\or July\or August%
+ \or September\or October\or November\or December\else
+ {}%
+ \fi}%
+ \space
+ \@tempcnta=##3\relax\the\@tempcnta,
+ \IfValueT{##1}{ ##1}%
+ \PutIfValue{##4}\IfValueT{##5}{ ##5}%
+ }% of \incs{gmu@datefsl}.
+}%
+
+\newif\ifdate
+\pdef\bidate#1{%
+ \gmu@datefsl#1\gmu@datefsl
+}
+
+\pdef\linedate{\gmu@ifstar\linedate@@\linedate@}
+\pdef\linedate@@#1{\linedate@{--{}{}#1}}
+\pdef\linedate@#1{\par
+ \linedate@hook{#1}%
+ \ifdate\addvspace{\dateskipamount}%
+ \possvfil% if we put it before |\addvspace|, the v-space is always added.
+ \date@line{\DateFont \bidate{#1}}%
+ \nopagebreak
+ \else%|%\ifnum\arabic{dateinsection}>0\dekbigskip\fi|
+ \addvspace{\bigskipamount}\possvfil
+ \fi}% end of |\linedate|.
+
+\newcommand*\DateFont{\footnotesize\itshape}
+
+\let\linedate@hook\@gobble
+
+\let\dateskipamount\medskipamount
+
+\pdef\rdate{\let\date@line\rightline \linedate}
+
+\def\date@left#1{\par{%
+ \raggedright#1%
+ \leftskip\z@skip
+ \@@par}}%
+
+\pdef\ldate{%\changes{v0.94}{2008/09/06}{\cs{leftline}
+ % replaced with \cs{par}…\cs{par} to work well with \pk{floatflt}}
+ \let\date@line\date@left
+ \linedate}
+
+\newcommand*\runindate[1]{%
+ \paragraph{\footnotesize\itshape \gmu@datef#1\gmu@datef}%
+ \stepcounter{dateinsection}}
+\let\thedate\ldate
+
+\pdef\zwrobcy#1{\emph{#1}} %ostinato, allegro con moto,
+ %garden party etc., także kompliment
+
+\pdef\tytul#1{\emph{#1}}
+
+\newenvironment{maszynopis}[1][]{#1\ttfamily
+ \hyphenchar\font=45\relax% this assignment is global for the font.
+ \@tempskipa=\glueexpr\rightskip+\leftskip\relax
+ \ifdim\gluestretch\@tempskipa=\z@
+ \tolerance900
+ % \nostanza it worked well with tolerance \equals 900.\nostanza
+ \advance\rightskip by\z@ plus0,5em\relax\fi
+ \fontdimen3\font=\z@% we forbid stretching spaces…\par\nostanza\gmdnoindent
+ %|% \fontdimen4\font=\z@| but allow shrinking them.\nostanza
+ \hyphenpenalty0 % not to make \TeX\ nervous: in a~typewriting this
+ % marvellous algorithm of hyphenation should be turned off and every
+ % line broken at the last allowable point.
+ \Store@Macro\pauzacore
+ \def\pauzacore{-\rlap{\kern-0,3em-}-}%
+}{\par}
+
+\pdef\justified{%
+ \leftskip=1\leftskip% to preserve the natural length and discard
+ % stretch and shrink.
+ \rightskip=1\rightskip
+ \parfillskip=1\parfillskip
+ \advance\parfillskip by 0sp plus 1fil\relax
+ \let\\\@normalcr}
+
+\DeclareCommand\fullpar{%
+ T{+-}%
+ Q{+-0123456789} % optional looseness (most probably negative)
+}{%
+ \begingroup
+ \IfValueT{#1}{\looseness=#1\IfValueTF{#2}{#2}{1}\relax
+ \multiply\tolerance by \tw@
+ }%
+ \fullparcore
+ \par
+ \endgroup}
+
+\pdef\fullparcore{%
+ \hunskip
+ \parfillskip\z@skip}
+
+\newcommand*\twoparinit{% the name stands for `\emph{last} paragraph
+ % line's length \emph{min}imum \emph{two} \incs{parindent}.
+ \def\twopar@defts{%
+ \hsize-\leftskip-\rightskip-\fontcharwd\font`…}%
+ \def\twopar@atleast{2\@parindent}%
+ \DeclareCommand\twopar{%
+ T{+-}% (1) you can specify loosening the paragraph by one only by
+ % typing single |+| and tightening by one by typing single |-|.
+ Q{+-0123456789}% (2)
+ A{\twopar@atleast}% (3)
+ >iT{\cipolagwa}}{%
+ \begingroup
+ \IfValueT{##1}{%
+ \looseness=##1\IfValueTF{##2}{##2}{1}\relax
+ \multiply\tolerance by2
+ }%
+ \twoparcore<##3>%
+ \par
+ \endgroup
+ }% of \incmd\twopar.
+ % \stanza
+ \ifdefined\XeTeXversion
+ \DeclareCommand\twoparcore{%
+ A{\twopar@atleast}
+ \gobblespace
+ }{%
+ \hunskip % it's \ac{O.K.} it's in a~group, it'll work anyway.
+ \edef\gmu@tempa{\the\dimexpr\twopar@defts-##1\relax}%
+ \parfillskip=\glueexpr\gmu@tempa minus \gmu@tempa
+ \relax% to delimit |\glueexpr|.
+ \relax% to delimit the assignment.
+ }%
+ \else % not \XeTeX---doesn't use |\fontcharwd|.
+ \DeclareCommand\twoparcore{%
+ A{\twopar@default}
+ \gobblespace
+ }{%
+ \hunskip % it's \ac{O.K.} it's in a~group, it'll work anyway.
+ {\setbox0=\hbox{\dots}%
+ \xdef\gmu@tempa{\the\wd0}}%
+ \edef\gmu@tempa{%
+ \the\dimexpr\hsize-\leftskip-\rightskip
+ -\gmu@tempa-2\@parindent\relax}%
+ \parfillskip=\glueexpr\gmu@tempa minus \gmu@tempa
+ \relax% to delimit |\glueexpr|.
+ \relax% to delimit the assignment.
+ }%
+ \fi
+ % \stanza
+ \AtBeginDocument{%
+ \def\restoreparindent{\parindent\@parindent}%
+ }% of \cmd\AtBeginDocument.
+}% of \cs{twoparinit}.
+
+
+\def\gmu@leftskipcorr{%
+ \kern1\leftskip
+ \ifcsname \@currenvir leftskip\endcsname
+ \kern-1\csname \@currenvir leftskip\endcsname
+ \fi
+}
+
+\DeclareCommand\wherncore{om}{%\
+ % \begin{enumargs}
+ % \dc optional value of \incs{hskip} of (left) indent of the parbox. If
+ % absent, parbox is aligned right;
+ % \dc text for the datum parbox.
+ % \end{enumargs}
+ \IfValueTF{#1}{\leftline{%
+ \kern1\leftskip
+ \whernfont
+ \hskip#1\relax\parbox
+ {\dimexpr\textwidth-\leftskip-\rightskip-#1}%
+ {#2}% of |\parbox|,
+ }% of |\leftline|,
+ }% of |ValueT{#1}|.
+ {% |ValueF{#1}|:
+ \rightline
+ {\whernfont
+ \whern@parbox{#2}%
+ \kern1\rightskip
+ }% of |\rightline|,
+ \setprevdepth
+ }% of |ValueF{#1}|,
+}% of |\wherncore|.
+
+\DeclareCommand\whern@parbox{%
+ T {\leftskip\rightskip}% horizontal alignment of resulting box (the
+ % side to be ragged)
+ O{t} % vertical alignment of parbox
+ >is % separator
+ O{0,7666\textwidth} % (3) width of parbox
+ m % (4) parbox contents
+}{%
+ % \begin{enumargs}
+ % \dc S the skip of the ragged side,
+ % \dc the |\parbox|'s contents.
+ % \end{enumargs}
+ \parbox[#2]{#3}{%
+ \IfValueTF{#1}{#1}{\leftskip}=0sp plus \textwidth
+ \parfillskip0sp\relax
+ \let\\\linebreak
+ \disobeylines
+ \whernfont #4\unskip\strut\endgraf
+ \getprevdepth
+ }% of |\parbox|,
+}% of |\whern@parbox|.
+
+\def\whern{%
+ \endgraf\nopagebreak
+ \gmu@ifstar{\wherncore}%
+ {\vskip\whernskip\wherncore}}
+
+\let\whernfont\footnotesize
+
+\newskip\whernskip
+\whernskip2\baselineskip minus 2\baselineskip\relax
+
+\DeclareCommand\whernup{%
+ o % a~vskip before
+ >is % separating star (ignored)
+ o % (2) custom width of parbox
+ >Pm}{\par
+ \IfValueT{#1}{\vskip#1\relax}%
+ \leftline{%
+ \gmu@leftskipcorr
+ \IfValueTF{#2}{\whern@parbox\rightskip[b][#2]}%
+ {\whern@parbox\rightskip[b]}%
+ {#3}%
+ }%
+ \setprevdepth
+ \nopagebreak\relax
+ \@ifenvir{quote}{\noindent\ignorespaces}{}}
+
+
+\pdef\thousep#1{% a~macro that'll put the thousand separator between
+ % every two three-digit groups.\par\nostanza
+ % First we check whether we have at least five digits.
+ %\changes{v0.93}{2008/08/23}{added}
+ \gmu@thou@fiver#1\relax\relax\relax\relax\relax% we put five
+ % \incs{relax}es after the parameter to ensure the string will meet
+ % \incs{gmu\+@\+thou\+@\+fi\+ver}'s definition.\ilrr
+ \gmu@thou@fiver{#1}{% if more than five digits:
+ \emptify\gmu@thou@put
+ \relaxen\gmu@thou@o\relaxen\gmu@thou@i\relaxen\gmu@thou@ii
+ \@tempcnta\z@
+ \gmu@thou@putter#1\gmu@thou@putter
+ \gmu@thou@put
+ }}
+
+\def\gmu@thou@fiver#1#2#3#4#5\gmu@thou@fiver#6#7{% this macro only
+ % checks if the text delimited with itself consists of at least five tokens/braces
+ \ifx\relax#5\relax\@xa\@firstoftwo
+ \else\@xa\@secondoftwo
+ \fi{#6}{#7}}
+
+\def\gmu@thou@putter #1#2{% we are sure to have at least five tokens
+ % before the sentinel \incs{gmu@thou@putter}.
+ \advance\@tempcnta\@ne
+ \@tempcntb\@tempcnta
+ \divide\@tempcntb3\relax
+ \@tempcnta=\numexpr\@tempcnta-\@tempcntb*3
+ \edef\gmu@thou@put{\@xau{\gmu@thou@put}\unexpanded{#1}%
+ \ifx\gmu@thou@putter#2\else
+ \ifcase\@tempcnta
+ \gmu@thou@o\or\gmu@thou@i\or\gmu@thou@ii% all three
+ % \CSes are yet \incs{relax} so we may put them in
+ % an \incs{edef} safely.\ilrr
+ \fi
+ \fi}% of \cs{edef}
+ \ifx\gmu@thou@putter #2% if we are at end of the digits…
+ \edef\gmu@tempa{%
+ \ifcase\@tempcnta
+ \gmu@thou@o\or\gmu@thou@i\or\gmu@thou@ii
+ \fi}%
+ \@xa\let\gmu@tempa\gmu@thousep% … we set the proper \CS…
+ \else% or …
+ \afterfi{% iterate.
+ \gmu@thou@putter#2}% of \cs{afterfi}
+ \fi% of if end of digits.
+}% of \cs{gmu@thou@putter}.
+
+\def\gmu@thousep{\,}% in Polish the recommended thousand separator is
+
+\pdef\xathousep#1{\@xa\thousep\@xa{\the#1}}
+
+\def\shortthousep{%
+ \DeclareCommand\thous{
+ D {\NoValue} % decimal argument
+ }{%
+ % we declare it as a command with Q-type argument to allow spaces
+ % between digits.
+ \ifmmode\hbox\bgroup\@gmu@mmhboxtrue\fi
+ \IfValueTF{##1}{% we are given a sequence of digits
+ \@tempcnta=##1\relax
+ \ifnum\@tempcnta<0 $-$%
+ \@tempcnta=-\@tempcnta
+ \fi
+ \xathousep\@tempcnta
+ \if@gmu@mmhbox\egroup
+ \else\@xa\spifletter
+ \fi
+ }%
+ {% no bare digits given, then we assume the argument is braced.
+ \thousep
+ }%
+ }% of |\thous|.
+}% of |\shortthousep|.
+
+
+\DeclareCommand\ATfootnotes{s}{% \chgs{2008/11/29 v0.98 moved here
+ % from my own private macro package to allow the beauty of these
+ % footnotes for the general audience}
+ % \stanza
+ % We make the footnote mark in the footnote |\scriptsize| not
+ % |\scriptscriptsize|.\nostanza
+ \IfValueT{#1}% the following setting is suitable for old style
+ % numbers in footnote marks, therefore I~place it in the starred
+ % version of the command.
+ {\prependtomacro\gmu@ATfootnotes{%
+ \pdef\@makefnmark{%
+ \mbox {\normalfont \textsuperscript {\smaller[3]\@thefnmark }}}%
+ }% of prepend,
+ }% of |\IfValueT|.
+ %
+ \gmu@ATfootnotes
+ \gmu@AT@ampulex\maketitle% without \pk{hyperref}
+ \ifdefined\HyOrg@maketitle
+ \afterfi{\gmu@AT@ampulex\HyOrg@maketitle}% with \pk{hyperref}
+ \fi
+}
+
+\pdef\gmu@AT@ampulex#1{%
+ \typeout{@@@@@^^J^^J\@nx#1^^J^^J%
+ @@@@ meaning:^^J\meaning#1%
+ }%
+ \ampulexdef#1{\def\@makefnmark}%
+ \if@twocolumn
+ {\gmu@ATfootnotes\if@twocolumn}% Ampulex redefinition of
+ % \incs{maketitle} for the standard classes.
+ \ampulexdef#1{\long\def\@makefntext}%
+ \if@twocolumn{\gmu@ATfootnotes\if@twocolumn}% Ampulex redefinition
+ % of \incs{maketitle} for \pk{mwcls}.
+}
+
+\pdef\gmu@ATfootnotes{%
+ % And we make the footnote number not be in superscript but on the
+ % base line, according to Andrzej Tomaszewski's suggestion on
+ % Bacho\TeX\ 2008, and the same size as in the footnote mark.\nostanza
+ \long\pdef\@makefntext##1{%
+ \ifdefined\@parindent \parindent\@parindent
+ \else \parindent 1em\relax
+ \fi
+ \indent{\ATf@font\scriptsize% ^^A \hphantom{19}\llap
+ {\@thefnmark}}%
+ \gmu@fnhook
+ \enspace\ignorespaces##1}%
+}
+
+\let\ATf@font\normalfont
+
+\emptify\gmu@fnhook
+
+
+\pdef\rrthis{% ‘rag right this’: make only the current paragraph
+ % ragged right (e.g.\ if the paragraph consists of a~long \ac{URL}).
+ % \chgs{2008/12/01 v0.98 added}
+ \begingroup\rightskip=0sp plus \hsize \endgraf\endgroup}
+
+\pdef\centerthis{% 2009/12/15
+ \begingroup
+ \rightskip=1\rightskip plus \hsize
+ \leftskip=1\leftskip plus\hsize
+ \parfillskip=\z@skip
+ \endgraf\endgroup}
+
+
+\def\TrzaskaTilde{%
+ \@xa\DeclareCommand\@xa\gmu@smarttilde
+ \@xa{\@xa T\@xa{\all@stars~}}{%
+ \IfValueTF{##1}{\nobreakspace{}}%
+ {\ifdim\dimexpr\hsize-\leftskip-\rightskip
+ -\ifdim\hangindent<\z@-\fi\hangindent % the last
+ % parameter is used with respect to the \pk{floatflt} package.
+ >%
+ \ifdim\f@size pt>\dimexpr10pt-1sp\relax
+ 168dd
+ \else
+ 144dd
+ \fi
+ \nobreakspace {}%
+ \else
+ \ %
+ \fi
+ }% of |\gmu@ifstar|'s else,
+ }% of |\gmu@smarttilde|,
+ \let~\gmu@smarttilde
+}% of |\TrzaskaTilde|.
+
+
+\newcommand{\clearemptydoublepage}{%
+ \newpage{\pagestyle{empty}\cleardoublepage}}
+
+\foone\obeylines{%
+ \def\disobeylines{% for arguments in which line end is active to
+ % simulate normal behaviour
+ \ifnum\catcode`\^^M=\active%
+ \pdef^^M{\@ifnextgroup{\ifhmode\unskip\space\fi}{\gmu@disMinner}}%
+ \def\gmu@disMinner##1{%
+ \ifx^^M##1\endgraf%
+ \else\afterfi{\ifhmode\unskip\space\fi}\fi##1}%
+ \fi}%
+}
+
+
+\DeclareCommand\*{Q{0123456789}{1}}
+{\gmu@flexhyphen
+ \gmu@star@loop0{#1}\relax
+}%
+
+\def\gmu@star@loop#1#2{% this is an expandable loop as in The
+ % \eTeX\ Manual p.~9.
+ \ifnum#1<\numexpr#2\relax%
+ \gmu@lowstar
+ \gmu@flexhyphen
+ \@xa\gmu@star@loop
+ \@xa{\number\numexpr#1+1\@xa}%
+ \@xa{\number#2\@xa}%
+ \fi}
+
+\ifdefined\XeTeXversion
+
+\foone{%
+ \catcode`„\active
+ \catcode`”\active
+ \catcode`’\active
+ \catcode`—\active
+ \catcode`–\active
+}{%
+ \def\activequotes{%
+ \incsdef„{}{\@ifnextchar—%
+ {\lv\llap{\string„}\pauzadial}{\string„}}%
+ \incsdef”{}{\string”\@ifnextanyRS{.,}{\quotkern}{}}%
+ \incsdef’{}{\string’\@ifnextanyRS{.,}{\quotkern}{}}%
+ \catcode`„\active
+ \catcode`”\active
+ }%
+ \def\activepunctsQ {„”’—–}%
+}
+
+\catcode`ѥ\active
+
+\DeclareCommand\ac {b} {%
+ \IfValueTF{#1}
+ {%
+ \acro{#1}%
+ }
+ {\ac@u}%
+}
+
+\def\ac@kernel#1{{\gmu@acrokernel {#1}}}% |#1| in braces because |\acrocore|
+ % valid in \ty{Dzienniczek} uses
+ % |\lowercase| (that requires braced text).
+
+
+\@xa\def\@xa\@dc@basicdelims\@xa{%
+ \two@Ms \par \relax
+ \bgroup
+ \egroup \begingroup \endgroup
+ \begin \end
+ $% ^^A$
+ \(\)\[\]% other math delims
+ &\\% tabular delims
+}
+
+\let\@dc@basicdelimsp\@dc@basicdelims
+
+\@xa\addtomacro\@xa\@dc@basicdelimsp
+\@xa{\all@spaces}
+
+\@xa\def\@xa\@dc@punctanddelims
+\@xa{\@dc@basicdelims :,.;?!„”«»‹›"'`‘’}%
+
+\let \@dc@acpunctanddelims \@dc@punctanddelims
+
+\@xa\addtomacro\@xa\@dc@acpunctanddelims
+\@xa{\activepunctsQ}
+
+\let \@dc@acpunctanddelimsp \@dc@punctanddelims
+
+\@xa\addtomacro\@xa\@dc@acpunctanddelimsp
+\@xa{\all@spaces}
+
+\addtomacro\@dc@acpunctanddelimsp{~}
+
+\DeclareCommand\ac@u{
+ >\@xa U{\@dc@acpunctanddelimsp ()[]<>ѥ} \default{}
+ \eacher {\ac@kernel}
+ >iW{ѥ}
+}
+{\text{#1}}
+
+\fi % of if \XeTeX\ of l.~\ref{12322}.
+
+\@namedef{enumerate*}{%
+ \ifnum\@enumdepth>\thr@@
+ \@toodeep
+ \else
+ \advance\@enumdepth\@ne
+ \edef\@enumctr{enum\romannumeral\the\@enumdepth}%
+ \@xa\list\csname label\@enumctr\endcsname{%
+ \partopsep\topsep \topsep\z@ \leftmargin\z@
+ \itemindent\@parindent %|%\advance\itemindent\labelsep|
+ \labelwidth\@parindent
+ \advance\labelwidth-\labelsep
+ \listparindent\@parindent
+ \usecounter \@enumctr
+ \def\makelabel##1{##1\hfil}}%
+ \fi}
+\@namedef{endenumerate*}{\endlist}
+
+\@namedef{itemize*}{%
+ \ifnum\@itemdepth>\thr@@
+ \@toodeep
+ \else
+ \advance\@itemdepth\@ne
+ \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}%
+ \@xa\list\csname\@itemitem\endcsname{%
+ \partopsep\topsep \topsep\z@ \leftmargin\z@
+ \itemindent\@parindent
+ \labelwidth\@parindent
+ \advance\labelwidth-\labelsep
+ \listparindent\@parindent
+ \def\makelabel##1{##1\hfil }}%
+ \fi}
+\@namedef{enditemize*}{\endlist}
+
+%%% (For my GNU Emacs:)
+%%% Local Variables:
+%%% mode: doctex
+%%% coding: utf-8
+%%% End:
+\endinput
+%%
+%% End of file `gmtypos.sty'.