diff options
author | Karl Berry <karl@freefriends.org> | 2021-06-07 20:07:35 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-06-07 20:07:35 +0000 |
commit | 5306b14091619abcc7b5555a0781c1c65422f81f (patch) | |
tree | c4f5cff00baa8ec8fe3053b42f52251bbbcde60c /Master/texmf-dist/tex | |
parent | 670905f37c1e8d5b5b8f33e9862b3f8d1f80d01f (diff) |
siunitx (7jun21)
git-svn-id: svn://tug.org/texlive/trunk@59516 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r-- | Master/texmf-dist/tex/latex/siunitx/siunitx.sty | 56 |
1 files changed, 41 insertions, 15 deletions
diff --git a/Master/texmf-dist/tex/latex/siunitx/siunitx.sty b/Master/texmf-dist/tex/latex/siunitx/siunitx.sty index 024f6b12a4c..0cbaae91a00 100644 --- a/Master/texmf-dist/tex/latex/siunitx/siunitx.sty +++ b/Master/texmf-dist/tex/latex/siunitx/siunitx.sty @@ -42,7 +42,7 @@ }% \endinput }% -\ProvidesExplPackage {siunitx} {2021-06-04} {3.0.10} +\ProvidesExplPackage {siunitx} {2021-06-07} {3.0.11} {A comprehensive (SI) units package} \msg_new:nnnn { siunitx } { incompatible-package } { Package~'#1'~incompatible. } @@ -6034,18 +6034,21 @@ } \cs_new:Npn \__siunitx_symbol_non_latin:nnnn #1#2#3#4 { + \__siunitx_symbol_deal_with_utf: \exp_after:wN \exp_after:wN \exp_after:wN \exp_not:N \char_generate:nn {#1} { 13 } \exp_after:wN \exp_after:wN \exp_after:wN \exp_not:N \char_generate:nn {#2} { 13 } } } +\cs_new:Npn \__siunitx_symbol_deal_with_utf: { } \prg_new_protected_conditional:Npnn \__siunitx_symbol_if_replace:Nn #1#2 { T , TF } { \group_begin: - \tl_set:Nx \l__siunitx_symbol_tmpa_tl { \__siunitx_symbol_non_latin:n {#2} } \protected@edef \l__siunitx_symbol_tmpa_tl - { \exp_not:N \mathrm { \l__siunitx_symbol_tmpa_tl } } + { \exp_not:N \mathrm { \__siunitx_symbol_non_latin:n {#2} } } + \int_step_inline:nnn { "80 } { "FF } + { \char_set_active_eq:nN {##1} \scan_stop: } \keys_set:nn { siunitx } { parse-units = false } \siunitx_unit_format:nN {#1} \l__siunitx_symbol_tmpb_tl \str_if_eq:VVTF \l__siunitx_symbol_tmpa_tl \l__siunitx_symbol_tmpb_tl @@ -6054,6 +6057,7 @@ \prg_return_true: } { + \show\l__siunitx_symbol_tmpa_tl \show\l__siunitx_symbol_tmpb_tl \group_end: \prg_return_false: } @@ -6077,8 +6081,12 @@ { \siunitx_declare_unit:Nxn \degree { - \siunitx_print_text:n - { \__siunitx_symbol_non_latin:n { "00B0 } } + \exp_not:N \text + { + \@ifpackageloaded { inputenc } + { \exp_not:N \textdegree } + { \__siunitx_symbol_non_latin:n { "00B0 } } + } } { quantity-product = { } } } @@ -6097,8 +6105,13 @@ { \siunitx_declare_unit:Nx \degreeCelsius { - \siunitx_print_text:n - { \__siunitx_symbol_non_latin:n { "00B0 } } C + \exp_not:N \text + { + \@ifpackageloaded { inputenc } + { \exp_not:N \textdegree } + { \__siunitx_symbol_non_latin:n { "00B0 } } + } + C } } } @@ -6112,7 +6125,7 @@ { \exp_not:N \upOmega } { \exp_not:N \Omega } \exp_not:N \else - \siunitx_print_text:n + \exp_not:N \text { \bool_lazy_or:nnTF { \sys_if_engine_luatex_p: } @@ -6127,7 +6140,7 @@ { \siunitx_declare_prefix:Nnx \micro { -6 } { - \siunitx_print_text:n + \exp_not:N \text { \bool_lazy_or:nnTF { \sys_if_engine_luatex_p: } @@ -6950,6 +6963,13 @@ { quantity-product } \l_keys_value_tl } , + number-unit-separator .code:n = + { + \__siunitx_option_deprecated:nnV + { number-unit-separator } + { quantity-product } + \l_keys_value_tl + } , prefixes-as-symbols .choice: , prefixes-as-symbols / false . code:n = { @@ -7146,25 +7166,31 @@ \bar { bar } \barn { b } \bohr - { \text { \ensuremath { a } } \char_generate:nn { `\_ } { 8 } { 0 } } + { + \exp_not:N \text + { \exp_not:N \ensuremath { a } } \char_generate:nn { `\_ } { 8 } { 0 } + } \clight - { \text { \ensuremath { c } } \char_generate:nn { `\_ } { 8 } { 0 } } + { + \exp_not:N \text + { \exp_not:N \ensuremath { c } } \char_generate:nn { `\_ } { 8 } { 0 } + } \electronmass { - \text { \ensuremath { m } } + \exp_not:N \text { \exp_not:N \ensuremath { m } } \char_generate:nn { `\_ } { 8 } { \exp_not:N \mathrm { e } } } \elementarycharge { \text { \ensuremath { e } } } \hartree { - \text { \ensuremath { E } } + \exp_not:N \text { \exp_not:N \ensuremath { E } } \char_generate:nn { `\_ } { 8 } { \exp_not:N \mathrm { h } } } \knot { kn } \mmHg { mmHg } \nauticalmile { M } \planckbar - { \text { \ensuremath { \exp_not:N \hbar } } } + { \exp_not:N \text { \exp_not:N \ensuremath { \exp_not:N \hbar } } } \q_recursion_tail { } \q_recursion_stop \@ifpackageloaded { fontspec } @@ -7186,7 +7212,7 @@ } \NewDocumentCommand \DeclareSIPrefix { +m m m } { - \siunitx_declare_prefix:Nnn #1 {#2} {#3} + \siunitx_declare_prefix:Nnn #1 {#3} {#2} } \NewDocumentCommand \DeclareSIQualifier { +m m } { |