From ca4208ab5d96c12b345e9ebe3462cb7dfb81591c Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Thu, 10 Sep 2015 20:56:13 +0000 Subject: unicode-math (10sep15) git-svn-id: svn://tug.org/texlive/trunk@38337 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/latex/unicode-math/README | 293 -------------------- Master/texmf-dist/doc/latex/unicode-math/README.md | 294 +++++++++++++++++++++ .../doc/latex/unicode-math/unicode-math.pdf | Bin 386208 -> 386448 bytes .../doc/latex/unicode-math/unimath-symbols.pdf | Bin 1448685 -> 1448683 bytes .../latex/unicode-math/unicode-math-compat.dtx | 4 +- .../source/latex/unicode-math/unicode-math.dtx | 133 +++++----- .../tex/latex/unicode-math/unicode-math-luatex.sty | 47 +--- .../tex/latex/unicode-math/unicode-math-xetex.sty | 38 +-- .../tex/latex/unicode-math/unicode-math.sty | 4 +- 9 files changed, 379 insertions(+), 434 deletions(-) delete mode 100644 Master/texmf-dist/doc/latex/unicode-math/README create mode 100644 Master/texmf-dist/doc/latex/unicode-math/README.md diff --git a/Master/texmf-dist/doc/latex/unicode-math/README b/Master/texmf-dist/doc/latex/unicode-math/README deleted file mode 100644 index 59104c0f330..00000000000 --- a/Master/texmf-dist/doc/latex/unicode-math/README +++ /dev/null @@ -1,293 +0,0 @@ -The UNICODE-MATH package -======================== - -This package will provide a complete implementation of unicode maths for -XeLaTeX and LuaLaTeX. - -While I am a little wary of encouraging people to use this package for -production work, I understand that it has certain uses and am making it -available for distribution. Your testing and feedback is essential to fill -in the many gaps that I miss! - -Please be aware that this package is undergoing continued development and the -interface and functionality should not be considered completely stable. But -the more the package is used the more stable it will become. (Things are -generally working now; it is only minutiae that may change in the future.) - -Unicode maths is currently supported by the fonts - - - [Cambria Math][CM] (Microsoft), - - [Minion Math][MM] (Johannes Küster, typoma GmbH) - - [Latin Modern Math][LM] (Bogusław Jackowski, Janusz M. Nowacki) - - [TeX Gyre Pagella Math][PM] (Bogusław Jackowski, Janusz M. Nowacki) - - [Asana Math][AM] (Apostolos Syropolous), - - [Neo Euler][NE] (Khaled Hosny), - - [STIX][SM] (STI Pub), and - - [XITS Math][XM] (Khaled Hosny). - -With the exception of Cambria Math, which is proprietry, the fonts above -are all freely available and released under open source licences -(the [GUST Font License][GFL] and [Open Font Licence][OFL]). - -I'm always looking for new fonts to test with, so please let me know of any -new releases. - -[CM]: http://www.ascenderfonts.com/font/cambria-regular.aspx -[MM]: http://www.typoma.com/en/fonts.html -[LM]: http://www.gust.org.pl/projects/e-foundry/lm-math -[PM]: http://www.ctan.org/pkg/tex-gyre-math-pagella -[AM]: http://www.ctan.org/tex-archive/fonts/Asana-Math/ -[NE]: http://github.com/khaledhosny/euler-otf -[SM]: http://www.aip.org/stixfonts/ -[XM]: http://github.com/khaledhosny/xits-math -[GFL]: http://www.gust.org.pl/projects/projects/e-foundry/licenses/ -[OFL]: http://scripts.sil.org/OFL - - -PACKAGE USAGE -------------- - -Please see the PDF documentation for full details. A simple beginning is: - - \usepackage{unicode-math} - \setmathfont{xits-math.otf} - -Most LaTeX math should still work after this. (Let me know if it doesn't.) -Furthermore, it will be in a different font. - - -REQUIREMENTS ------------- - -As well as running XeTeX or LuaTeX, this package requires recent versions of -the `fontspec`, `expl3`, `xpackages`, `catchfile`, `trimspaces`, -`filehook`, and `lualatex-math` packages. - - -MAINTENANCE ------------ - -The current release version is available from CTAN: -> - -Latest developmental and archived historical versions are -available from Github: -> - -Please file bug reports with minimal examples: -> - - - -CHANGE HISTORY --------------- - -- v0.8a (2015/08/06) - - * Fix bug with \vert, \|, \(l/r)vert, etc., displaying with the wrong characters. - - * Improve documentation to properly reflect changes in v0.8 and fix some broken examples. - - * No longer reset catcodes of : and @ during \setmathfont . - - * Fix remapping of alphabets (needed for Minion Math) in cases such as: - - \setmathfont[range=bfit->it]{MinionMath-Bold.otf} - -- v0.8 (2015/07/29) **Breaking changes in this update!** - - * `\mathrm` (`\mathup`), `\mathit`, `\mathbf`, `\mathsf`, and `\mathtt` revert to their traditional LaTeX meanings; they are set up to match their equivalent text fonts unless specifically set using `\setmathrm` and friends from `fontspec` or the new `\setmathfontface` in `unicode-math`. These commands should be used for *multi*-letter identifiers. - - * New "symbol" commands have been added, `\symrm` (`\symup`), `symit`, ..., to replace the behaviour of the old commands. These should be used for *single*-letter identifiers. See the package documentation for more detail on these and related commands. - - * Package options `mathit=sym`, `mathbf=sym`, etc., reverse the changes above to revert to pre-v0.8 behaviour for `\mathXYZ`. Regardless of package option, `\symXYZ` always maps to symbols and `\mathtextXYZ` is provided for the traditional `\mathXYZ` font switch. - - * New command `\setoperatorfont` to set the font used for commands such as `\sin` and `\cos`. Usage: `\setoperatorfont\mathbf` or any command defined with `\setmathfontface`. - - * Traditional LaTeX `\DeclareMathAlphabet` now works again for legacy font-loading packages. - - * Commands defined to "force" Greek letters with `\upbeta` and `\itbeta`, etc. - - * Assorted bug fixes and minor changes. - -- v0.7e (2014/06/30) - - * No longer assume fixltx2e has been loaded. - * Some ascii math symbols have been renamed with a \math... prefix, such as \mathquestion. - * Assume latest luaotfload is being used; no need for a separate unicode-math.lua script. - * Assorted typos and minor bugs. - -- v0.7e (2013/05/04) - - * Track luaotfload updates. - -- v0.7d (2013/03/16) - - * More expl3 changes missed first time around. (Sorry again.) - -- v0.7c (2013/02/25) - - * The Latin Modern math font name changed TWICE. Only caught the first one. - Sorry for any inconvenience caused. - -- v0.7b (2013/02/22) - - * Keep in sync with Latin Modern Math font name change. - * Keep in sync with expl3 changes. - -- v0.7a (2012/07/28) - - * Keep in sync with expl3 changes. - -- v0.7 (2012/05/30): The TeX Live 2012 release. - - * Most changes (and all significant ones) in this release thanks to Khaled - Hosny, who is now credited as an author of the package. - * Many improvements for XeTeX support to take advantage of the new engine - (v0.9998) in TL2012. - * As a result, `\resetmathfont` is no longer required. - * Improve `\not` to use pre-combined glyphs where possible. - * LM Math is loaded by default. - * Support bottom accents. - * And add `\wideutilde`. - * The ‘symbols’ document is somewhat better organised and contains - information on whether a symbol is defined in plain TeX or amssymb. - * Various other minor fixes and additions: - * `\underleftrightarrow` added for fonts that support it. - * Don’t overwrite mathtool’s `\overbracket` and `\underbracket`. - * Bug in `[range=...]` parsing fixed. - * Add `\longdivision`. - * Add `\lgroup` and `\rgroup`. - * Fix ‘moustache’ delimiters. - * `\openbox` renamed to `\mathvisiblespace`, since it is already defined - in amsthm as an empty box. - -- v0.6a (2011/09/19) - - * Always a bug that slips through the cracks! Fixes `\left.` and `\right.` - * Add experimental package option `warnings-off=...` which allows warnings - to be suppressed on an individual basis. - -- v0.6 (2011/09/18) - - * Keep in sync with fontspec internals - (sorry for the small delay where things were broken) - * Keep in sync with expl3 deprecated functions - * Math versions (finally) implemented; can now change maths fonts - mid-document without reinitialising everything - (thanks to Ulrike Fischer and Ulrik Vieth) - * Symbols file `unimath-symbols.pdf` now uses maths versions to compare - all of the OpenType maths fonts I currently have access to - * Over- and under- braces, brackets, and parentheses now work in XeTeX - (thanks to Claudio Beccari) - * Many internal changes, including a re-write of the `range` feature; - it should now be faster and more robust - * Tentative programmer's interface for querying the current math style: - `\l_um_mathstyle_tl`. - * Remove (outdated) interaction with beamer; you must specify - `professionalfonts` manually for now - * Quieten the console output when loading maths fonts with incomplete maths - style coverage - * Synonym added: `\lnot` -> `\neg` - * Two added Unicode symbols (names tentative): `\blanksymbol` and `\openbox` - (thanks to Apostolos Syropoulos) - * Fixed literal sub-/super-script input. - -- v0.5e (2011/07/31) - - * Fix forward compatibility clash with deprecated expl3 functions (sorry) - * Command names are now `\protected`; this makes them safe to use in moving - arguments and so on - * Similarly to the change in v0.5c, the main math font is now loaded in - math family zero (equiv. to LaTeX's `operators` math font) - * `\mathring` added - * Ensure that a math font has been selected in order to prevent problems - in minimal documents (this will be unnecessary when the OpenType LM math - font is released) - * Documentation for which was which of epsilon/varepsilon was backwards! - (thank to Rasmus Villemoes for pointing this out) - * Spurious `\upUpsilon` removed (the one at U+03A5 is now the correct one) - * Typo when defining `\dprime` fixed - (thanks to Ulrik Vieth for these last two) - * Fix the math class of `\modtwosum`; it is now a large operator - (thanks to Michael Ummels) - * Move several LuaTeX-related patches to the `lualatex-math` package - * Fixed mathtool's `\cramped` in XeLaTeX usage - -- v0.5d (2011/01/30) - - * Assorted improvements to LuaLaTeX support, including non-growing accents - available in LuaTeX v0.65 and later - * Improved behaviour with reading and using maths font dimensions - * Better compatibility with legacy maths packages and environments - (always more worked needed, though) - * Fix the default setting for "vargreek-shape" - -- v0.5c (2010/09/27) - - * Fix a long-standing bug in XeLaTeX in which the "master" math - families 2 and 3 weren't being set; hence fraction rules and many other - parameters were not being set correctly - * Stay in sync with internal fontspec changes - -- v0.5b (2010/09/19): Tune-up - - * Added missing symbols/synonyms: - \diamond \smallint \emptyset \hbar \backepsilon \eth - * \overline works for LuaLaTeX - * Fix \slash; previously, it overwrote the text definition - * \vartriangle now has the correct math class - -- v0.5a (2010/07/14): TeX Live 2010 release - - * Numerous documentation improvements - * Bug fix against stray catcode changes - * Add `\mathcal` and `\mathbfcal` as distinct from the Script style; - these are only supported by the XITS fonts at present - * Small changes to the range of symbols offered (especially note that `\ac` - is now `\invlazys` to avoid acronym package clash) - * Superscripts are allowed after primes (as they should be) - * Numerous LuaLaTeX improvements, including roots and over/under braces. - -- v0.5 (2010/06/03): Initial CTAN release - - -LICENCE -------- - -The unicode-math package may be modified and distributed under the terms and -conditions of the [LaTeX Project Public License][LPPL], version 1.3c or -greater. - -[LPPL]: http://www.latex-project.org/lppl/ - -This work is author-maintained and consists of the files - -- unicode-math.dtx, -- unicode-math-table.tex, -- unimath-example.ltx, -- unimath-symbols.ltx, -- unicode-math-testsuite.ltx; - -the derived files - -- unicode-math.lua, -- unicode-math.sty; - -the compiled documentation files - -- unicode-math.pdf, -- unicode-math-testsuite.pdf, -- unimath-example.pdf, -- unimath-symbols.pdf; - -and the test suite for this package - -- testfiles/umtest-preamble.tex, -- testfiles/umtest-suite-(F|L|X).tex, -- testfiles/*.ltx. - -____________________________________ -Copyright 2006-2012 Will Robertson -Copyright 2010-2011 Philipp Stephani -Copyright 2012 Khaled Hosny diff --git a/Master/texmf-dist/doc/latex/unicode-math/README.md b/Master/texmf-dist/doc/latex/unicode-math/README.md new file mode 100644 index 00000000000..7ee21e0946b --- /dev/null +++ b/Master/texmf-dist/doc/latex/unicode-math/README.md @@ -0,0 +1,294 @@ +The UNICODE-MATH package +======================== + +This package will provide a complete implementation of unicode maths for +XeLaTeX and LuaLaTeX. + +While I am a little wary of encouraging people to use this package for +production work, I understand that it has certain uses and am making it +available for distribution. Your testing and feedback is essential to fill +in the many gaps that I miss! + +Please be aware that this package is undergoing continued development and the +interface and functionality should not be considered completely stable. But +the more the package is used the more stable it will become. (Things are +generally working now; it is only minutiae that may change in the future.) + +Unicode maths is currently supported by the following fonts: + + - [Cambria Math][CM] (Microsoft), + - [Minion Math][MM] (Johannes Küster, typoma GmbH) + - [Latin Modern Math][LM] (Bogusław Jackowski, Janusz M. Nowacki) + - [TeX Gyre Pagella Math][PM] (Bogusław Jackowski, Janusz M. Nowacki) + - [Asana Math][AM] (Apostolos Syropolous), + - [Neo Euler][NE] (Khaled Hosny), + - [STIX][SM] (STI Pub), and + - [XITS Math][XM] (Khaled Hosny). + +With the exception of Cambria Math, which is proprietry, the fonts above +are all freely available and released under open source licences +(the [GUST Font License][GFL] and [Open Font Licence][OFL]). + +I'm always looking for new fonts to test with, so please let me know of any +new releases. + +[CM]: http://www.ascenderfonts.com/font/cambria-regular.aspx +[MM]: http://www.typoma.com/en/fonts.html +[LM]: http://www.gust.org.pl/projects/e-foundry/lm-math +[PM]: http://www.ctan.org/pkg/tex-gyre-math-pagella +[AM]: http://www.ctan.org/tex-archive/fonts/Asana-Math/ +[NE]: http://github.com/khaledhosny/euler-otf +[SM]: http://www.aip.org/stixfonts/ +[XM]: http://github.com/khaledhosny/xits-math +[GFL]: http://www.gust.org.pl/projects/projects/e-foundry/licenses/ +[OFL]: http://scripts.sil.org/OFL + + +PACKAGE USAGE +------------- + +Please see the PDF documentation for full details. A simple beginning is: + + \usepackage{unicode-math} + \setmathfont{xits-math.otf} + +Most LaTeX math should still work after this. (Let me know if it doesn't.) +Furthermore, it will be in a different font. + + +REQUIREMENTS +------------ + +As well as running XeTeX or LuaTeX, this package requires recent versions of the `fontspec`, `expl3`, `xpackages`, `filehook`, `ucharcat`, and `lualatex-math` packages. + + +MAINTENANCE +----------- + +The current release version is available from CTAN: +> + +Latest developmental and archived historical versions are available from Github: +> + +Please file bug reports with minimal examples: +> + + + +CHANGE HISTORY +-------------- + +- v0.8b (2015/09/09) + + * Bug fix: Use the "ucharcat" package to simplify some code that caused some headaches with \tl_rescan:nn. + +- v0.8a (2015/08/06) + + * Fix bug with \vert, \|, \(l/r)vert, etc., displaying with the wrong characters. + + * Improve documentation to properly reflect changes in v0.8 and fix some broken examples. + + * No longer reset catcodes of : and @ during \setmathfont . + + * Fix remapping of alphabets (needed for Minion Math) in cases such as: + + \setmathfont[range=bfit->it]{MinionMath-Bold.otf} + +- v0.8 (2015/07/29) **Breaking changes in this update!** + + * `\mathrm` (`\mathup`), `\mathit`, `\mathbf`, `\mathsf`, and `\mathtt` revert to their traditional LaTeX meanings; they are set up to match their equivalent text fonts unless specifically set using `\setmathrm` and friends from `fontspec` or the new `\setmathfontface` in `unicode-math`. These commands should be used for *multi*-letter identifiers. + + * New "symbol" commands have been added, `\symrm` (`\symup`), `symit`, ..., to replace the behaviour of the old commands. These should be used for *single*-letter identifiers. See the package documentation for more detail on these and related commands. + + * Package options `mathit=sym`, `mathbf=sym`, etc., reverse the changes above to revert to pre-v0.8 behaviour for `\mathXYZ`. Regardless of package option, `\symXYZ` always maps to symbols and `\mathtextXYZ` is provided for the traditional `\mathXYZ` font switch. + + * New command `\setoperatorfont` to set the font used for commands such as `\sin` and `\cos`. Usage: `\setoperatorfont\mathbf` or any command defined with `\setmathfontface`. + + * Traditional LaTeX `\DeclareMathAlphabet` now works again for legacy font-loading packages. + + * Commands defined to "force" Greek letters with `\upbeta` and `\itbeta`, etc. + + * Assorted bug fixes and minor changes. + +- v0.7e (2014/06/30) + + * No longer assume fixltx2e has been loaded. + * Some ascii math symbols have been renamed with a \math... prefix, such as \mathquestion. + * Assume latest luaotfload is being used; no need for a separate unicode-math.lua script. + * Assorted typos and minor bugs. + +- v0.7e (2013/05/04) + + * Track luaotfload updates. + +- v0.7d (2013/03/16) + + * More expl3 changes missed first time around. (Sorry again.) + +- v0.7c (2013/02/25) + + * The Latin Modern math font name changed TWICE. Only caught the first one. + Sorry for any inconvenience caused. + +- v0.7b (2013/02/22) + + * Keep in sync with Latin Modern Math font name change. + * Keep in sync with expl3 changes. + +- v0.7a (2012/07/28) + + * Keep in sync with expl3 changes. + +- v0.7 (2012/05/30): The TeX Live 2012 release. + + * Most changes (and all significant ones) in this release thanks to Khaled + Hosny, who is now credited as an author of the package. + * Many improvements for XeTeX support to take advantage of the new engine + (v0.9998) in TL2012. + * As a result, `\resetmathfont` is no longer required. + * Improve `\not` to use pre-combined glyphs where possible. + * LM Math is loaded by default. + * Support bottom accents. + * And add `\wideutilde`. + * The ‘symbols’ document is somewhat better organised and contains + information on whether a symbol is defined in plain TeX or amssymb. + * Various other minor fixes and additions: + * `\underleftrightarrow` added for fonts that support it. + * Don’t overwrite mathtool’s `\overbracket` and `\underbracket`. + * Bug in `[range=...]` parsing fixed. + * Add `\longdivision`. + * Add `\lgroup` and `\rgroup`. + * Fix ‘moustache’ delimiters. + * `\openbox` renamed to `\mathvisiblespace`, since it is already defined + in amsthm as an empty box. + +- v0.6a (2011/09/19) + + * Always a bug that slips through the cracks! Fixes `\left.` and `\right.` + * Add experimental package option `warnings-off=...` which allows warnings + to be suppressed on an individual basis. + +- v0.6 (2011/09/18) + + * Keep in sync with fontspec internals + (sorry for the small delay where things were broken) + * Keep in sync with expl3 deprecated functions + * Math versions (finally) implemented; can now change maths fonts + mid-document without reinitialising everything + (thanks to Ulrike Fischer and Ulrik Vieth) + * Symbols file `unimath-symbols.pdf` now uses maths versions to compare + all of the OpenType maths fonts I currently have access to + * Over- and under- braces, brackets, and parentheses now work in XeTeX + (thanks to Claudio Beccari) + * Many internal changes, including a re-write of the `range` feature; + it should now be faster and more robust + * Tentative programmer's interface for querying the current math style: + `\l_um_mathstyle_tl`. + * Remove (outdated) interaction with beamer; you must specify + `professionalfonts` manually for now + * Quieten the console output when loading maths fonts with incomplete maths + style coverage + * Synonym added: `\lnot` -> `\neg` + * Two added Unicode symbols (names tentative): `\blanksymbol` and `\openbox` + (thanks to Apostolos Syropoulos) + * Fixed literal sub-/super-script input. + +- v0.5e (2011/07/31) + + * Fix forward compatibility clash with deprecated expl3 functions (sorry) + * Command names are now `\protected`; this makes them safe to use in moving + arguments and so on + * Similarly to the change in v0.5c, the main math font is now loaded in + math family zero (equiv. to LaTeX's `operators` math font) + * `\mathring` added + * Ensure that a math font has been selected in order to prevent problems + in minimal documents (this will be unnecessary when the OpenType LM math + font is released) + * Documentation for which was which of epsilon/varepsilon was backwards! + (thank to Rasmus Villemoes for pointing this out) + * Spurious `\upUpsilon` removed (the one at U+03A5 is now the correct one) + * Typo when defining `\dprime` fixed + (thanks to Ulrik Vieth for these last two) + * Fix the math class of `\modtwosum`; it is now a large operator + (thanks to Michael Ummels) + * Move several LuaTeX-related patches to the `lualatex-math` package + * Fixed mathtool's `\cramped` in XeLaTeX usage + +- v0.5d (2011/01/30) + + * Assorted improvements to LuaLaTeX support, including non-growing accents + available in LuaTeX v0.65 and later + * Improved behaviour with reading and using maths font dimensions + * Better compatibility with legacy maths packages and environments + (always more worked needed, though) + * Fix the default setting for "vargreek-shape" + +- v0.5c (2010/09/27) + + * Fix a long-standing bug in XeLaTeX in which the "master" math + families 2 and 3 weren't being set; hence fraction rules and many other + parameters were not being set correctly + * Stay in sync with internal fontspec changes + +- v0.5b (2010/09/19): Tune-up + + * Added missing symbols/synonyms: + \diamond \smallint \emptyset \hbar \backepsilon \eth + * \overline works for LuaLaTeX + * Fix \slash; previously, it overwrote the text definition + * \vartriangle now has the correct math class + +- v0.5a (2010/07/14): TeX Live 2010 release + + * Numerous documentation improvements + * Bug fix against stray catcode changes + * Add `\mathcal` and `\mathbfcal` as distinct from the Script style; + these are only supported by the XITS fonts at present + * Small changes to the range of symbols offered (especially note that `\ac` + is now `\invlazys` to avoid acronym package clash) + * Superscripts are allowed after primes (as they should be) + * Numerous LuaLaTeX improvements, including roots and over/under braces. + +- v0.5 (2010/06/03): Initial CTAN release + + +LICENCE +------- + +The unicode-math package may be modified and distributed under the terms and +conditions of the [LaTeX Project Public License][LPPL], version 1.3c or +greater. + +[LPPL]: http://www.latex-project.org/lppl/ + +This work is author-maintained and consists of the files + +- unicode-math.dtx, +- unicode-math-table.tex, +- unimath-example.ltx, +- unimath-symbols.ltx, +- unicode-math-testsuite.ltx; + +the derived files + +- unicode-math.lua, +- unicode-math.sty; + +the compiled documentation files + +- unicode-math.pdf, +- unicode-math-testsuite.pdf, +- unimath-example.pdf, +- unimath-symbols.pdf; + +and the test suite for this package + +- testfiles/umtest-preamble.tex, +- testfiles/umtest-suite-(F|L|X).tex, +- testfiles/*.ltx. + +____________________________________ +Copyright 2006-2012 Will Robertson +Copyright 2010-2011 Philipp Stephani +Copyright 2012 Khaled Hosny 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 ae835ea73f3..52dcd15aebd 100644 Binary files a/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf and b/Master/texmf-dist/doc/latex/unicode-math/unicode-math.pdf 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 bad02fc07cc..438daaa27df 100644 Binary files a/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf and b/Master/texmf-dist/doc/latex/unicode-math/unimath-symbols.pdf differ diff --git a/Master/texmf-dist/source/latex/unicode-math/unicode-math-compat.dtx b/Master/texmf-dist/source/latex/unicode-math/unicode-math-compat.dtx index 6ab6f351241..f7768095976 100644 --- a/Master/texmf-dist/source/latex/unicode-math/unicode-math-compat.dtx +++ b/Master/texmf-dist/source/latex/unicode-math/unicode-math-compat.dtx @@ -217,7 +217,7 @@ && \int_compare_p:nNn { \leftroot@ } = { \c_zero } } { - \luatexUroot \l_@@_radical_sqrt_tl { #1 } { #2 } + \Uroot \l_@@_radical_sqrt_tl { #1 } { #2 } } { \hbox_set:Nn \rootbox @@ -258,7 +258,7 @@ \mskip \uproot@ mu \c_math_toggle_token } - \luatexUroot \l_@@_radical_sqrt_tl + \Uroot \l_@@_radical_sqrt_tl { \box_move_up:nn { \box_wd:N \l_tmpa_box } { 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 848935c481b..3f4faf47fe0 100644 --- a/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx +++ b/Master/texmf-dist/source/latex/unicode-math/unicode-math.dtx @@ -69,7 +69,7 @@ This work is "maintained" by Will Robertson. %\ProvidesPackage{unicode-math-xetex} %\ProvidesPackage{unicode-math-luatex} %<*preamble> - [2014/08/06 v0.8a Unicode maths in XeLaTeX and LuaLaTeX] + [2015/09/09 v0.8b Unicode maths in XeLaTeX and LuaLaTeX] % %<*internal> \def\DOCUMENTEND{F} @@ -136,6 +136,7 @@ This work is "maintained" by Will Robertson. % \paragraph{Packages} % \begin{macrocode} \RequirePackage{expl3}[2015/03/01] +\RequirePackage{ucharcat} \RequirePackage{xparse} \RequirePackage{l3keys2e} \RequirePackage{fontspec}[2015/03/14] @@ -148,6 +149,11 @@ This work is "maintained" by Will Robertson. \ExplSyntaxOn % \end{macrocode} % +% Variants needed from \pkg{expl3}: +% \begin{macrocode} +\cs_set_protected_nopar:Npn \exp_last_unbraced:NNx { \::N \::x_unbraced \::: } +% \end{macrocode} +% % For \pkg{fontspec}: % \begin{macrocode} \cs_generate_variant:Nn \fontspec_set_family:Nnn {Nx} @@ -370,7 +376,7 @@ This work is "maintained" by Will Robertson. % % Rather than `readable', in the end, this makes the code more extensible. % \begin{macrocode} -\cs_new:Nn \usv_set:nnn +\cs_new:Nn \usv_set:nnn { \tl_set:cn { g_@@_#1_#2_usv } {#3} } \cs_new:Nn \@@_to_usv:nn { \use:c { g_@@_#1_#2_usv } } @@ -637,7 +643,7 @@ This work is "maintained" by Will Robertson. } \use:c {@@_setup_active_frac:} } - + {normalsize} { \bool_set_false:N \l_@@_smallfrac_bool @@ -845,9 +851,9 @@ This work is "maintained" by Will Robertson. \@@_char_gmake_mathactive:n {#3} \@@_active_char_set:wc #3 \q_nil { \cs_to_str:N #2 _sym } \group_end: - + \@@_set_mathchar:cNnn {\cs_to_str:N #2 op} \mathop {#1} {#3} - + \cs_gset:cpx { \cs_to_str:N #2 _sym } { \exp_not:c { \cs_to_str:N #2 op } @@ -958,18 +964,18 @@ This work is "maintained" by Will Robertson. \DeclareDocumentCommand \setmathfontface { m O{} m O{} } { \tl_clear:N \l_@@_mversion_tl - + \keys_set_known:nnN {@@_mathface} {#2,#4} \l_@@_keyval_clist \exp_args:Nnx \fontspec_set_family:Nxn \l_@@_tmpa_tl { ItalicFont={}, BoldFont={}, \exp_not:V \l_@@_keyval_clist } {#3} - + \tl_if_empty:NT \l_@@_mversion_tl { \tl_set:Nn \l_@@_mversion_tl {normal} \DeclareMathAlphabet #1 {\g_fontspec_encoding_tl} {\l_@@_tmpa_tl} {\mddefault} {\updefault} } \SetMathAlphabet #1 {\l_@@_mversion_tl} {\g_fontspec_encoding_tl} {\l_@@_tmpa_tl} {\mddefault} {\updefault} - + % integrate with fontspec's \setmathrm etc: \tl_case:Nn #1 { @@ -1001,7 +1007,7 @@ This work is "maintained" by Will Robertson. % % \subsubsection{Text font} % \begin{macrocode} -\cs_generate_variant:Nn \tl_if_eq:nnT {o} +\cs_generate_variant:Nn \tl_if_eq:nnT {o} \cs_set:Nn \__fontspec_setmainfont:nn { \fontspec_set_family:Nnn \rmdefault {#1}{#2} @@ -1122,7 +1128,7 @@ This work is "maintained" by Will Robertson. \bool_if:nT { \l_@@_ot_math_bool && !\g_@@_mainfont_already_set_bool } { \@@_declare_math_sizes: - \@@_fontspec_select_font: + \@@_fontspec_select_font: } % \end{macrocode} % Now define |\@@_symfont_tl| as the \LaTeX\ math font to access everything: @@ -1523,7 +1529,7 @@ This work is "maintained" by Will Robertson. % ensure \left. and \right. work: \@@_set_delcode:nnn \@@_symfont_tl {`\.} {\c_zero} % this is forcefully done to fix a bug -- indicates a larger problem! - + \@@_assign_delcode:nn {`\/} {\g_@@_slash_delimiter_usv} \@@_assign_delcode:nn {"2044} {\g_@@_slash_delimiter_usv} % fracslash \@@_assign_delcode:nn {"2215} {\g_@@_slash_delimiter_usv} % divslash @@ -1665,12 +1671,16 @@ This work is "maintained" by Will Robertson. % \begin{macro}{\@@_new_cramped_style:N} % \darg{command} % Define \meta{command} as a new cramped style switch. -% For \LuaTeX, simply rename the correspronding primitive. +% For \LuaTeX, simply rename the correspronding primitive if it is not +% already defined. % For \XeTeX, define \meta{command} as a new quark. % \begin{macrocode} \cs_new_protected_nopar:Nn \@@_new_cramped_style:N % { \quark_new:N #1 } -% { \cs_new_eq:Nc #1 { luatex \cs_to_str:N #1 } } +% { +% \cs_if_exist:NF #1 +% { \cs_new_eq:Nc #1 { luatex \cs_to_str:N #1 } } +% } % \end{macrocode} % \end{macro} % @@ -2011,24 +2021,24 @@ This work is "maintained" by Will Robertson. % \begin{macrocode} \prg_new_conditional:Nnn \@@_if_mathalph_decl:n {TF} { - \tl_set:Nn \l_@@_tmpa_tl {#1} + \tl_set:Nn \l_@@_tmpa_tl {#1} \tl_clear:N \l_@@_tmpb_tl \tl_clear:N \l_@@_tmpc_tl - + \tl_if_in:NnT \l_@@_tmpa_tl {->} { \exp_after:wN \@@_split_arrow:w \l_@@_tmpa_tl \q_nil } - + \tl_if_in:NnT \l_@@_tmpa_tl {/} { \exp_after:wN \@@_split_slash:w \l_@@_tmpa_tl \q_nil } - - \tl_set:Nx \l_@@_tmpa_tl { \tl_to_str:N \l_@@_tmpa_tl } + + \tl_set:Nx \l_@@_tmpa_tl { \tl_to_str:N \l_@@_tmpa_tl } \exp_args:NNx \tl_remove_all:Nn \l_@@_tmpa_tl { \token_to_str:N \math } \exp_args:NNx \tl_remove_all:Nn \l_@@_tmpa_tl { \token_to_str:N \sym } \tl_trim_spaces:N \l_@@_tmpa_tl \tl_if_empty:NT \l_@@_tmpc_tl { \tl_set_eq:NN \l_@@_tmpc_tl \l_@@_tmpa_tl } - + \seq_if_in:NVTF \g_@@_named_ranges_seq \l_@@_tmpa_tl { \prg_return_true: } { \prg_return_false: } } @@ -2326,7 +2336,7 @@ This work is "maintained" by Will Robertson. \clist_set:Nn \g_@@_named_ranges_clist { up, it, tt, bfup, bfit, bb , bbit, scr, bfscr, cal, bfcal, - frak, bffrak, sfup, sfit, bfsfup, bfsfit, bfsf + frak, bffrak, sfup, sfit, bfsfup, bfsfit, bfsf } \clist_map_inline:Nn \g_@@_named_ranges_clist { \@@_new_named_range:n {#1} } @@ -2427,7 +2437,7 @@ This work is "maintained" by Will Robertson. % The following are alphabets which do not have a math/text ambiguity. % \begin{macrocode} \clist_map_inline:nn - { + { normal, bb , bbit, scr, bfscr, cal, bfcal, frak, bffrak, tt, bfup, bfit, sfup, sfit, bfsfup, bfsfit, bfsf } @@ -2477,7 +2487,7 @@ This work is "maintained" by Will Robertson. % \begin{document} % \makeatletter % ${\operator@font Mod}\, x$ -% +% % \def\operator@font{% % \let \math@bgroup \relax % \def \math@egroup {\let \math@bgroup \@@math@bgroup @@ -2496,7 +2506,7 @@ This work is "maintained" by Will Robertson. % \begin{document} % \makeatletter % ${\operator@font Mod}\, x$ -% +% % \def\operator@font{\mathgroup\symfoo} % ${\operator@font Mod}\, x$ % \end{document} @@ -2560,7 +2570,7 @@ This work is "maintained" by Will Robertson. \prop_get:cnN { g_@@_named_range_ \l_@@_style_tl _prop } { default-alpha } \l_@@_alphabet_clist } - + \@@_setup_math_alphabet: } \seq_if_empty:NF \l_@@_missing_alph_seq { \@@_log:n { missing-alphabets } } @@ -2980,10 +2990,17 @@ This work is "maintained" by Will Robertson. % % \section{Definitions of the active math characters} % -% Here we define every Unicode math codepoint an equivalent macro name. -% The two are equivalent, in a |\let\xyz=^^^^1234| kind of way. -% % \begin{macro}{\@@_cs_set_eq_active_char:Nw} +% This macro is used to give each Unicode math codepoint an equivalent macro name. +% The two are equivalent, in a |\let\xyz=^^^^1234| kind of way. (For now!!) +% \begin{macrocode} +\cs_set:Npn \@@_cs_set_eq_active_char:Nw #1 = "#2 \q_nil + { + \exp_last_unbraced:NNx \cs_gset_eq:NN #1 { \Ucharcat "#2 ~ 12 ~ } + } +% \end{macrocode} +% \end{macro} +% % \begin{macro}{\@@_active_char_set:wc} % We need to do some trickery to transform the |\_@@_sym:nnn| argument % |"ABCDEF| into the \XeTeX\ `caret input' form |^^^^^abcdef|. It is \emph{very important} @@ -2995,30 +3012,6 @@ This work is "maintained" by Will Robertson. % \begin{macrocode} \group_begin: \char_set_catcode_other:N \^ - \cs_gset:Npn \@@_cs_set_eq_active_char:Nw #1 = "#2 \q_nil - { - \tex_lowercase:D - { - \tl_rescan:nn - { - \ExplSyntaxOn - \char_set_catcode_other:N \{ - \char_set_catcode_other:N \} - \char_set_catcode_other:N \& - \char_set_catcode_other:N \% - \char_set_catcode_other:N \$ - } - { - \cs_gset_eq:NN #1 ^^^^^#2 - } - } - } -% \end{macrocode} -% Making |^| the right catcode isn't strictly necessary right now but it helps -% to future proof us with, e.g., breqn. -% Because we're inside a |\tl_rescan:nn|, use plain old \TeX\ syntax to avoid -% any catcode problems. -% \begin{macrocode} \cs_new:Npn \@@_active_char_set:wc "#1 \q_nil #2 { \tex_lowercase:D @@ -3029,7 +3022,10 @@ This work is "maintained" by Will Robertson. } \group_end: % \end{macrocode} -% \end{macro} +% Could be defined simply as the following if Ucharcar allowed active chars! +% \begin{Verbatim} +% \exp_last_unbraced:Nx \cs_gset_protected_nopar:Npx { \Ucharcat "#2 ~ 13 ~ } { \exp_not:c {#2} } +% \end{Verbatim} % \end{macro} % % Now give \cmd\_@@_sym:nnn\ a definition in terms of \cmd\@@_cs_set_eq_active_char:Nw\ @@ -3045,7 +3041,7 @@ This work is "maintained" by Will Robertson. \char_set_catcode_math_superscript:N \^ \cs_set:Npn \_@@_sym:nnn ##1##2##3 { - \tl_if_in:nnT + \tl_if_in:nnT { \mathord \mathalpha \mathbin \mathrel \mathpunct \mathop \mathfence } {##3} { @@ -3057,22 +3053,6 @@ This work is "maintained" by Will Robertson. \group_end: } % \end{macrocode} -% Fix \cs{backslash}, which is defined as the escape char character -% above: -% \begin{macrocode} -\group_begin: - \lccode`\*=`\\ - \char_set_catcode_escape:N \| - \char_set_catcode_other:N \\ - |lowercase - { - |AtBeginDocument - { - |let|backslash=* - } - } -|group_end: -% \end{macrocode} % % \section{Fall-back font} % @@ -3261,7 +3241,7 @@ This work is "maintained" by Will Robertson. \cs_new:Nn \@@_scanprime_collect:N { \int_incr:N \l_@@_primecount_int - \peek_meaning_remove:NTF ' + \peek_meaning_remove:NTF ' { \@@_scanprime_collect:N #1 } { \peek_meaning_remove:NTF \@@_scan_prime: @@ -3442,6 +3422,15 @@ This work is "maintained" by Will Robertson. % % \subsection{Unicode radicals} % +% Make sure \cs{Uroot} is defined in the case where the \LaTeX{} +% kernel doesn't make it available with its native name. +% \begin{macrocode} +%<*LU> +\cs_if_exist:NF \Uroot + { \cs_new_eq:NN \Uroot \luatexUroot } +% +% \end{macrocode} +% % \begin{macrocode} \AtBeginDocument{\@@_redefine_radical:} \cs_new:Nn \@@_redefine_radical: @@ -3493,7 +3482,7 @@ This work is "maintained" by Will Robertson. % \begin{macrocode} \cs_set:Npn \root ##1 \of ##2 { - \luatexUroot \l_@@_radical_sqrt_tl { ##1 } { ##2 } + \Uroot \l_@@_radical_sqrt_tl { ##1 } { ##2 } } % \end{macrocode} % \end{macro} @@ -3820,7 +3809,7 @@ This work is "maintained" by Will Robertson. % \end{macrocode} % These are names that are `frozen' in HTML but have dumb names: % \begin{macrocode} -\def\dbkarow {\dbkarrow} +\def\dbkarow {\dbkarrow} \def\drbkarow{\drbkarrow} \def\hksearow{\hksearrow} \def\hkswarow{\hkswarrow} 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 1866de6a515..06bf4687261 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 @@ -530,7 +530,10 @@ \tl_new:N \l__um_radicals_tl \tl_set:Nn \l__um_radicals_tl {\sqrt \longdivision} \cs_new_protected_nopar:Nn \__um_new_cramped_style:N - { \cs_new_eq:Nc #1 { luatex \cs_to_str:N #1 } } + { + \cs_if_exist:NF #1 + { \cs_new_eq:Nc #1 { luatex \cs_to_str:N #1 } } + } \__um_new_cramped_style:N \crampeddisplaystyle \__um_new_cramped_style:N \crampedtextstyle \__um_new_cramped_style:N \crampedscriptstyle @@ -1160,26 +1163,12 @@ } \CatchFileEdef \g__um_mathtable_tl {unicode-math-table.tex} {\__um_symbol_setup:} \cs_new:Nn \__um_input_math_symbol_table: {\g__um_mathtable_tl} +\cs_set:Npn \__um_cs_set_eq_active_char:Nw #1 = "#2 \q_nil + { + \exp_last_unbraced:NNx \cs_gset_eq:NN #1 { \Ucharcat "#2 ~ 12 ~ } + } \group_begin: \char_set_catcode_other:N \^ - \cs_gset:Npn \__um_cs_set_eq_active_char:Nw #1 = "#2 \q_nil - { - \tex_lowercase:D - { - \tl_rescan:nn - { - \ExplSyntaxOn - \char_set_catcode_other:N \{ - \char_set_catcode_other:N \} - \char_set_catcode_other:N \& - \char_set_catcode_other:N \% - \char_set_catcode_other:N \$ - } - { - \cs_gset_eq:NN #1 ^^^^^#2 - } - } - } \cs_new:Npn \__um_active_char_set:wc "#1 \q_nil #2 { \tex_lowercase:D @@ -1207,18 +1196,6 @@ \__um_input_math_symbol_table: \group_end: } -\group_begin: - \lccode`\*=`\\ - \char_set_catcode_escape:N \| - \char_set_catcode_other:N \\ - |lowercase - { - |AtBeginDocument - { - |let|backslash=* - } - } -|group_end: \AtBeginDocument { \__um_load_lm_if_necessary: } \cs_new:Nn \__um_load_lm_if_necessary: { @@ -1510,6 +1487,8 @@ \cs_set_eq:NN ^^^^2037 \__um_scan_sup_backtrprime: } \group_end: +\cs_if_exist:NF \Uroot + { \cs_new_eq:NN \Uroot \luatexUroot } \AtBeginDocument{\__um_redefine_radical:} \cs_new:Nn \__um_redefine_radical: { @@ -1517,7 +1496,7 @@ { \cs_set:Npn \root ##1 \of ##2 { - \luatexUroot \l__um_radical_sqrt_tl { ##1 } { ##2 } + \Uroot \l__um_radical_sqrt_tl { ##1 } { ##2 } } } } @@ -1869,7 +1848,7 @@ && \int_compare_p:nNn { \leftroot@ } = { \c_zero } } { - \luatexUroot \l__um_radical_sqrt_tl { #1 } { #2 } + \Uroot \l__um_radical_sqrt_tl { #1 } { #2 } } { \hbox_set:Nn \rootbox @@ -1910,7 +1889,7 @@ \mskip \uproot@ mu \c_math_toggle_token } - \luatexUroot \l__um_radical_sqrt_tl + \Uroot \l__um_radical_sqrt_tl { \box_move_up:nn { \box_wd:N \l_tmpa_box } { 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 b7b7113ee80..a5cac59aec8 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 @@ -1188,26 +1188,12 @@ } \CatchFileEdef \g__um_mathtable_tl {unicode-math-table.tex} {\__um_symbol_setup:} \cs_new:Nn \__um_input_math_symbol_table: {\g__um_mathtable_tl} +\cs_set:Npn \__um_cs_set_eq_active_char:Nw #1 = "#2 \q_nil + { + \exp_last_unbraced:NNx \cs_gset_eq:NN #1 { \Ucharcat "#2 ~ 12 ~ } + } \group_begin: \char_set_catcode_other:N \^ - \cs_gset:Npn \__um_cs_set_eq_active_char:Nw #1 = "#2 \q_nil - { - \tex_lowercase:D - { - \tl_rescan:nn - { - \ExplSyntaxOn - \char_set_catcode_other:N \{ - \char_set_catcode_other:N \} - \char_set_catcode_other:N \& - \char_set_catcode_other:N \% - \char_set_catcode_other:N \$ - } - { - \cs_gset_eq:NN #1 ^^^^^#2 - } - } - } \cs_new:Npn \__um_active_char_set:wc "#1 \q_nil #2 { \tex_lowercase:D @@ -1235,18 +1221,6 @@ \__um_input_math_symbol_table: \group_end: } -\group_begin: - \lccode`\*=`\\ - \char_set_catcode_escape:N \| - \char_set_catcode_other:N \\ - |lowercase - { - |AtBeginDocument - { - |let|backslash=* - } - } -|group_end: \AtBeginDocument { \__um_load_lm_if_necessary: } \cs_new:Nn \__um_load_lm_if_necessary: { @@ -1968,7 +1942,7 @@ && \int_compare_p:nNn { \leftroot@ } = { \c_zero } } { - \luatexUroot \l__um_radical_sqrt_tl { #1 } { #2 } + \Uroot \l__um_radical_sqrt_tl { #1 } { #2 } } { \hbox_set:Nn \rootbox @@ -2009,7 +1983,7 @@ \mskip \uproot@ mu \c_math_toggle_token } - \luatexUroot \l__um_radical_sqrt_tl + \Uroot \l__um_radical_sqrt_tl { \box_move_up:nn { \box_wd:N \l_tmpa_box } { 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 ff499293d04..584b03f79e7 100644 --- a/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty +++ b/Master/texmf-dist/tex/latex/unicode-math/unicode-math.sty @@ -19,7 +19,7 @@ %% %% This work is "maintained" by Will Robertson. \ProvidesPackage{unicode-math} - [2014/08/06 v0.8a Unicode maths in XeLaTeX and LuaLaTeX] + [2015/09/09 v0.8b Unicode maths in XeLaTeX and LuaLaTeX] \usepackage{ifxetex,ifluatex} \ifxetex \ifdim\number\XeTeXversion\XeTeXrevision in<0.9998in% @@ -42,6 +42,7 @@ }\@ehd \fi\fi \RequirePackage{expl3}[2015/03/01] +\RequirePackage{ucharcat} \RequirePackage{xparse} \RequirePackage{l3keys2e} \RequirePackage{fontspec}[2015/03/14] @@ -49,6 +50,7 @@ \RequirePackage{fix-cm} % avoid some warnings \RequirePackage{filehook} \ExplSyntaxOn +\cs_set_protected_nopar:Npn \exp_last_unbraced:NNx { \::N \::x_unbraced \::: } \cs_generate_variant:Nn \fontspec_set_family:Nnn {Nx} \cs_generate_variant:Nn \fontspec_set_fontface:NNnn {NNx} \bool_new:N \l__um_ot_math_bool -- cgit v1.2.3