diff options
author | Karl Berry <karl@freefriends.org> | 2022-02-02 21:41:04 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2022-02-02 21:41:04 +0000 |
commit | 56116169670197f29747c0aac833ec9a95192895 (patch) | |
tree | 0c5d65eeb067d31af8d7039a511ddb7619a0c931 /Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx | |
parent | 297b98fd50c6384f0976ed1c69bf77dd7af09bbd (diff) |
siunitx (2feb22)
git-svn-id: svn://tug.org/texlive/trunk@61858 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx b/Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx index 337901d47ff..8f1e4bb4677 100644 --- a/Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx +++ b/Master/texmf-dist/source/latex/siunitx/siunitx-print.dtx @@ -843,13 +843,22 @@ \tl_set:Nn \l_@@_tmp_tl {#1} \tl_if_empty:NF \l_siunitx_unit_font_tl { \exp_after:wN \cs_set_eq:NN \l_siunitx_unit_font_tl \use:n } - \cs_set:Npn \mathord ##1 {##1} - \cs_set:Npn \pm { \exp_not:N \textpm } + \cs_set:Npn \mathord ##1 + { + \str_case:nnF {##1} + { + { \cdot } { \exp_not:N \textperiodcentered } + { \pm } { \exp_not:N \textpm } + { \times } { \exp_not:N \texttimes } + } + {##1} + } + \cs_set:Npn \pm { \: \exp_not:N \textpm \: } \tl_map_inline:nn { \mp \ge \le \gg \ll } { \cs_set:Npn ##1 { \exp_not:N \ensuremath { \exp_not:N ##1 } } } - \cs_set:Npn \cdot { \exp_not:N \textperiodcentered } - \cs_set:Npn \times { \exp_not:N \texttimes } + \cs_set:Npn \cdot { \: \exp_not:N \textperiodcentered \: } + \cs_set:Npn \times { \: \exp_not:N \texttimes \: } \protected@edef \l_@@_tmp_tl { \l_@@_tmp_tl } \@@_text_replace:N \l_@@_tmp_tl \@@_text_replace_aux:n { \tl_use:N \l_@@_tmp_tl } @@ -992,7 +1001,7 @@ \cs_new_protected:Npn \@@_text_fraction:Nnn #1#2#3 { \ensuremath - { + { #1 { \mbox { \@@_text_replace:n {#2} } } { \mbox { \@@_text_replace:n {#3} } } |