summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-09-26 21:49:25 +0000
committerKarl Berry <karl@freefriends.org>2019-09-26 21:49:25 +0000
commit6b5aee18d53170454bf65845519f0bd0345c0788 (patch)
treed8a116d5578a4a388825649e8c4e0dcd71c4b455
parentdf42b39352bb8ffd623c43a39225b9d869e698e3 (diff)
unicode-math (26sep19)
git-svn-id: svn://tug.org/texlive/trunk@52185 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/CHANGES.md9
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/README.md2
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/um-doc-main.tex8
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/unicode-math-code.pdfbin332100 -> 323520 bytes
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdfbin162882 -> 162731 bytes
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/unimath-example.pdfbin22157 -> 22002 bytes
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdfbin1203926 -> 1208308 bytes
-rw-r--r--Master/texmf-dist/source/latex/unicode-math/um-code-amsmath.dtx57
-rw-r--r--Master/texmf-dist/source/latex/unicode-math/um-code-compat.dtx138
-rw-r--r--Master/texmf-dist/source/latex/unicode-math/um-code-opening.dtx17
-rw-r--r--Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx6
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math/unicode-math-luatex.sty119
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty155
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty2
14 files changed, 131 insertions, 382 deletions
diff --git a/Master/texmf-dist/doc/latex/unicode-math/CHANGES.md b/Master/texmf-dist/doc/latex/unicode-math/CHANGES.md
index ffe61e18a88..01dcd8a4627 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/CHANGES.md
+++ b/Master/texmf-dist/doc/latex/unicode-math/CHANGES.md
@@ -1,6 +1,15 @@
CHANGE HISTORY
==============
+## v0.8p (2019/09/26)
+
+ * Remove dependency on `filehook` package. Just to simplify.
+ * Remove patch code for the `colonequals` package; now if you use that package
+ you will simply receive its standard ‘constructed’ symbols.
+ * Load `amsmath` automatically. This is not intended to save time for the user,
+ but to simplify the code logic. Users should continue to load `amsmath` explicitly IMO.
+
+
## v0.8o (2019/03/04)
* Avoid `'Dimension too large' error` for some (unpredictable) combinations of font
diff --git a/Master/texmf-dist/doc/latex/unicode-math/README.md b/Master/texmf-dist/doc/latex/unicode-math/README.md
index 7208d667998..12e0d1157a2 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/README.md
+++ b/Master/texmf-dist/doc/latex/unicode-math/README.md
@@ -76,7 +76,7 @@ REQUIREMENTS
------------
As well as running XeTeX or LuaTeX, this package requires recent versions of the
-`lm-math`, `fontspec`, `expl3`, `xpackages`, `filehook`, and `lualatex-math` packages.
+`lm-math`, `fontspec`, `expl3`, `xpackages`, and `lualatex-math` packages.
THANKS
diff --git a/Master/texmf-dist/doc/latex/unicode-math/um-doc-main.tex b/Master/texmf-dist/doc/latex/unicode-math/um-doc-main.tex
index 8ecc8357e7a..5c0bc22ed12 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/um-doc-main.tex
+++ b/Master/texmf-dist/doc/latex/unicode-math/um-doc-main.tex
@@ -69,7 +69,7 @@ Load \pkg{unicode-math} as a regular \LaTeX\ package. It should be loaded
after any other maths or font-related package in case it needs to overwrite
their definitions. Here's an example using the filename syntax to load the \TeX\ Gyre Pagella Math font: (this works for both \XeLaTeX\ and \LuaLaTeX)
\begin{Verbatim}
-\usepackage{amsmath} % if desired
+\usepackage{amsmath}
\usepackage{unicode-math}
\setmathfont{texgyrepagella-math.otf}
\end{Verbatim}
@@ -78,6 +78,10 @@ Once the package is loaded, traditional TFM-based maths fonts are no longer supp
you can only switch to a different OpenType maths font using the \cs{setmathfont} command.
If you do not load an OpenType maths font before |\begin{document}|, Latin Modern Math will be loaded automatically.
+Note that \pkg{amsmath} should be loaded before \pkg{unicode-math} to avoid conflicts, and
+it will be loaded automatically if not requested earlier in the preamble.
+
+
\subsection{New commands}
\LaTeX, since the first version of \LaTeXe, changed the math group
selection from, say, |{\bf x}| to |\mathbf{x}|. It introduced commands
@@ -111,7 +115,7 @@ the two meanings with a command like |\mathbf| for the boldface text font
in math and a command like |\symbf| (for the bold math font).
The five new symbol font commands that behave in this way are: \cs{symup},
-\cs{symit}, \cs{symbf}, \cs{symsf}, and \cs{symit}.
+\cs{symit}, \cs{symbf}, \cs{symsf}, and \cs{symtt}.
These commands switch to single-letter mathematical symbols
(generally within the same OpenType font).
diff --git a/Master/texmf-dist/doc/latex/unicode-math/unicode-math-code.pdf b/Master/texmf-dist/doc/latex/unicode-math/unicode-math-code.pdf
index bf0ca20ed5d..c251d66a182 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/unicode-math-code.pdf
+++ b/Master/texmf-dist/doc/latex/unicode-math/unicode-math-code.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf b/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf
index 05d2817a78c..41da2850e61 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf
+++ b/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/unicode-math/unimath-example.pdf b/Master/texmf-dist/doc/latex/unicode-math/unimath-example.pdf
index 82fdbee8f9f..315e19f2683 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/unimath-example.pdf
+++ b/Master/texmf-dist/doc/latex/unicode-math/unimath-example.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf b/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf
index dcb99c16db5..bd55866e6bb 100644
--- a/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf
+++ b/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/unicode-math/um-code-amsmath.dtx b/Master/texmf-dist/source/latex/unicode-math/um-code-amsmath.dtx
index bc782ba88c4..ee1f0642bc4 100644
--- a/Master/texmf-dist/source/latex/unicode-math/um-code-amsmath.dtx
+++ b/Master/texmf-dist/source/latex/unicode-math/um-code-amsmath.dtx
@@ -9,8 +9,6 @@
%
% Since the mathcode of |`\-| is greater than eight bits, this piece of |\AtBeginDocument| code from \pkg{amsmath} dies if we try and set the maths font in the preamble:
% \begin{macrocode}
-\AtEndOfPackageFile * {amsmath}
- {
\tl_remove_once:Nn \@begindocumenthook
{
\mathchardef\std@minus\mathcode`\-\relax
@@ -38,24 +36,7 @@
% \end{macrocode}
% The |subarray| environment uses inappropriate font dimensions.
% \begin{macrocode}
- \@@_check_and_fix:NNnnn \subarray \cs_set:Npn { #1 }
- {
- \vcenter
- \bgroup
- \Let@
- \restore@math@cr
- \default@tag
- \baselineskip \fontdimen 10~ \scriptfont \tw@
- \advance \baselineskip \fontdimen 12~ \scriptfont \tw@
- \lineskip \thr@@@@ \fontdimen 8~ \scriptfont \thr@@@@
- \lineskiplimit \lineskip
- \ialign
- \bgroup
- \ifx c #1 \hfil \fi
- $ \m@th \scriptstyle ## $
- \hfil
- \crcr
- }
+ \cs_set:Npn \subarray #1
{
\vcenter
\c_group_begin_token
@@ -64,15 +45,9 @@
\default@tag
\skip_set:Nn \baselineskip
{
-% \end{macrocode}
-% Here we use stack top shift + stack bottom shift, which sounds reasonable.
-% \begin{macrocode}
\@@_stack_num_up:N \scriptstyle
+ \@@_stack_denom_down:N \scriptstyle
}
-% \end{macrocode}
-% Here we use the minimum stack gap.
-% \begin{macrocode}
\lineskip \@@_stack_vgap:N \scriptstyle
\lineskiplimit \lineskip
\ialign
@@ -91,19 +66,7 @@
% The roots need a complete rework.
% \begin{macrocode}
%<*LU>
- \@@_check_and_fix:NNnnn \plainroot@ \cs_set_nopar:Npn { #1 \of #2 }
- {
- \setbox \rootbox \hbox
- {
- $ \m@th \scriptscriptstyle { #1 } $
- }
- \mathchoice
- { \r@@@@t \displaystyle { #2 } }
- { \r@@@@t \textstyle { #2 } }~
- { \r@@@@t \scriptstyle { #2 } }
- { \r@@@@t \scriptscriptstyle { #2 } }
- \egroup
- }
+ \cs_set_nopar:Npn \plainroot@ #1 \of #2
{
\bool_if:nTF
{
@@ -131,20 +94,7 @@
% \end{macrocode}
%
% \begin{macrocode}
- \@@_check_and_fix:NNnnn \r@@@@t \cs_set_nopar:Npn { #1 #2 }
- {
- \setboxz@h { $ \m@th #1 \sqrtsign { #2 } $ }
- \dimen@ \ht\z@
- \advance \dimen@ -\dp\z@
- \setbox\@ne \hbox { $ \m@th #1 \mskip \uproot@ mu $ }
- \advance \dimen@ by 1.667 \wd\@ne
- \mkern -\leftroot@ mu
- \mkern 5mu
- \raise .6\dimen@ \copy\rootbox
- \mkern -10mu
- \mkern \leftroot@ mu
- \boxz@
- }
+ \cs_set_nopar:Npn \r@@@@t #1 #2
%<*LU>
{
\hbox_set:Nn \l_tmpa_box
@@ -197,7 +147,6 @@
\box_use_drop:N \l_tmpa_box
}
%</XE>
- }
% \end{macrocode}
%
% \begin{macrocode}
diff --git a/Master/texmf-dist/source/latex/unicode-math/um-code-compat.dtx b/Master/texmf-dist/source/latex/unicode-math/um-code-compat.dtx
index a5f05c81b39..72ce5186da1 100644
--- a/Master/texmf-dist/source/latex/unicode-math/um-code-compat.dtx
+++ b/Master/texmf-dist/source/latex/unicode-math/um-code-compat.dtx
@@ -7,47 +7,6 @@
%<*package>
% \end{macrocode}
%
-% \begin{macro}{\@@_check_and_fix:NNnnn}
-% \darg{command}
-% \darg{factory command}
-% \darg{parameter text}
-% \darg{expected replacement text}
-% \darg{new replacement text}
-% Tries to patch \meta{command}.
-% If \meta{command} is undefined, do nothing.
-% Otherwise it must be a macro with the given \meta{parameter text} and \meta{expected replacement text}, created by the given \meta{factory command} or equivalent.
-% In this case it will be overwritten using the \meta{parameter text} and the \meta{new replacement text for \LuaTeX} or the \meta{new replacement text for \XeTeX}, depending on the engine.
-% Otherwise issue a warning and don’t overwrite.
-% \begin{macrocode}
-\cs_new_protected_nopar:Nn \@@_check_and_fix:NNnnn
- {
- \cs_if_exist:NT #1
- {
- \token_if_macro:NTF #1
- {
- \group_begin:
- #2 \@@_tmpa:w #3 { #4 }
- \cs_if_eq:NNTF #1 \@@_tmpa:w
- {
- \msg_info:nnx { unicode-math } { patch-macro } { \token_to_str:N #1 }
- \group_end:
- #2 #1 #3 { #5 }
- }
- {
- \msg_warning:nnxxx { unicode-math } { wrong-meaning }
- { \token_to_str:N #1 } { \token_to_meaning:N #1 }
- { \token_to_meaning:N \@@_tmpa:w }
- \group_end:
- }
- }
- {
- \msg_warning:nnx { unicode-math } { macro-expected }
- { \token_to_str:N #1 }
- }
- }
- }
-% \end{macrocode}
-% \end{macro}
%
% \section{Patching/augmenting 3rd-party packages}
%
@@ -60,7 +19,7 @@
% but activates automatically so documents that might change the \cs{url}
% font through the standard interface still work correctly.
% \begin{macrocode}
-\AtEndOfPackageFile * {url}
+\@@_after_package:nNn {url} \@@_patch_url:
{
\tl_put_left:Nn \Url@FormatString { \@@_switch_to:n {literal} }
\tl_put_right:Nn \UrlSpecials
@@ -84,43 +43,21 @@
% upsetting effect on legacy math alphabets.
% \begin{macrocode}
%<*XE>
-\AtEndOfPackageFile * { mathtools }
+\@@_after_package:nNn { mathtools } \@@_patch_mathtools_A:
{
- \@@_check_and_fix:NNnnn \MT_cramped_internal:Nn \cs_set_nopar:Npn { #1 #2 }
- {
- \sbox \z@ { $ \m@th #1 \nulldelimiterspace = \z@ \radical \z@ { #2 } $ }
- \ifx #1 \displaystyle
- \dimen@ = \fontdimen 8 \textfont 3
- \advance \dimen@ .25 \fontdimen 5 \textfont 2
- \else
- \dimen@ = 1.25 \fontdimen 8
- \ifx #1 \textstyle
- \textfont
- \else
- \ifx #1 \scriptstyle
- \scriptfont
- \else
- \scriptscriptfont
- \fi
- \fi
- 3
- \fi
- \advance \dimen@ -\ht\z@
- \ht\z@ = -\dimen@
- \box\z@
- }
+ \cs_set_nopar:Npn \MT_cramped_internal:Nn ##1 ##2
{
\hbox_set:Nn \l_tmpa_box
{
\color@setgroup \c_math_toggle_token \m@th
- #1
+ ##1
\dim_zero:N \nulldelimiterspace
- \XeTeXradical 255 ~ 0 ~ { #2 }
+ \XeTeXradical 255 ~ 0 ~ { ##2 }
\c_math_toggle_token \color@endgroup
}
\box_set_ht:Nn \l_tmpa_box
{
- \box_ht:N \l_tmpa_box - \@@_radical_vgap:N #1
+ \box_ht:N \l_tmpa_box - \@@_radical_vgap:N ##1
}
\box_use_drop:N \l_tmpa_box
}
@@ -138,7 +75,7 @@
% with Unicode fonts, so we are hard coding the $5/18$ex suggested by
% \pkg{mathtools}’s documentation.
% \begin{macrocode}
-\AtEndOfPackageFile * { mathtools }
+\@@_after_package:nNn { mathtools } \@@_patch_mathtools_B:
{
\cs_set_eq:NN \MToverbracket \overbracket
\cs_set_eq:NN \MTunderbracket \underbracket
@@ -147,20 +84,20 @@
{
\msg_warning:nn { unicode-math } { mathtools-overbracket }
- \cs_set:Npn \downbracketfill #1 #2
+ \cs_set:Npn \downbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \downbracketend {#1} {#2}
- \leaders \vrule \@height #1 \@depth \z@ \hfill
- \downbracketend {#1} {#2}
+ \downbracketend {##1} {##2}
+ \leaders \vrule \@height ##1 \@depth \z@ \hfill
+ \downbracketend {##1} {##2}
}
- \cs_set:Npn \upbracketfill #1 #2
+ \cs_set:Npn \upbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \upbracketend {#1} {#2}
- \leaders \vrule \@height \z@ \@depth #1 \hfill
- \upbracketend {#1} {#2}
+ \upbracketend {##1} {##2}
+ \leaders \vrule \@height \z@ \@depth ##1 \hfill
+ \upbracketend {##1} {##2}
}
\cs_set_eq:NN \Uoverbracket \overbracket
@@ -179,53 +116,22 @@
% \begin{macro}{\eqqcolon}
% \pkg{mathtools} defines several commands as combinations of colons and
% other characters, but with meanings incompatible to \pkg{unicode-math}.
-% Thus we issue a warning. Because \pkg{mathtools} uses
-% \cmd{\providecommand} \cmd{\AtBeginDocument}, we can just define the
-% offending commands here.
+% Thus we issue a warning. Note \pkg{mathtools} uses
+% \cmd{\providecommand} \cmd{\AtBeginDocument}.
% \begin{macrocode}
-\AtEndOfPackageFile * { mathtools }
+\@@_after_package:nNn { mathtools } \@@_patch_mathtools_C:
{
\msg_warning:nn { unicode-math } { mathtools-colon }
- \NewDocumentCommand \dblcolon { } { \Colon }
- \NewDocumentCommand \coloneqq { } { \coloneq }
- \NewDocumentCommand \Coloneqq { } { \Coloneq }
- \NewDocumentCommand \eqqcolon { } { \eqcolon }
- }
-% \end{macrocode}
-% \end{macro}
-% \end{macro}
-% \end{macro}
-% \end{macro}
-%
-% \subsection{\pkg{colonequals}}
-%
-% \begin{macro}{\ratio}
-% \begin{macro}{\coloncolon}
-% \begin{macro}{\minuscolon}
-% \begin{macro}{\colonequals}
-% \begin{macro}{\equalscolon}
-% \begin{macro}{\coloncolonequals}
-% Similarly to \pkg{mathtools}, the \pkg{colonequals} defines several colon
-% combinations. Fortunately there are no name clashes, so we can just
-% overwrite their definitions.
-% \begin{macrocode}
-\AtEndOfPackageFile * { colonequals }
- {
- \msg_warning:nn { unicode-math } { colonequals }
- \RenewDocumentCommand \ratio { } { \mathratio }
- \RenewDocumentCommand \coloncolon { } { \Colon }
- \RenewDocumentCommand \minuscolon { } { \dashcolon }
- \RenewDocumentCommand \colonequals { } { \coloneq }
- \RenewDocumentCommand \equalscolon { } { \eqcolon }
- \RenewDocumentCommand \coloncolonequals { } { \Coloneq }
+ \DeclareDocumentCommand \dblcolon { } { \Colon }
+ \DeclareDocumentCommand \coloneqq { } { \coloneq }
+ \DeclareDocumentCommand \Coloneqq { } { \Coloneq }
+ \DeclareDocumentCommand \eqqcolon { } { \eqcolon }
}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
-% \end{macro}
-% \end{macro}
%
% \begin{macrocode}
%</package>
diff --git a/Master/texmf-dist/source/latex/unicode-math/um-code-opening.dtx b/Master/texmf-dist/source/latex/unicode-math/um-code-opening.dtx
index b739fa6deae..16e3213998d 100644
--- a/Master/texmf-dist/source/latex/unicode-math/um-code-opening.dtx
+++ b/Master/texmf-dist/source/latex/unicode-math/um-code-opening.dtx
@@ -17,7 +17,22 @@
% \begin{macrocode}
\RequirePackage{xparse,l3keys2e}
\RequirePackage{fontspec}
-\RequirePackage{filehook}
+\RequirePackage{fix-cm}
+\RequirePackage{amsmath}
+%<LU>\RequirePackage{lualatex-math}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\cs_set_protected:Npn \@@_after_package:nNn #1 #2 #3
+ {
+ \AtBeginDocument
+ {
+ \cs_new_protected:Npn #2 {#3}
+ \@ifpackageloaded {#1} {#2} {}
+ }
+ }
+\RequirePackage{xparse,l3keys2e}
+\RequirePackage{fontspec}
\RequirePackage{fix-cm}
%<LU>\RequirePackage{lualatex-math}
% \end{macrocode}
diff --git a/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx b/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx
index 59cf98b1885..3aee6d530b0 100644
--- a/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx
+++ b/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx
@@ -60,15 +60,15 @@
%<base>\ProvidesExplPackage{unicode-math}
%<package&XE>\ProvidesExplPackage{unicode-math-xetex}
%<package&LU>\ProvidesExplPackage{unicode-math-luatex}
-%<base|package> {2019/03/04} {0.8o} {Unicode maths in XeLaTeX and LuaLaTeX}
+%<base|package> {2019/09/26} {0.8p} {Unicode maths in XeLaTeX and LuaLaTeX}
% \end{macrocode}
%
% Here the version and date are setup for typesetting the documentation.
% \begin{macrocode}
%<*dtx>
\date{
- \def\filedate{2019/03/04}
- \def\fileversion{0.8o}
+ \def\filedate{2019/09/26}
+ \def\fileversion{0.8p}
\filedate \qquad \fileversion
}
%</dtx>
diff --git a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-luatex.sty b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-luatex.sty
index 1da955739d6..15c2acd6122 100644
--- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-luatex.sty
+++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-luatex.sty
@@ -43,14 +43,26 @@
%%^^A%% Metadata for the package code, including files and versioning
\ProvidesExplPackage{unicode-math-luatex}
- {2019/03/04} {0.8o} {Unicode maths in XeLaTeX and LuaLaTeX}
+ {2019/09/26} {0.8p} {Unicode maths in XeLaTeX and LuaLaTeX}
%%^^A%% um-code-opening.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Assorted initialisation tasks, including some low-level function definitions.
\RequirePackage{xparse,l3keys2e}
\RequirePackage{fontspec}
-\RequirePackage{filehook}
+\RequirePackage{fix-cm}
+\RequirePackage{amsmath}
+\RequirePackage{lualatex-math}
+\cs_set_protected:Npn \__um_after_package:nNn #1 #2 #3
+ {
+ \AtBeginDocument
+ {
+ \cs_new_protected:Npn #2 {#3}
+ \@ifpackageloaded {#1} {#2} {}
+ }
+ }
+\RequirePackage{xparse,l3keys2e}
+\RequirePackage{fontspec}
\RequirePackage{fix-cm}
\RequirePackage{lualatex-math}
\cs_set_protected_nopar:Npn \exp_last_unbraced:NNx { \::N \::x_unbraced \::: }
@@ -672,13 +684,13 @@
}
\__um_msg_new:nn {no-main-font}
{
- No main maths font has been set up yet.\\If you simply want ^^e2^^80^^98the default^^e2^^80^^99, use: \\
+ No main maths font has been set up yet.\\If you simply want ‘the default’, use: \\
\iow_indent:n {\token_to_str:N\setmathfont{latinmodern-math.otf}}
}
\__um_msg_new:nn {not-ot-math}
{
The first font loaded by unicode-math must be an OpenType Math font (with script=math).
- If you simply want ^^e2^^80^^98the default^^e2^^80^^99 before loading supplementary fonts over the top for certain
+ If you simply want ‘the default’ before loading supplementary fonts over the top for certain
ranges, use: \\
\iow_indent:n {\token_to_str:N\setmathfont{latinmodern-math.otf}}
}
@@ -3626,34 +3638,7 @@
%%^^A%% um-code-compat.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Compatibility with 3rd party packages.
-\cs_new_protected_nopar:Nn \__um_check_and_fix:NNnnn
- {
- \cs_if_exist:NT #1
- {
- \token_if_macro:NTF #1
- {
- \group_begin:
- #2 \__um_tmpa:w #3 { #4 }
- \cs_if_eq:NNTF #1 \__um_tmpa:w
- {
- \msg_info:nnx { unicode-math } { patch-macro } { \token_to_str:N #1 }
- \group_end:
- #2 #1 #3 { #5 }
- }
- {
- \msg_warning:nnxxx { unicode-math } { wrong-meaning }
- { \token_to_str:N #1 } { \token_to_meaning:N #1 }
- { \token_to_meaning:N \__um_tmpa:w }
- \group_end:
- }
- }
- {
- \msg_warning:nnx { unicode-math } { macro-expected }
- { \token_to_str:N #1 }
- }
- }
- }
-\AtEndOfPackageFile * {url}
+\__um_after_package:nNn {url} \__um_patch_url:
{
\tl_put_left:Nn \Url@FormatString { \__um_switch_to:n {literal} }
\tl_put_right:Nn \UrlSpecials
@@ -3664,7 +3649,7 @@
\do \& { \mathchar`\& }
}
}
-\AtEndOfPackageFile * { mathtools }
+\__um_after_package:nNn { mathtools } \__um_patch_mathtools_B:
{
\cs_set_eq:NN \MToverbracket \overbracket
\cs_set_eq:NN \MTunderbracket \underbracket
@@ -3673,20 +3658,20 @@
{
\msg_warning:nn { unicode-math } { mathtools-overbracket }
- \cs_set:Npn \downbracketfill #1 #2
+ \cs_set:Npn \downbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \downbracketend {#1} {#2}
- \leaders \vrule \@height #1 \@depth \z@ \hfill
- \downbracketend {#1} {#2}
+ \downbracketend {##1} {##2}
+ \leaders \vrule \@height ##1 \@depth \z@ \hfill
+ \downbracketend {##1} {##2}
}
- \cs_set:Npn \upbracketfill #1 #2
+ \cs_set:Npn \upbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \upbracketend {#1} {#2}
- \leaders \vrule \@height \z@ \@depth #1 \hfill
- \upbracketend {#1} {#2}
+ \upbracketend {##1} {##2}
+ \leaders \vrule \@height \z@ \@depth ##1 \hfill
+ \upbracketend {##1} {##2}
}
\cs_set_eq:NN \Uoverbracket \overbracket
@@ -3695,30 +3680,18 @@
\cs_set_eq:NN \underbracket \MTunderbracket
}
}
-\AtEndOfPackageFile * { mathtools }
+\__um_after_package:nNn { mathtools } \__um_patch_mathtools_C:
{
\msg_warning:nn { unicode-math } { mathtools-colon }
- \NewDocumentCommand \dblcolon { } { \Colon }
- \NewDocumentCommand \coloneqq { } { \coloneq }
- \NewDocumentCommand \Coloneqq { } { \Coloneq }
- \NewDocumentCommand \eqqcolon { } { \eqcolon }
- }
-\AtEndOfPackageFile * { colonequals }
- {
- \msg_warning:nn { unicode-math } { colonequals }
- \RenewDocumentCommand \ratio { } { \mathratio }
- \RenewDocumentCommand \coloncolon { } { \Colon }
- \RenewDocumentCommand \minuscolon { } { \dashcolon }
- \RenewDocumentCommand \colonequals { } { \coloneq }
- \RenewDocumentCommand \equalscolon { } { \eqcolon }
- \RenewDocumentCommand \coloncolonequals { } { \Coloneq }
+ \DeclareDocumentCommand \dblcolon { } { \Colon }
+ \DeclareDocumentCommand \coloneqq { } { \coloneq }
+ \DeclareDocumentCommand \Coloneqq { } { \Coloneq }
+ \DeclareDocumentCommand \eqqcolon { } { \eqcolon }
}
%%^^A%% um-code-amsmath.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Compatibility with amsmath.
-\AtEndOfPackageFile * {amsmath}
- {
\tl_remove_once:Nn \@begindocumenthook
{
\mathchardef\std@minus\mathcode`\-\relax
@@ -3731,19 +3704,7 @@
}
\cs_set:Npn \@cdots {\mathinner{\unicodecdots}}
\cs_set_eq:NN \dotsb@ \cdots
- \__um_check_and_fix:NNnnn \plainroot@ \cs_set_nopar:Npn { #1 \of #2 }
- {
- \setbox \rootbox \hbox
- {
- $ \m@th \scriptscriptstyle { #1 } $
- }
- \mathchoice
- { \r@@t \displaystyle { #2 } }
- { \r@@t \textstyle { #2 } }~
- { \r@@t \scriptstyle { #2 } }
- { \r@@t \scriptscriptstyle { #2 } }
- \egroup
- }
+ \cs_set_nopar:Npn \plainroot@ #1 \of #2
{
\bool_if:nTF
{
@@ -3767,20 +3728,7 @@
}
\c_group_end_token
}
- \__um_check_and_fix:NNnnn \r@@t \cs_set_nopar:Npn { #1 #2 }
- {
- \setboxz@h { $ \m@th #1 \sqrtsign { #2 } $ }
- \dimen@ \ht\z@
- \advance \dimen@ -\dp\z@
- \setbox\@ne \hbox { $ \m@th #1 \mskip \uproot@ mu $ }
- \advance \dimen@ by 1.667 \wd\@ne
- \mkern -\leftroot@ mu
- \mkern 5mu
- \raise .6\dimen@ \copy\rootbox
- \mkern -10mu
- \mkern \leftroot@ mu
- \boxz@
- }
+ \cs_set_nopar:Npn \r@@t #1 #2
{
\hbox_set:Nn \l_tmpa_box
{
@@ -3804,7 +3752,6 @@
}
{ #2 }
}
- }
%%^^A%% um-code-epilogue.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Assorted definitions to close up.
diff --git a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty
index a1461f7a112..ef94a2d76f0 100644
--- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty
+++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math-xetex.sty
@@ -43,14 +43,25 @@
%%^^A%% Metadata for the package code, including files and versioning
\ProvidesExplPackage{unicode-math-xetex}
- {2019/03/04} {0.8o} {Unicode maths in XeLaTeX and LuaLaTeX}
+ {2019/09/26} {0.8p} {Unicode maths in XeLaTeX and LuaLaTeX}
%%^^A%% um-code-opening.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Assorted initialisation tasks, including some low-level function definitions.
\RequirePackage{xparse,l3keys2e}
\RequirePackage{fontspec}
-\RequirePackage{filehook}
+\RequirePackage{fix-cm}
+\RequirePackage{amsmath}
+\cs_set_protected:Npn \__um_after_package:nNn #1 #2 #3
+ {
+ \AtBeginDocument
+ {
+ \cs_new_protected:Npn #2 {#3}
+ \@ifpackageloaded {#1} {#2} {}
+ }
+ }
+\RequirePackage{xparse,l3keys2e}
+\RequirePackage{fontspec}
\RequirePackage{fix-cm}
\cs_set_protected_nopar:Npn \exp_last_unbraced:NNx { \::N \::x_unbraced \::: }
\cs_generate_variant:Nn \fontspec_set_family:Nnn {Nx,Nxx}
@@ -664,13 +675,13 @@
}
\__um_msg_new:nn {no-main-font}
{
- No main maths font has been set up yet.\\If you simply want ^^e2^^80^^98the default^^e2^^80^^99, use: \\
+ No main maths font has been set up yet.\\If you simply want ‘the default’, use: \\
\iow_indent:n {\token_to_str:N\setmathfont{latinmodern-math.otf}}
}
\__um_msg_new:nn {not-ot-math}
{
The first font loaded by unicode-math must be an OpenType Math font (with script=math).
- If you simply want ^^e2^^80^^98the default^^e2^^80^^99 before loading supplementary fonts over the top for certain
+ If you simply want ‘the default’ before loading supplementary fonts over the top for certain
ranges, use: \\
\iow_indent:n {\token_to_str:N\setmathfont{latinmodern-math.otf}}
}
@@ -3555,34 +3566,7 @@
%%^^A%% um-code-compat.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Compatibility with 3rd party packages.
-\cs_new_protected_nopar:Nn \__um_check_and_fix:NNnnn
- {
- \cs_if_exist:NT #1
- {
- \token_if_macro:NTF #1
- {
- \group_begin:
- #2 \__um_tmpa:w #3 { #4 }
- \cs_if_eq:NNTF #1 \__um_tmpa:w
- {
- \msg_info:nnx { unicode-math } { patch-macro } { \token_to_str:N #1 }
- \group_end:
- #2 #1 #3 { #5 }
- }
- {
- \msg_warning:nnxxx { unicode-math } { wrong-meaning }
- { \token_to_str:N #1 } { \token_to_meaning:N #1 }
- { \token_to_meaning:N \__um_tmpa:w }
- \group_end:
- }
- }
- {
- \msg_warning:nnx { unicode-math } { macro-expected }
- { \token_to_str:N #1 }
- }
- }
- }
-\AtEndOfPackageFile * {url}
+\__um_after_package:nNn {url} \__um_patch_url:
{
\tl_put_left:Nn \Url@FormatString { \__um_switch_to:n {literal} }
\tl_put_right:Nn \UrlSpecials
@@ -3593,48 +3577,26 @@
\do \& { \mathchar`\& }
}
}
-\AtEndOfPackageFile * { mathtools }
+\__um_after_package:nNn { mathtools } \__um_patch_mathtools_A:
{
- \__um_check_and_fix:NNnnn \MT_cramped_internal:Nn \cs_set_nopar:Npn { #1 #2 }
- {
- \sbox \z@ { $ \m@th #1 \nulldelimiterspace = \z@ \radical \z@ { #2 } $ }
- \ifx #1 \displaystyle
- \dimen@ = \fontdimen 8 \textfont 3
- \advance \dimen@ .25 \fontdimen 5 \textfont 2
- \else
- \dimen@ = 1.25 \fontdimen 8
- \ifx #1 \textstyle
- \textfont
- \else
- \ifx #1 \scriptstyle
- \scriptfont
- \else
- \scriptscriptfont
- \fi
- \fi
- 3
- \fi
- \advance \dimen@ -\ht\z@
- \ht\z@ = -\dimen@
- \box\z@
- }
+ \cs_set_nopar:Npn \MT_cramped_internal:Nn ##1 ##2
{
\hbox_set:Nn \l_tmpa_box
{
\color@setgroup \c_math_toggle_token \m@th
- #1
+ ##1
\dim_zero:N \nulldelimiterspace
- \XeTeXradical 255 ~ 0 ~ { #2 }
+ \XeTeXradical 255 ~ 0 ~ { ##2 }
\c_math_toggle_token \color@endgroup
}
\box_set_ht:Nn \l_tmpa_box
{
- \box_ht:N \l_tmpa_box - \__um_radical_vgap:N #1
+ \box_ht:N \l_tmpa_box - \__um_radical_vgap:N ##1
}
\box_use_drop:N \l_tmpa_box
}
}
-\AtEndOfPackageFile * { mathtools }
+\__um_after_package:nNn { mathtools } \__um_patch_mathtools_B:
{
\cs_set_eq:NN \MToverbracket \overbracket
\cs_set_eq:NN \MTunderbracket \underbracket
@@ -3643,20 +3605,20 @@
{
\msg_warning:nn { unicode-math } { mathtools-overbracket }
- \cs_set:Npn \downbracketfill #1 #2
+ \cs_set:Npn \downbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \downbracketend {#1} {#2}
- \leaders \vrule \@height #1 \@depth \z@ \hfill
- \downbracketend {#1} {#2}
+ \downbracketend {##1} {##2}
+ \leaders \vrule \@height ##1 \@depth \z@ \hfill
+ \downbracketend {##1} {##2}
}
- \cs_set:Npn \upbracketfill #1 #2
+ \cs_set:Npn \upbracketfill ##1 ##2
{
\tl_set:Nn \l_MT_bracketheight_fdim {.27ex}
- \upbracketend {#1} {#2}
- \leaders \vrule \@height \z@ \@depth #1 \hfill
- \upbracketend {#1} {#2}
+ \upbracketend {##1} {##2}
+ \leaders \vrule \@height \z@ \@depth ##1 \hfill
+ \upbracketend {##1} {##2}
}
\cs_set_eq:NN \Uoverbracket \overbracket
@@ -3665,30 +3627,18 @@
\cs_set_eq:NN \underbracket \MTunderbracket
}
}
-\AtEndOfPackageFile * { mathtools }
+\__um_after_package:nNn { mathtools } \__um_patch_mathtools_C:
{
\msg_warning:nn { unicode-math } { mathtools-colon }
- \NewDocumentCommand \dblcolon { } { \Colon }
- \NewDocumentCommand \coloneqq { } { \coloneq }
- \NewDocumentCommand \Coloneqq { } { \Coloneq }
- \NewDocumentCommand \eqqcolon { } { \eqcolon }
- }
-\AtEndOfPackageFile * { colonequals }
- {
- \msg_warning:nn { unicode-math } { colonequals }
- \RenewDocumentCommand \ratio { } { \mathratio }
- \RenewDocumentCommand \coloncolon { } { \Colon }
- \RenewDocumentCommand \minuscolon { } { \dashcolon }
- \RenewDocumentCommand \colonequals { } { \coloneq }
- \RenewDocumentCommand \equalscolon { } { \eqcolon }
- \RenewDocumentCommand \coloncolonequals { } { \Coloneq }
+ \DeclareDocumentCommand \dblcolon { } { \Colon }
+ \DeclareDocumentCommand \coloneqq { } { \coloneq }
+ \DeclareDocumentCommand \Coloneqq { } { \Coloneq }
+ \DeclareDocumentCommand \eqqcolon { } { \eqcolon }
}
%%^^A%% um-code-amsmath.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Compatibility with amsmath.
-\AtEndOfPackageFile * {amsmath}
- {
\tl_remove_once:Nn \@begindocumenthook
{
\mathchardef\std@minus\mathcode`\-\relax
@@ -3706,24 +3656,7 @@
\setbox\z@\hbox{$($}%)
\ht\Mathstrutbox@\ht\z@ \dp\Mathstrutbox@\dp\z@
}
- \__um_check_and_fix:NNnnn \subarray \cs_set:Npn { #1 }
- {
- \vcenter
- \bgroup
- \Let@
- \restore@math@cr
- \default@tag
- \baselineskip \fontdimen 10~ \scriptfont \tw@
- \advance \baselineskip \fontdimen 12~ \scriptfont \tw@
- \lineskip \thr@@ \fontdimen 8~ \scriptfont \thr@@
- \lineskiplimit \lineskip
- \ialign
- \bgroup
- \ifx c #1 \hfil \fi
- $ \m@th \scriptstyle ## $
- \hfil
- \crcr
- }
+ \cs_set:Npn \subarray #1
{
\vcenter
\c_group_begin_token
@@ -3748,20 +3681,7 @@
\hfil
\crcr
}
- \__um_check_and_fix:NNnnn \r@@t \cs_set_nopar:Npn { #1 #2 }
- {
- \setboxz@h { $ \m@th #1 \sqrtsign { #2 } $ }
- \dimen@ \ht\z@
- \advance \dimen@ -\dp\z@
- \setbox\@ne \hbox { $ \m@th #1 \mskip \uproot@ mu $ }
- \advance \dimen@ by 1.667 \wd\@ne
- \mkern -\leftroot@ mu
- \mkern 5mu
- \raise .6\dimen@ \copy\rootbox
- \mkern -10mu
- \mkern \leftroot@ mu
- \boxz@
- }
+ \cs_set_nopar:Npn \r@@t #1 #2
{
\hbox_set:Nn \l_tmpa_box
{
@@ -3787,7 +3707,6 @@
\mkern \leftroot@ mu
\box_use_drop:N \l_tmpa_box
}
- }
%%^^A%% um-code-epilogue.dtx -- part of UNICODE-MATH <wspr.io/unicode-math>
%%^^A%% Assorted definitions to close up.
diff --git a/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty b/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
index 5e5a1b7f361..26759e8d0a9 100644
--- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
+++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty
@@ -24,7 +24,7 @@
\RequirePackage{expl3}
\ProvidesExplPackage{unicode-math}
- {2019/03/04} {0.8o} {Unicode maths in XeLaTeX and LuaLaTeX}
+ {2019/09/26} {0.8p} {Unicode maths in XeLaTeX and LuaLaTeX}
\sys_if_engine_luatex:T { \RequirePackageWithOptions{unicode-math-luatex} }
\sys_if_engine_xetex:T { \RequirePackageWithOptions{unicode-math-xetex} }
\sys_if_engine_pdftex:T