diff options
-rw-r--r-- | Master/texmf-dist/doc/latex/siunitx/LICENSE | 5 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/siunitx/README | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/siunitx/siunitx.pdf | bin | 579796 -> 620160 bytes | |||
-rw-r--r-- | Master/texmf-dist/source/latex/siunitx/siunitx.dtx | 310 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/siunitx/siunitx.ins | 76 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/siunitx/siunitx-abbreviations.cfg (renamed from Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg) | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/siunitx/siunitx-binary.cfg (renamed from Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg) | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/siunitx/siunitx-version-1.cfg (renamed from Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg) | 9 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/siunitx/siunitx.sty | 226 |
9 files changed, 358 insertions, 278 deletions
diff --git a/Master/texmf-dist/doc/latex/siunitx/LICENSE b/Master/texmf-dist/doc/latex/siunitx/LICENSE new file mode 100644 index 00000000000..69cdc42a1a3 --- /dev/null +++ b/Master/texmf-dist/doc/latex/siunitx/LICENSE @@ -0,0 +1,5 @@ +Released under the [LaTeX Project Public +License](http://www.latex-project.org/lppl.txt), v1.3c or later. + +The package has status 'maintained': the current maintainer is +[Joseph Wright](joseph.wright@morningstar2.co.uk).
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/siunitx/README b/Master/texmf-dist/doc/latex/siunitx/README index 3ac953fd4ce..abccc7d4465 100644 --- a/Master/texmf-dist/doc/latex/siunitx/README +++ b/Master/texmf-dist/doc/latex/siunitx/README @@ -52,4 +52,4 @@ need the packages: - `multirow` - `listings` - `pgfplots` - - `xcolor` + - `xcolor`
\ No newline at end of file diff --git a/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf b/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf Binary files differindex 3d2df09da55..b6c647919ad 100644 --- a/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf +++ b/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf diff --git a/Master/texmf-dist/source/latex/siunitx/siunitx.dtx b/Master/texmf-dist/source/latex/siunitx/siunitx.dtx index 13b425c4aa3..0f644ac2a0c 100644 --- a/Master/texmf-dist/source/latex/siunitx/siunitx.dtx +++ b/Master/texmf-dist/source/latex/siunitx/siunitx.dtx @@ -81,7 +81,7 @@ See http://www.latex-project.org/lppl.txt \endpreamble \postamble -Copyright (C) 2008-2013 by +Copyright (C) 2008-2014 by Joseph Wright <joseph.wright@morningstar2.co.uk> It may be distributed and/or modified under the conditions of @@ -608,6 +608,14 @@ This work consists of the file siunitx.dtx % in tables} %\changes{v2.5r}{2013/07/11}{Update internals to track \pkg{expl3} changes} %\changes{v2.5s}{2013/07/31}{Update internals to track \pkg{expl3} changes} +% \changes{v2.6}{2013/11/19}{Allow for loading of \pkg{mdwtab}} +% \changes{v2.6}{2014/09/03}{Produce proper minus sign when \pkg{tex4ht} +% is in use} +% \changes{v2.6}{2014/09/03}{Fix spacing when printing comparators} +% \changes{v2.6}{2014/09/04}{Fix printing of uncertainties when the +% input is an integer and the uncertainty is given as a separate part} +% \changes{v2.6}{2014/09/04}{Preserve standard meaning of \cs{fg} in +% bookmarks when \pkg{babel} is loaded with the \opt{french} option} % %\begin{abstract} % Physical quantities have both numbers and units, and each physical @@ -762,14 +770,17 @@ This work consists of the file siunitx.dtx %\subsection{Numbers} % %\DescribeMacro{\num} +% \changes{v2.6}{2014/09/03}{Ignore hard spaces (\texttt{\~}) in +% argument of \cs{num}} %\begin{syntax} % \cs{num}\oarg{options}\marg{number} %\end{syntax} % Numbers are automatically formatted by the \cs{num} macro. This % takes one optional argument, \meta{options}, and one mandatory one, % \meta{number}. The contents of \meta{number} are automatically -% formatted. The formatter removes \enquote{hard} spaces -% (\cs{,} and "~"), automatically identifies exponents (by default +% formatted. The formatter removes both \enquote{soft} (\verb*" ") and +% \enquote{hard} spaces (\cs{,} and "~"), automatically identifies +% exponents (by default % marked using \texttt{e}, \texttt{E}, \texttt{d} or \texttt{D}) and % adds the appropriate spacing of large numbers. With the standard % settings a leading zero is added before a decimal marker, if needed: @@ -1217,7 +1228,7 @@ This work consists of the file siunitx.dtx % \meta{symbol} can contain literal input, other units, multiple % prefixes, powers and \cs{per}, although literal text should not be % intermixed with unit macros. Units can be created with \meta{options} -% from the usual list understood by \pkg{siuntix}, and apply the +% from the usual list understood by \pkg{siunitx}, and apply the % specific unit macro only. The (first) optional argument to \cs{SI} % and \cs{si} can be used to override the settings for the unit. A % typical example is the \cs{degree} unit. @@ -1232,7 +1243,7 @@ This work consists of the file siunitx.dtx % The spacing can still be altered at point of use: %\begin{LaTeXdemo} % \SI{67890}{\degree} \\ -% \SI[number-unit-product = \;]{67890}{\degree} +% \SI[number-unit-product = \,]{67890}{\degree} %\end{LaTeXdemo} % The meaning of a pre-defined unit can be altered by using % \cs{DeclareSIUnit} after loading \pkg{siunitx}. This will overwrite @@ -1617,6 +1628,8 @@ This work consists of the file siunitx.dtx %\end{table} % %\DescribeOption{mode} +% \changes{v2.6}{2014/09/03}{Switch standard setting for \opt{mode} option +% to \opt{math}} % The \opt{mode} option determines whether \pkg{siunitx} uses % math or text mode when printing output. The choices are \opt{math} and % \opt{text}. When using math mode, text is printed using a math font @@ -2169,6 +2182,8 @@ This work consists of the file siunitx.dtx %\end{LaTeXdemo} %\DescribeOption{output-exponent-marker} %\changes{v2.2}{2011/04/03}{New \opt{output-exponent-marker} option} +% \changes{v2.6}{2014/09/05}{Fix printing exponent in tables when +% \opt{output-exponent-marker} is active} % Alternatively, if the \opt{output-exponent-marker} option is % set then the value stored will be used in place of the normal % product and base combination. This will normally be set up to @@ -2959,7 +2974,9 @@ This work consists of the file siunitx.dtx % The font used for the powers in units can be typeset using the % current number or unit font. This may be of use when the font used % for numbers and units are very different, for example when the -% \pkg{euler} package is loaded. +% \pkg{euler} package is loaded. Note that this setting applies to all +% printing options for numbers, including the color used for displaying +% the number. %\begin{LaTeXdemo} % \si{\metre\per\second\squared} \\ % \si[power-font = unit]{\metre\per\second\squared} @@ -3051,13 +3068,13 @@ This work consists of the file siunitx.dtx % Type & % \multicolumn{1}{l}{Default} \\ % \midrule ^^A ( -% allow-number-unit-breaks & Switch & false \\ -% exponent-to-prefix & Switch & false \\ -% list-units & Choice & repeat \\ -% multi-part-units & Choice & brackets \\ -% number-unit-product & Literal & \cs{,} \\ -% product-units & Choice & repeat \\ -% range-units & Choice & repeat \\ +% allow-number-unit-breaks & Switch & false \\ +% exponent-to-prefix & Switch & false \\ +% list-units & Choice & repeat \\ +% multi-part-units & Choice & brackets \\ +% number-unit-product & Literal & \cs{,} \\ +% product-units & Choice & repeat \\ +% range-units & Choice & repeat \\ % \bottomrule % \end{tabular} %\end{table} @@ -3082,7 +3099,7 @@ This work consists of the file siunitx.dtx % \opt{number-unit-product} option. %\begin{LaTeXdemo} % \SI{2.67}{\farad} \\ -% \SI[number-unit-product = \text{~}]{2.67}{\farad} \\ +% \SI[number-unit-product = \ ]{2.67}{\farad} \\ % \SI[number-unit-product = ]{2.67}{\farad} %\end{LaTeXdemo} % @@ -4545,8 +4562,8 @@ This work consists of the file siunitx.dtx % colorneg & negative-color \\ % colourneg & negative-color \\ % colourunits & unit-color \\ -% colorvalues & value-color \\ -% colourvalues & value-color \\ +% colorvalues & number-color \\ +% colourvalues & number-color \\ % decimalsymbol & output-decimal-marker \\ % detectdisplay & detect-display-math \\ % digitsep & group-separator \\ @@ -4612,6 +4629,7 @@ This work consists of the file siunitx.dtx % redefsymbols & redefine-symbols \\ % repeatunits & multi-part-units \\ % & product-units \\ +% & range-units \\ % retainplus & retain-explicit-plus \\ % seperr & separate-uncertainty \\ % sepfour & group-four-digits \\ @@ -4657,14 +4675,14 @@ This work consists of the file siunitx.dtx % unitmode & unit-mode \\ % unitsep & inter-unit-product \\ % unitspace & inter-unit-product \\ -% valuecolor & value-color \\ -% valuecolour & value-color \\ -% valuemathrm & value-math-rm \\ -% valuemathsf & value-math-sf \\ -% valuemathsrm & value-math-rm \\ -% valuemathssf & value-math-sf \\ -% valuemathstt & value-math-tt \\ -% valuemathtt & value-math-tt \\ +% valuecolor & number-color \\ +% valuecolour & number-color \\ +% valuemathrm & number-math-rm \\ +% valuemathsf & number-math-sf \\ +% valuemathsrm & number-math-rm \\ +% valuemathssf & number-math-sf \\ +% valuemathstt & number-math-tt \\ +% valuemathtt & number-math-tt \\ % valuemode & value-mode \\ % valuesep & number-unit-product \\ % xspace & use-xspace \\ @@ -4765,6 +4783,12 @@ This work consists of the file siunitx.dtx % account of this, but user-set options for products may need to be updated % accordingly. % +% \subsection{Upgrading from version 2.5} +% +% All printing now takes place in math mode (\emph{i.e.}~\opt{mode = math} +% is set). This may alter the appearance of some units, and users may want +% to verify the output is correct. +% %\section{Correct application of (SI) units} % % Consistent and logical units are a necessity for scientific work, @@ -5118,7 +5142,7 @@ This work consists of the file siunitx.dtx % % The usual preliminaries. % \begin{macrocode} -\ProvidesExplPackage {siunitx} {2013/07/31} {2.5s} +\ProvidesExplPackage {siunitx} {2014/09/05} {2.6} {A comprehensive (SI) units package} % \end{macrocode} % @@ -5613,6 +5637,7 @@ This work consists of the file siunitx.dtx \@@_option_unchanged:Nnn \l_@@_qualifier_mode_tl { subscript } { brackets } \keys_set:nn { siunitx } { mode = text } + \tl_set:Nn \c_@@_minus_tl { \HCode { &\#x2212; } } } { } } @@ -6195,13 +6220,13 @@ This work consists of the file siunitx.dtx } } \keys_set:nn { siunitx } { - math-rm = \mathrm, - math-sf = \mathsf, - math-tt = \mathtt, - number-mode = math, - text-rm = \rmfamily, - text-sf = \sffamily, - text-tt = \ttfamily, + math-rm = \mathrm, + math-sf = \mathsf, + math-tt = \mathtt, + mode = math, + text-rm = \rmfamily, + text-sf = \sffamily, + text-tt = \ttfamily, } % \end{macrocode} % @@ -6365,7 +6390,8 @@ This work consists of the file siunitx.dtx % %\begin{macro}{ % \@@_print_math: , -% \@@_print_text: +% \@@_print_text:, +% \@@_print_text_aux: %} % Printing the text means replacing any awkward characters, which is % dependent on the output mode. The rest of the package uses "_" and @@ -6401,10 +6427,10 @@ This work consists of the file siunitx.dtx { \tl_replace_all:Nnn \l_@@_print_arg_tl { - } { \c_@@_minus_tl } - \tl_replace_all:Nnn \l_@@_print_arg_tl { \pm } - { \ensuremath { \pm } } + \@@_print_text_aux: \tl_replace_all:Nnn \l_@@_print_arg_tl { \mp } { \ensuremath { \mp } } + \tl_remove_all:Nn \l_@@_print_arg_tl { \mathord } \cs_set_eq:NN \PrintSubscript \@@_print_text_sub:n \cs_set_eq:NN \PrintSuperscript \@@_print_text_super:n \tl_replace_all:Nnn \l_@@_print_arg_tl { @ } @@ -6420,6 +6446,23 @@ This work consists of the file siunitx.dtx \l_@@_print_arg_tl } } +\cs_new_protected:Npn \@@_print_text_aux: + { + \tl_replace_all:Nnn \l_@@_print_arg_tl { \pm } + { \ensuremath { \pm } } + } +\AtBeginDocument + { + \@ifpackageloaded { textcomp } + { + \cs_set_protected:Npn \@@_print_text_aux: + { + \tl_replace_all:Nnn \l_@@_print_arg_tl { \pm } + { \textpm } + } + } + { } + } % \end{macrocode} %\end{macro} % @@ -6812,46 +6855,51 @@ This work consists of the file siunitx.dtx } } \cs_generate_variant:Nn \@@_number_in_parse:n { V } -\cs_new_protected:Npn \@@_number_in_parse_aux:n #1 - { - \group_begin: - \@@_number_in_protect: - \cs_set_eq:NN \, \prg_do_nothing: - \tl_set_rescan:Nnx \l_@@_number_arg_tl - { - \char_set_catcode_ignore:N \~ - \char_set_catcode_other:N \, - \char_set_catcode_other:N \. - } - {#1} - \exp_args:NNNV \group_end: - \tl_set:Nn \l_@@_number_arg_tl \l_@@_number_arg_tl - \@@_number_in_sign_replace:N \l_@@_number_arg_tl - \@@_number_in_parse_relation:N \l_@@_number_arg_tl - \tl_map_function:NN \l_@@_number_arg_tl - \@@_number_in_parse_loop:N - \tl_if_empty:NF \l_@@_number_parsed_tl - { - \bool_if:NTF \l_@@_number_in_uncert_bool - { \@@_error:nx { invalid-number } {#1} } - { - \prop_put:NVn \l_@@_number_in_prop - \l_@@_number_part_tl { true } - \bool_if:NTF \l_@@_number_in_decimal_bool - { - \prop_put:NVV \l_@@_number_in_prop - \l_@@_number_part_decimal_tl - \l_@@_number_parsed_tl - } - { - \prop_put:NVV \l_@@_number_in_prop - \l_@@_number_part_integer_tl - \l_@@_number_parsed_tl - } - } - } - \@@_number_in_check:n {#1} - } +\group_begin: + \char_set_catcode_active:N \~ + \char_set_catcode_space:N \ % + \cs_new_protected:Npn \@@_number_in_parse_aux:n#1% + {% + \group_begin: + \@@_number_in_protect: + \cs_set_eq:NN\,\prg_do_nothing: + \cs_set_eq:NN~\prg_do_nothing: + \tl_set_rescan:Nnx\l_@@_number_arg_tl + {% + \char_set_catcode_ignore:N\ % + \char_set_catcode_other:N\,% + \char_set_catcode_other:N\.% + }% + {#1}% + \exp_args:NNNV\group_end: + \tl_set:Nn\l_@@_number_arg_tl\l_@@_number_arg_tl + \@@_number_in_sign_replace:N\l_@@_number_arg_tl + \@@_number_in_parse_relation:N\l_@@_number_arg_tl + \tl_map_function:NN\l_@@_number_arg_tl + \@@_number_in_parse_loop:N + \tl_if_empty:NF\l_@@_number_parsed_tl + {% + \bool_if:NTF\l_@@_number_in_uncert_bool + {\@@_error:nx{invalid-number}{#1}}% + {% + \prop_put:NVn \l_@@_number_in_prop + \l_@@_number_part_tl {true}% + \bool_if:NTF\l_@@_number_in_decimal_bool + {% + \prop_put:NVV\l_@@_number_in_prop + \l_@@_number_part_decimal_tl + \l_@@_number_parsed_tl + }% + {% + \prop_put:NVV\l_@@_number_in_prop + \l_@@_number_part_integer_tl + \l_@@_number_parsed_tl + }% + }% + }% + \@@_number_in_check:n {#1}% + } +\group_end: % \end{macrocode} %\end{macro} %\end{macro} @@ -7700,7 +7748,7 @@ This work consists of the file siunitx.dtx { \prop_get:NnNF \l_@@_number_in_prop { mantissa-decimal } \l_@@_tmpb_tl - { \tl_clear:N \l_@@_tmpb_tl } + { \tl_set:Nn \l_@@_tmpb_tl { 0 } } \tl_set:Nx \l_@@_tmpb_tl { \exp_not:V \l_@@_tmpb_tl @@ -9653,7 +9701,12 @@ This work consists of the file siunitx.dtx \l_@@_tmpa_tl \prop_get:NnN \l_@@_number_out_prop { result } \l_@@_tmpb_tl - \tl_put_right:No \l_@@_tmpa_tl { \l_@@_tmpb_tl } + \tl_set:Nx \l_@@_tmpa_tl + { + \exp_not:N \mathord + \exp_not:V \l_@@_tmpa_tl + \exp_not:V \l_@@_tmpb_tl + } \prop_put:NnV \l_@@_number_out_prop { result } \l_@@_tmpa_tl } @@ -9711,7 +9764,8 @@ This work consists of the file siunitx.dtx \tl_set:Nx \l_@@_tmpa_tl { \exp_not:V \l_@@_output_exponent_tl - { \exp_not:V \l_@@_tmpa_tl } + \exp_not:N \mathord + \exp_not:V \l_@@_tmpa_tl } } \prop_put:NnV \l_@@_number_out_prop { exponent-result } @@ -9728,11 +9782,6 @@ This work consists of the file siunitx.dtx \prop_get:NnNT \l_@@_number_in_prop { mantissa-sign } \l_@@_tmpa_tl { - \bool_if:NT \l_@@_tight_bool - { - \tl_set:Nx \l_@@_tmpa_tl - { { \exp_not:V \l_@@_tmpa_tl } } - } \prop_get:NnN \l_@@_number_out_prop { exponent-result } \l_@@_tmpb_tl \@@_tl_put_left_math:NV \l_@@_tmpb_tl @@ -10035,11 +10084,6 @@ This work consists of the file siunitx.dtx } } \cs_new_protected:Npn \@@_number_format_sign_aux:n #1 { - \bool_if:NT \l_@@_tight_bool - { - \tl_set:Nx \l_@@_tmpa_tl - { { \exp_not:V \l_@@_tmpa_tl } } - } \tl_clear:N \l_@@_tmpb_tl \tl_put_left:NV \l_@@_tmpb_tl \l_@@_tmpa_tl \prop_put:NnV \l_@@_number_out_prop { #1 -sign } @@ -10081,7 +10125,7 @@ This work consists of the file siunitx.dtx \bool_if:NTF \l_@@_tight_bool { \tl_set:Nx \l_@@_tmpa_tl - { { \exp_not:V \l_@@_tmpa_tl } } + { \exp_not:N \mathord \exp_not:V \l_@@_tmpa_tl } } { \prop_if_in:NnT \l_@@_number_out_prop { mantissa } @@ -12703,8 +12747,8 @@ This work consists of the file siunitx.dtx } \keys_set:nn { siunitx } { multi-part-units = brackets, - number-unit-product = \,, - product-units = repeat, + number-unit-product = \, , + product-units = repeat } % \end{macrocode} %\end{macro} @@ -13205,7 +13249,10 @@ This work consists of the file siunitx.dtx { \tl_set_eq:NN \l_@@_tmpa_tl \l_@@_exponent_product_tl \bool_if:NT \l_@@_tight_bool - { \tl_set:Nx \l_@@_tmpa_tl { { \exp_not:o \l_@@_tmpa_tl } } } + { + \tl_set:Nx \l_@@_tmpa_tl + { \exp_not:N \mathord \exp_not:o \l_@@_tmpa_tl } + } \tl_set:Nx \l_@@_tmpa_tl { \exp_not:N \ensuremath { { } \exp_not:o \l_@@_tmpa_tl { } } @@ -13272,6 +13319,22 @@ This work consists of the file siunitx.dtx \NC@find } } +\AtBeginDocument + { + \@ifpackageloaded { mdwtab } + { + \cs_set_protected:Npn \@@_table_rewrite_create:N #1 + { + \newcolumntype {#1} [1] [] + { + > { \__siunitx_table_collect_begin:Nn #1 {##1} } + c + < { \__siunitx_table_print: } + } + } + } + { } + } \cs_new_protected:Npn \@@_table_rewrite_create_aux:w { } \AtBeginDocument { \@@_table_rewrite_create:N s } \AtBeginDocument { \@@_table_rewrite_create:N S } @@ -13561,14 +13624,34 @@ This work consists of the file siunitx.dtx % so that the table actually works. The newline function needs its own % function, which is picked up by hand. % \begin{macrocode} -\cs_new_protected:Npn \@@_table_collect_not_braced:N #1 { - \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D - { - \token_if_eq_meaning:NNF #1 \tex_unskip:D - { \@@_table_collect_not_braced_aux_i:N #1 } - } - \@@_table_collect_next: -} +\cs_new_protected:Npn \@@_table_collect_not_braced:N #1 + { + \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D + { + \token_if_eq_meaning:NNF #1 \tex_unskip:D + { \@@_table_collect_not_braced_aux_i:N #1 } + } + \@@_table_collect_next: + } +\AtBeginDocument + { + \@ifpackageloaded { mdwtab } + { + \cs_set_protected:Npn \@@_table_collect_not_braced:N #1 + { + \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D + { + \token_if_eq_meaning:NNF #1 \tex_unskip:D + { + \token_if_eq_meaning:NNF #1 \tab@setcr + { \@@_table_collect_not_braced_aux_i:N #1 } + } + } + \@@_table_collect_next: + } + } + { } + } \cs_new_protected:Npn \@@_table_collect_not_braced_aux_i:N #1 { \cs_set:Npn \@@_table_collect_not_braced_aux_ii:N ##1 { @@ -14812,9 +14895,12 @@ This work consists of the file siunitx.dtx { \dim_set:Nn \l_@@_table_exponent_dim { \box_wd:N \l_@@_tmp_box } - \prop_if_in:NnTF \l_@@_number_out_prop { mantissa } - { \@@_table_print_S_reserved_exponent_product: } - { \@@_table_print_S_reserved_exponent_product_correction: } + \tl_if_empty:NT \l_@@_output_exponent_tl + { + \prop_if_in:NnTF \l_@@_number_out_prop { mantissa } + { \@@_table_print_S_reserved_exponent_product: } + { \@@_table_print_S_reserved_exponent_product_correction: } + } \hbox_set:Nn \l_@@_tmp_box { \@@_print:nV { number } \l_@@_tmpa_tl } \bool_if:NTF \l_@@_table_align_exponent_bool @@ -14844,7 +14930,10 @@ This work consists of the file siunitx.dtx { \tl_set_eq:NN \l_@@_tmpb_tl \l_@@_exponent_product_tl \bool_if:NT \l_@@_tight_bool - { \tl_set:Nx \l_@@_tmpb_tl { { \exp_not:o \l_@@_tmpb_tl } } } + { + \tl_set:Nx \l_@@_tmpb_tl + { \exp_not:N \mathord \exp_not:o \l_@@_tmpb_tl } + } \tl_set:Nx \l_@@_tmpa_tl { \exp_not:N \ensuremath { { } \exp_not:o \l_@@_tmpb_tl { } } @@ -15897,6 +15986,8 @@ This work consists of the file siunitx.dtx { \seq_map_inline:Nn \l_@@_declare_list_seq { \@@_unit_print_literal_aux:N ##1 } + \cs_if_exist:NT \FB@fg + { \cs_set_eq:NN \fg \FB@fg } \msg_redirect_name:nnn { xparse } { redefine-command } { none } \cs_set_eq:NN \num \@@_bookmark_num:w \cs_set_eq:NN \numrange \@@_bookmark_numrange:w @@ -16545,7 +16636,7 @@ This work consists of the file siunitx.dtx % \end{macrocode} % % \begin{macrocode} -\ProvidesExplFile {siunitx-version-1.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-version-1.cfg} {2014/09/05} {2.6} {siunitx: Version 1 settings} % \end{macrocode} % @@ -17171,10 +17262,7 @@ This work consists of the file siunitx.dtx % A couple of settings which are slightly different by default in % version 1. % \begin{macrocode} -\keys_set:nn { siunitx } { - free-standing-units = true , - mode = math , -} +\keys_set:nn { siunitx } {free-standing-units = true} % \end{macrocode} % %\begin{macro}{ @@ -17490,7 +17578,7 @@ This work consists of the file siunitx.dtx % \end{macrocode} % % \begin{macrocode} -\ProvidesExplFile {siunitx-abbreviations.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-abbreviations.cfg} {2014/09/05} {2.6} {siunitx: Abbreviated units} % \end{macrocode} % @@ -17672,7 +17760,7 @@ This work consists of the file siunitx.dtx % \end{macrocode} % % \begin{macrocode} -\ProvidesExplFile {siunitx-binary.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-binary.cfg} {2014/09/05} {2.6} {siunitx: Binary units} % \end{macrocode} % diff --git a/Master/texmf-dist/source/latex/siunitx/siunitx.ins b/Master/texmf-dist/source/latex/siunitx/siunitx.ins deleted file mode 100644 index 1fc4ad41ea9..00000000000 --- a/Master/texmf-dist/source/latex/siunitx/siunitx.ins +++ /dev/null @@ -1,76 +0,0 @@ -%% -%% This is file `siunitx.ins', -%% generated with the docstrip utility. -%% -%% The original source files were: -%% -%% siunitx.dtx (with options: `install') -%% --------------------------------------------------------------- -%% The siunitx package --- A comprehensive (SI) units package -%% Maintained by Joseph Wright -%% E-mail: joseph.wright@morningstar2.co.uk -%% Released under the LaTeX Project Public License v1.3c or later -%% See http://www.latex-project.org/lppl.txt -%% --------------------------------------------------------------- -%% -\input l3docstrip.tex -\keepsilent -\askforoverwritefalse -\preamble ---------------------------------------------------------------- -The siunitx package --- A comprehensive (SI) units package -Maintained by Joseph Wright -E-mail: joseph.wright@morningstar2.co.uk -Released under the LaTeX Project Public License v1.3c or later -See http://www.latex-project.org/lppl.txt ---------------------------------------------------------------- - -\endpreamble -\postamble -Copyright (C) 2008-2013 by - Joseph Wright <joseph.wright@morningstar2.co.uk> - -It may be distributed and/or modified under the conditions of -the LaTeX Project Public License (LPPL), either version 1.3c of -this license or (at your option) any later version. The latest -version of this license is in the file: - http://www.latex-project.org/lppl.txt - -This work is "maintained" (as per LPPL maintenance status) by - Joseph Wright. - -This work consists of the file siunitx.dtx - and the derived files siunitx.pdf, - siunitx.sty and - siunitx.ins. -\endpostamble -\usedir{tex/latex/siunitx} -\generate{ - \file{\jobname.sty}{\from{\jobname.dtx}{package}} -} -\usedir{tex/latex/siunitx/config} -\generate{ - \file{siunitx-abbreviations.cfg} - {\from{\jobname.dtx}{config,abbreviations}} - \file{siunitx-binary.cfg}{\from{\jobname.dtx}{config,binary}} - \file{siunitx-version-1.cfg}{\from{\jobname.dtx}{config,version-1}} -} -\endbatchfile -%% Copyright (C) 2008-2013 by -%% Joseph Wright <joseph.wright@morningstar2.co.uk> -%% -%% It may be distributed and/or modified under the conditions of -%% the LaTeX Project Public License (LPPL), either version 1.3c of -%% this license or (at your option) any later version. The latest -%% version of this license is in the file: -%% http://www.latex-project.org/lppl.txt -%% -%% This work is "maintained" (as per LPPL maintenance status) by -%% Joseph Wright. -%% -%% This work consists of the file siunitx.dtx -%% and the derived files siunitx.pdf, -%% siunitx.sty and -%% siunitx.ins. -%% -%% End of file `siunitx.ins'. diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg b/Master/texmf-dist/tex/latex/siunitx/siunitx-abbreviations.cfg index 2dc0547ceeb..8c18c85c49d 100644 --- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg +++ b/Master/texmf-dist/tex/latex/siunitx/siunitx-abbreviations.cfg @@ -13,7 +13,7 @@ %% See http://www.latex-project.org/lppl.txt %% --------------------------------------------------------------- %% -\ProvidesExplFile {siunitx-abbreviations.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-abbreviations.cfg} {2014/09/05} {2.6} {siunitx: Abbreviated units} \DeclareSIUnit \A { \ampere } \DeclareSIUnit \pA { \pico \ampere } @@ -102,7 +102,7 @@ \DeclareSIUnit \ns { \nano \second } \DeclareSIUnit \us { \micro \second } \DeclareSIUnit \ms { \milli \second } -%% Copyright (C) 2008-2013 by +%% Copyright (C) 2008-2014 by %% Joseph Wright <joseph.wright@morningstar2.co.uk> %% %% It may be distributed and/or modified under the conditions of diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg b/Master/texmf-dist/tex/latex/siunitx/siunitx-binary.cfg index c40077c9823..8dfa98bada1 100644 --- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg +++ b/Master/texmf-dist/tex/latex/siunitx/siunitx-binary.cfg @@ -13,7 +13,7 @@ %% See http://www.latex-project.org/lppl.txt %% --------------------------------------------------------------- %% -\ProvidesExplFile {siunitx-binary.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-binary.cfg} {2014/09/05} {2.6} {siunitx: Binary units} \DeclareBinaryPrefix \kibi { Ki } { 10 } \DeclareBinaryPrefix \mebi { Mi } { 20 } @@ -25,7 +25,7 @@ \DeclareBinaryPrefix \yobi { Yi } { 80 } \DeclareSIUnit \bit { bit } \DeclareSIUnit \byte { B } -%% Copyright (C) 2008-2013 by +%% Copyright (C) 2008-2014 by %% Joseph Wright <joseph.wright@morningstar2.co.uk> %% %% It may be distributed and/or modified under the conditions of diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg b/Master/texmf-dist/tex/latex/siunitx/siunitx-version-1.cfg index 98fd50d08f2..1bbad3c32dc 100644 --- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg +++ b/Master/texmf-dist/tex/latex/siunitx/siunitx-version-1.cfg @@ -13,7 +13,7 @@ %% See http://www.latex-project.org/lppl.txt %% --------------------------------------------------------------- %% -\ProvidesExplFile {siunitx-version-1.cfg} {2013/07/31} {2.5s} +\ProvidesExplFile {siunitx-version-1.cfg} {2014/09/05} {2.6} {siunitx: Version 1 settings} \keys_define:nn { siunitx } { addsign .choice: , @@ -622,10 +622,7 @@ { \exp_not:V \l_keys_key_tl } } } -\keys_set:nn { siunitx } { - free-standing-units = true , - mode = math , -} +\keys_set:nn { siunitx } {free-standing-units = true} \cs_new_eq:NN \newunit \DeclareSIUnit \cs_new_eq:NN \renewunit \DeclareSIUnit \cs_new_eq:NN \provideunit \DeclareSIUnit @@ -730,7 +727,7 @@ \DeclareSIUnit \yb { \yocto \barn } \NewDocumentCommand \requiresiconfigs { m } { \keys_set:nn { siunitx } { version-1-compatibility } } -%% Copyright (C) 2008-2013 by +%% Copyright (C) 2008-2014 by %% Joseph Wright <joseph.wright@morningstar2.co.uk> %% %% It may be distributed and/or modified under the conditions of diff --git a/Master/texmf-dist/tex/latex/siunitx/siunitx.sty b/Master/texmf-dist/tex/latex/siunitx/siunitx.sty index 6c83ee336ee..cbcd24f9c22 100644 --- a/Master/texmf-dist/tex/latex/siunitx/siunitx.sty +++ b/Master/texmf-dist/tex/latex/siunitx/siunitx.sty @@ -14,7 +14,7 @@ %% --------------------------------------------------------------- %% \RequirePackage{expl3,xparse} -\ProvidesExplPackage {siunitx} {2013/07/31} {2.5s} +\ProvidesExplPackage {siunitx} {2014/09/05} {2.6} {A comprehensive (SI) units package} \@ifpackagelater { expl3 } { 2012/11/21 } { } @@ -348,6 +348,7 @@ \__siunitx_option_unchanged:Nnn \l__siunitx_qualifier_mode_tl { subscript } { brackets } \keys_set:nn { siunitx } { mode = text } + \tl_set:Nn \c__siunitx_minus_tl { \HCode { &\#x2212; } } } { } } @@ -688,13 +689,13 @@ } } \keys_set:nn { siunitx } { - math-rm = \mathrm, - math-sf = \mathsf, - math-tt = \mathtt, - number-mode = math, - text-rm = \rmfamily, - text-sf = \sffamily, - text-tt = \ttfamily, + math-rm = \mathrm, + math-sf = \mathsf, + math-tt = \mathtt, + mode = math, + text-rm = \rmfamily, + text-sf = \sffamily, + text-tt = \ttfamily, } \AtBeginDocument { \tl_set:Nx \l__siunitx_tmpa_tl { \familydefault } @@ -823,10 +824,10 @@ { \tl_replace_all:Nnn \l__siunitx_print_arg_tl { - } { \c__siunitx_minus_tl } - \tl_replace_all:Nnn \l__siunitx_print_arg_tl { \pm } - { \ensuremath { \pm } } + \__siunitx_print_text_aux: \tl_replace_all:Nnn \l__siunitx_print_arg_tl { \mp } { \ensuremath { \mp } } + \tl_remove_all:Nn \l__siunitx_print_arg_tl { \mathord } \cs_set_eq:NN \PrintSubscript \__siunitx_print_text_sub:n \cs_set_eq:NN \PrintSuperscript \__siunitx_print_text_super:n \tl_replace_all:Nnn \l__siunitx_print_arg_tl { @ } @@ -842,6 +843,23 @@ \l__siunitx_print_arg_tl } } +\cs_new_protected:Npn \__siunitx_print_text_aux: + { + \tl_replace_all:Nnn \l__siunitx_print_arg_tl { \pm } + { \ensuremath { \pm } } + } +\AtBeginDocument + { + \@ifpackageloaded { textcomp } + { + \cs_set_protected:Npn \__siunitx_print_text_aux: + { + \tl_replace_all:Nnn \l__siunitx_print_arg_tl { \pm } + { \textpm } + } + } + { } + } \cs_new_protected:Npn \__siunitx_print_text_sub:n #1 { \cs_set:Npn \__siunitx_print_text_sub_super:n ##1 @@ -1019,46 +1037,51 @@ } } \cs_generate_variant:Nn \__siunitx_number_in_parse:n { V } -\cs_new_protected:Npn \__siunitx_number_in_parse_aux:n #1 - { - \group_begin: - \__siunitx_number_in_protect: - \cs_set_eq:NN \, \prg_do_nothing: - \tl_set_rescan:Nnx \l__siunitx_number_arg_tl - { - \char_set_catcode_ignore:N \~ - \char_set_catcode_other:N \, - \char_set_catcode_other:N \. - } - {#1} - \exp_args:NNNV \group_end: - \tl_set:Nn \l__siunitx_number_arg_tl \l__siunitx_number_arg_tl - \__siunitx_number_in_sign_replace:N \l__siunitx_number_arg_tl - \__siunitx_number_in_parse_relation:N \l__siunitx_number_arg_tl - \tl_map_function:NN \l__siunitx_number_arg_tl - \__siunitx_number_in_parse_loop:N - \tl_if_empty:NF \l__siunitx_number_parsed_tl - { - \bool_if:NTF \l__siunitx_number_in_uncert_bool - { \__siunitx_error:nx { invalid-number } {#1} } - { - \prop_put:NVn \l__siunitx_number_in_prop - \l__siunitx_number_part_tl { true } - \bool_if:NTF \l__siunitx_number_in_decimal_bool - { - \prop_put:NVV \l__siunitx_number_in_prop - \l__siunitx_number_part_decimal_tl - \l__siunitx_number_parsed_tl - } - { - \prop_put:NVV \l__siunitx_number_in_prop - \l__siunitx_number_part_integer_tl - \l__siunitx_number_parsed_tl - } - } - } - \__siunitx_number_in_check:n {#1} - } +\group_begin: + \char_set_catcode_active:N \~ + \char_set_catcode_space:N \ % + \cs_new_protected:Npn \__siunitx_number_in_parse_aux:n#1% + {% + \group_begin: + \__siunitx_number_in_protect: + \cs_set_eq:NN\,\prg_do_nothing: + \cs_set_eq:NN~\prg_do_nothing: + \tl_set_rescan:Nnx\l__siunitx_number_arg_tl + {% + \char_set_catcode_ignore:N\ % + \char_set_catcode_other:N\,% + \char_set_catcode_other:N\.% + }% + {#1}% + \exp_args:NNNV\group_end: + \tl_set:Nn\l__siunitx_number_arg_tl\l__siunitx_number_arg_tl + \__siunitx_number_in_sign_replace:N\l__siunitx_number_arg_tl + \__siunitx_number_in_parse_relation:N\l__siunitx_number_arg_tl + \tl_map_function:NN\l__siunitx_number_arg_tl + \__siunitx_number_in_parse_loop:N + \tl_if_empty:NF\l__siunitx_number_parsed_tl + {% + \bool_if:NTF\l__siunitx_number_in_uncert_bool + {\__siunitx_error:nx{invalid-number}{#1}}% + {% + \prop_put:NVn \l__siunitx_number_in_prop + \l__siunitx_number_part_tl {true}% + \bool_if:NTF\l__siunitx_number_in_decimal_bool + {% + \prop_put:NVV\l__siunitx_number_in_prop + \l__siunitx_number_part_decimal_tl + \l__siunitx_number_parsed_tl + }% + {% + \prop_put:NVV\l__siunitx_number_in_prop + \l__siunitx_number_part_integer_tl + \l__siunitx_number_parsed_tl + }% + }% + }% + \__siunitx_number_in_check:n {#1}% + } +\group_end: \cs_new_protected:Npn \__siunitx_number_in_init: { \cs_set_eq:NN \__siunitx_number_in_parse_loop:N \__siunitx_number_in_parse_mantissa:N @@ -1682,7 +1705,7 @@ { \prop_get:NnNF \l__siunitx_number_in_prop { mantissa-decimal } \l__siunitx_tmpb_tl - { \tl_clear:N \l__siunitx_tmpb_tl } + { \tl_set:Nn \l__siunitx_tmpb_tl { 0 } } \tl_set:Nx \l__siunitx_tmpb_tl { \exp_not:V \l__siunitx_tmpb_tl @@ -3118,7 +3141,12 @@ \l__siunitx_tmpa_tl \prop_get:NnN \l__siunitx_number_out_prop { result } \l__siunitx_tmpb_tl - \tl_put_right:No \l__siunitx_tmpa_tl { \l__siunitx_tmpb_tl } + \tl_set:Nx \l__siunitx_tmpa_tl + { + \exp_not:N \mathord + \exp_not:V \l__siunitx_tmpa_tl + \exp_not:V \l__siunitx_tmpb_tl + } \prop_put:NnV \l__siunitx_number_out_prop { result } \l__siunitx_tmpa_tl } @@ -3160,7 +3188,8 @@ \tl_set:Nx \l__siunitx_tmpa_tl { \exp_not:V \l__siunitx_output_exponent_tl - { \exp_not:V \l__siunitx_tmpa_tl } + \exp_not:N \mathord + \exp_not:V \l__siunitx_tmpa_tl } } \prop_put:NnV \l__siunitx_number_out_prop { exponent-result } @@ -3171,11 +3200,6 @@ \prop_get:NnNT \l__siunitx_number_in_prop { mantissa-sign } \l__siunitx_tmpa_tl { - \bool_if:NT \l__siunitx_tight_bool - { - \tl_set:Nx \l__siunitx_tmpa_tl - { { \exp_not:V \l__siunitx_tmpa_tl } } - } \prop_get:NnN \l__siunitx_number_out_prop { exponent-result } \l__siunitx_tmpb_tl \__siunitx_tl_put_left_math:NV \l__siunitx_tmpb_tl @@ -3390,11 +3414,6 @@ } } \cs_new_protected:Npn \__siunitx_number_format_sign_aux:n #1 { - \bool_if:NT \l__siunitx_tight_bool - { - \tl_set:Nx \l__siunitx_tmpa_tl - { { \exp_not:V \l__siunitx_tmpa_tl } } - } \tl_clear:N \l__siunitx_tmpb_tl \tl_put_left:NV \l__siunitx_tmpb_tl \l__siunitx_tmpa_tl \prop_put:NnV \l__siunitx_number_out_prop { #1 -sign } @@ -3436,7 +3455,7 @@ \bool_if:NTF \l__siunitx_tight_bool { \tl_set:Nx \l__siunitx_tmpa_tl - { { \exp_not:V \l__siunitx_tmpa_tl } } + { \exp_not:N \mathord \exp_not:V \l__siunitx_tmpa_tl } } { \prop_if_in:NnT \l__siunitx_number_out_prop { mantissa } @@ -5154,8 +5173,8 @@ } \keys_set:nn { siunitx } { multi-part-units = brackets, - number-unit-product = \,, - product-units = repeat, + number-unit-product = \, , + product-units = repeat } \cs_new_protected:Npn \__siunitx_unit_output:nn #1#2 { \cs_set_eq:NN \__siunitx_unit_format_symbol_aux: @@ -5476,7 +5495,10 @@ { \tl_set_eq:NN \l__siunitx_tmpa_tl \l__siunitx_exponent_product_tl \bool_if:NT \l__siunitx_tight_bool - { \tl_set:Nx \l__siunitx_tmpa_tl { { \exp_not:o \l__siunitx_tmpa_tl } } } + { + \tl_set:Nx \l__siunitx_tmpa_tl + { \exp_not:N \mathord \exp_not:o \l__siunitx_tmpa_tl } + } \tl_set:Nx \l__siunitx_tmpa_tl { \exp_not:N \ensuremath { { } \exp_not:o \l__siunitx_tmpa_tl { } } @@ -5519,6 +5541,22 @@ \NC@find } } +\AtBeginDocument + { + \@ifpackageloaded { mdwtab } + { + \cs_set_protected:Npn \__siunitx_table_rewrite_create:N #1 + { + \newcolumntype {#1} [1] [] + { + > { \__siunitx_table_collect_begin:Nn #1 {##1} } + c + < { \__siunitx_table_print: } + } + } + } + { } + } \cs_new_protected:Npn \__siunitx_table_rewrite_create_aux:w { } \AtBeginDocument { \__siunitx_table_rewrite_create:N s } \AtBeginDocument { \__siunitx_table_rewrite_create:N S } @@ -5669,14 +5707,34 @@ \cs_set_eq:NN \__siunitx_table_print: \prg_do_nothing: \end } -\cs_new_protected:Npn \__siunitx_table_collect_not_braced:N #1 { - \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D - { - \token_if_eq_meaning:NNF #1 \tex_unskip:D - { \__siunitx_table_collect_not_braced_aux_i:N #1 } - } - \__siunitx_table_collect_next: -} +\cs_new_protected:Npn \__siunitx_table_collect_not_braced:N #1 + { + \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D + { + \token_if_eq_meaning:NNF #1 \tex_unskip:D + { \__siunitx_table_collect_not_braced_aux_i:N #1 } + } + \__siunitx_table_collect_next: + } +\AtBeginDocument + { + \@ifpackageloaded { mdwtab } + { + \cs_set_protected:Npn \__siunitx_table_collect_not_braced:N #1 + { + \token_if_eq_meaning:NNF #1 \tex_ignorespaces:D + { + \token_if_eq_meaning:NNF #1 \tex_unskip:D + { + \token_if_eq_meaning:NNF #1 \tab@setcr + { \__siunitx_table_collect_not_braced_aux_i:N #1 } + } + } + \__siunitx_table_collect_next: + } + } + { } + } \cs_new_protected:Npn \__siunitx_table_collect_not_braced_aux_i:N #1 { \cs_set:Npn \__siunitx_table_collect_not_braced_aux_ii:N ##1 { @@ -6485,9 +6543,12 @@ { \dim_set:Nn \l__siunitx_table_exponent_dim { \box_wd:N \l__siunitx_tmp_box } - \prop_if_in:NnTF \l__siunitx_number_out_prop { mantissa } - { \__siunitx_table_print_S_reserved_exponent_product: } - { \__siunitx_table_print_S_reserved_exponent_product_correction: } + \tl_if_empty:NT \l__siunitx_output_exponent_tl + { + \prop_if_in:NnTF \l__siunitx_number_out_prop { mantissa } + { \__siunitx_table_print_S_reserved_exponent_product: } + { \__siunitx_table_print_S_reserved_exponent_product_correction: } + } \hbox_set:Nn \l__siunitx_tmp_box { \__siunitx_print:nV { number } \l__siunitx_tmpa_tl } \bool_if:NTF \l__siunitx_table_align_exponent_bool @@ -6513,7 +6574,10 @@ { \tl_set_eq:NN \l__siunitx_tmpb_tl \l__siunitx_exponent_product_tl \bool_if:NT \l__siunitx_tight_bool - { \tl_set:Nx \l__siunitx_tmpb_tl { { \exp_not:o \l__siunitx_tmpb_tl } } } + { + \tl_set:Nx \l__siunitx_tmpb_tl + { \exp_not:N \mathord \exp_not:o \l__siunitx_tmpb_tl } + } \tl_set:Nx \l__siunitx_tmpa_tl { \exp_not:N \ensuremath { { } \exp_not:o \l__siunitx_tmpb_tl { } } @@ -7242,6 +7306,8 @@ { \seq_map_inline:Nn \l__siunitx_declare_list_seq { \__siunitx_unit_print_literal_aux:N ##1 } + \cs_if_exist:NT \FB@fg + { \cs_set_eq:NN \fg \FB@fg } \msg_redirect_name:nnn { xparse } { redefine-command } { none } \cs_set_eq:NN \num \__siunitx_bookmark_num:w \cs_set_eq:NN \numrange \__siunitx_bookmark_numrange:w @@ -7560,7 +7626,7 @@ { \__siunitx_unit_create_functions: } { \__siunitx_unit_create_empty_functions: } } -%% Copyright (C) 2008-2013 by +%% Copyright (C) 2008-2014 by %% Joseph Wright <joseph.wright@morningstar2.co.uk> %% %% It may be distributed and/or modified under the conditions of |