summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2024-01-25 21:22:39 +0000
committerKarl Berry <karl@freefriends.org>2024-01-25 21:22:39 +0000
commitab68e98075c1477689fcc79e76edc3074c57ade7 (patch)
tree240f51dd7dd3631ae9ab39543a2a1cb6053b7cec /Master
parenteb05b6438f547df7326c8911102b05429c523be9 (diff)
unicode-math-input (25jan24)
git-svn-id: svn://tug.org/texlive/trunk@69591 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.pdfbin107101 -> 107152 bytes
-rw-r--r--Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.tex4
-rw-r--r--Master/texmf-dist/tex/latex/unicode-math-input/unicode-math-input.sty42
3 files changed, 22 insertions, 24 deletions
diff --git a/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.pdf b/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.pdf
index 2bfddf791ba..f5c9f1594c0 100644
--- a/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.pdf
+++ b/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.tex b/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.tex
index 61fe577cede..e7b4b217a58 100644
--- a/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.tex
+++ b/Master/texmf-dist/doc/latex/unicode-math-input/unicode-math-input.tex
@@ -1,5 +1,5 @@
%! TEX program = lualatex
-\ProvidesFile{unicode-math-input.tex} [2024/01/18 v0.1.0 ]
+\ProvidesFile{unicode-math-input.tex} [2024/01/25 v0.1.1 ]
\PassOptionsToPackage{hyphens}{url}
\RequirePackage{fvextra}
\documentclass{l3doc}
@@ -234,7 +234,7 @@ Simply include the package.
\usepackage{unicode-math-input}
\end{verbatim}
-Because by default the \pkg{unicode-math} package will already allow entering Unicode symbols in math formulas, this package will raise an error if the other package is already loaded.
+Because by default the \pkg{unicode-math} package will already allow entering Unicode symbols in math formulas, this package will raise an error if \pkg{unicode-math} is already loaded.
\section{Advanced commands and options}
diff --git a/Master/texmf-dist/tex/latex/unicode-math-input/unicode-math-input.sty b/Master/texmf-dist/tex/latex/unicode-math-input/unicode-math-input.sty
index b9696c3a324..6d5a014c236 100644
--- a/Master/texmf-dist/tex/latex/unicode-math-input/unicode-math-input.sty
+++ b/Master/texmf-dist/tex/latex/unicode-math-input/unicode-math-input.sty
@@ -14,7 +14,7 @@
\RequirePackage{expl3}
\RequirePackage{iftex}
-\ProvidesExplPackage{unicode-math-input}{2024-01-18}{0.1.0}{Allow entering Unicode symbols in math formulas}
+\ProvidesExplPackage{unicode-math-input}{2024-01-25}{0.1.1}{Allow entering Unicode symbols in math formulas}
\makeatletter
\AtBeginDocument{
@@ -357,36 +357,34 @@
\cs_new_eq:NN \umiFrac \frac
% ======== after the superscript collection, \umiPrime\umiPrime... should be replaced with \dprime etc. smartly
-\cs_new_protected:Npn \umiPrime{ \__umi_prime } % indirection layer for fast meaning-equality checking
+\cs_new_protected:Npn \umiPrime{ \__umi_prime 1 } % note. Keep this short for fast meaning-equality checking
\cs_new_eq:NN \umiPrimeNormalDefinition \umiPrime
-\cs_new_protected:Npn \__umi_prime {
- \peek_meaning_collect_inline:Nn \umiPrime {
- % note that ##1 misses one \prime as expands to this current function
- \int_case:nnF { \tl_count:n {##1} } {
- 1 {\__umi_alternatives_iisafe \dprime {\prime\prime}}
- 2 {\__umi_alternatives_iisafe \trprime{\prime\prime\prime}}
- 3 {\__umi_alternatives_iisafe \qprime {\prime\prime\prime\prime}}
+\cs_new_protected:Npn \__umi_prime #1 {
+ \peek_meaning_remove:NTF \umiPrime {
+ \exp_args:Nf \__umi_prime {\int_eval:n{#1+1}}
+ } {
+ \int_case:nnF { #1 } {
+ 2 {\__umi_alternatives_iisafe \dprime {\prime\prime}}
+ 3 {\__umi_alternatives_iisafe \trprime{\prime\prime\prime}}
+ 4 {\__umi_alternatives_iisafe \qprime {\prime\prime\prime\prime}}
} {
- % complicated way to repeat '\prime' <count #1> times
- \cs_gset_eq:NN \umiPrime \prime
- \prime ##1
- \cs_gset_eq:NN \umiPrime \umiPrimeNormalDefinition
+ \prg_replicate:nn {#1} {\prime}
}
}
}
% similar for backprime
-\cs_new_protected:Npn \umiBackprime{ \__umi_backprime }
+\cs_new_protected:Npn \umiBackprime{ \__umi_backprime 1 }
\cs_new_eq:NN \umiBackprimeNormalDefinition \umiBackprime
-\cs_new_protected:Npn \__umi_backprime {
- \peek_meaning_collect_inline:Nn \umiBackprime {
- \int_case:nnF { \tl_count:n {##1} } {
- 1 {\__umi_alternatives_iisafe \backdprime {\backprime\backprime}}
- 2 {\__umi_alternatives_iisafe \backtrprime {\backprime\backprime\backprime}}
+\cs_new_protected:Npn \__umi_backprime #1 {
+ \peek_meaning_remove:NTF \umiBackprime {
+ \exp_args:Nf \__umi_backprime {\int_eval:n{#1+1}}
+ } {
+ \int_case:nnF { #1 } {
+ 2 {\__umi_alternatives_iisafe \backdprime {\backprime\backprime}}
+ 3 {\__umi_alternatives_iisafe \backtrprime {\backprime\backprime\backprime}}
} {
- \cs_gset_eq:NN \umiBackprime \backprime
- \backprime ##1
- \cs_gset_eq:NN \umiBackprime \umiBackprimeNormalDefinition
+ \prg_replicate:nn {#1} {\backprime}
}
}
}