summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-06-01 23:06:48 +0000
committerKarl Berry <karl@freefriends.org>2010-06-01 23:06:48 +0000
commit060c4b2203467358024faca68cf5e648488a04ae (patch)
tree2dc51f2217ec3fa7ee12541ef4f202cf101d74c6
parentf4d364d450d3bb42f7a9d4904f9467dee51f9b45 (diff)
siunitx 2.0b (1jun10)
git-svn-id: svn://tug.org/texlive/trunk@18685 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/siunitx/siunitx.pdfbin470552 -> 476196 bytes
-rw-r--r--Master/texmf-dist/source/latex/siunitx/siunitx.dtx359
-rw-r--r--Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg2
-rw-r--r--Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg2
-rw-r--r--Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg126
-rw-r--r--Master/texmf-dist/tex/latex/siunitx/siunitx.sty34
6 files changed, 441 insertions, 82 deletions
diff --git a/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf b/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf
index c613d7cfe98..5810c4f34d8 100644
--- a/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf
+++ b/Master/texmf-dist/doc/latex/siunitx/siunitx.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/siunitx/siunitx.dtx b/Master/texmf-dist/source/latex/siunitx/siunitx.dtx
index 89f25d51cd8..a5663fbfec0 100644
--- a/Master/texmf-dist/source/latex/siunitx/siunitx.dtx
+++ b/Master/texmf-dist/source/latex/siunitx/siunitx.dtx
@@ -414,6 +414,8 @@ This work consists of the file siunitx.dtx
%\changes{v2.0a}{2010/05/28}{Include high energy physics units in
% discussion of old configurations and in \file{version-1}
% configuration file}
+%\changes{v2.0b}{2010/06/01}{Further improvements to \file{version-1}
+% configuration file}
%
%\begin{abstract}
% Typesetting values with units requires care to ensure that the
@@ -2183,7 +2185,7 @@ This work consists of the file siunitx.dtx
% should update their source to use the new interfaces and functions.
%
% Users upgrading from version 1 of \pkg{siunitx} will notice that
-% the various \enquote{specialist} units available in version 1 are
+% the various \enquote{specialist} units available in version 1 are
% no longer provided as loadable options.\footnote{They are included
% in the loaded configuration file \opt{version-1}, but this is intended
% purely to ease transition to version 2.} These are not included in
@@ -3356,6 +3358,177 @@ This work consists of the file siunitx.dtx
% \si[sticky-per]{\candela\per\kWh}
%\end{LaTeXdemo}
%
+%\section{Information for those upgrading from version 1}
+%
+% The key--value control system of \pkg{siunitx} has been completely
+% rewritten for version 2, and at the same time some of the macros
+% provided by the package have been renamed and reworked. The package
+% can be loaded with a configuration file to provide most of the
+% same options and defaults as in version 1:
+%\begin{LaTeXdemo}[code only]
+% \usepackage[load-configurations = version-1]{siunitx}
+%\end{LaTeXdemo}
+% Many of the options from version 1 map to similar ones in version 2
+% (\cref{tab:opt:map}). The correspondence often includes a syntax
+% change: consult details of the new options for the correct syntax for
+% the new options. In some places the new behaviour is fundamentally
+% different to version 1, and as a result some options from version 1
+% are simply ignored by the new code. These cases are not included in
+% the table.
+%\begin{center}
+% \tablecaption{Mapping of version 1 options to version 2.}
+% \label{tab:opt:map}
+% \tablefirsthead{^^A
+% \toprule
+% \multicolumn{1}{l}{Version 1} &
+% \multicolumn{1}{l}{See in version 2} \\
+% \midrule
+% }
+% \tablehead{^^A
+% \multicolumn{2}{l}{\emph{Continued from previous page}} \\
+% \toprule
+% \multicolumn{1}{l}{Version 1} &
+% \multicolumn{1}{l}{See in version 2} \\
+% \midrule
+% }
+% \tabletail{^^A
+% \bottomrule
+% \multicolumn{2}{r}{\emph{Continued on next page}} \\
+% }
+% \tablelasttail{\bottomrule}
+%
+% \begin{xtabular}{>{\ttfamily}l>{\ttfamily}l}
+% addsign & explicit-sign \\
+% allowlitunits & free-standing-units \\
+% allowoptarg & unit-optional-argument \\
+% allowzeroexp & retain-zero-exponent \\
+% anglesep & arc-separator \\
+% astroang & angle-symbol-over-decimal \\
+% closeerr & close-bracket \\
+% closefrac & close-bracket \\
+% closerange & close-bracket \\
+% colour & color \\
+% decimalsymbol & output-decimal-marker \\
+% detectdisplay & detect-display-math \\
+% digitsep & group-separator \\
+% dp & round-mode \\
+% & round-precision \\
+% errspace & uncertainty-separator \\
+% expbase & exponent-base \\
+% expproduct & exponent-product \\
+% fixdp & round-mode \\
+% fixsf & round-mode \\
+% fraction & fraction-function \\
+% inlinebold & detect-inline-weight \\
+% mathOmega & math-ohm \\
+% mathcelsius & math-celsius \\
+% mathdegree & math-degree \\
+% mathminute & math-arcminute \\
+% mathmu & math-micro \\
+% mathringA & math-angstrom \\
+% mathrm & math-rm \\
+% mathsOmega & math-ohm \\
+% mathscelsius & math-celsius \\
+% mathsdegree & math-degree \\
+% mathsecond & math-arcsecond \\
+% mathsf & math-sf \\
+% mathsminute & math-arcminute \\
+% mathsmu & math-micro \\
+% mathsringA & math-angstrom \\
+% mathsrm & math-rm \\
+% mathssecond & math-arcsecond \\
+% mathssf & math-sf \\
+% mathstt & math-tt \\
+% mathtt & math-tt \\
+% mode & mode \\
+% negcolor & negative-color \\
+% negcolour & negative-color \\
+% numaddn & input-symbols \\
+% numcloseerr & input-close-uncertainty \\
+% numdecimal & input-decimal-markers \\
+% numdigits & input-digits \\
+% numdiv & input-quotient \\
+% numexp & input-exponent-markers \\
+% numgobble & input-ignore \\
+% numopenerr & input-open-uncertainty \\
+% numprod & input-product \\
+% numsign & input-signs \\
+% obeyall & detect-all \\
+% obeybold & detect-weight \\
+% obeyfamily & detect-family \\
+% obeyitalic & detect-italic \\
+% obeymode & detect-mode \\
+% openerr & open-bracket \\
+% openfrac & open-bracket \\
+% openrange & open-bracket \\
+% padangle & add-arc-degree-zero \\
+% & add-arc-minute-zero \\
+% & add-arc-second-zero \\
+% padnumber & add-decimal-zero \\
+% & add-integer-zero \\
+% per & per-mode \\
+% prefixsymbolic & prefixes-as-symbols \\
+% prespace & space-before-unit \\
+% redefsymbols & redefine-symbols \\
+% repeatunits & multi-part-units \\
+% & product-units \\
+% retainplus & retain-explicit-plus \\
+% seperr & separate-uncertainty \\
+% sepfour & group-four-digits \\
+% sf & round-mode \\
+% & round-precision \\
+% sign & explicit-sign \\
+% slash & per-symbol \\
+% stickyper & sticky-per \\
+% strict & strict \\
+% tabalign & table-alignment \\
+% tabautofit & table-auto-round \\
+% tabformat & table-format \\
+% tabnumalign & table-number-alignment \\
+% tabparseonly & table-parse-only \\
+% tabtextalign & table-text-alignment \\
+% tabunitalign & table-unit-alignment \\
+% textcelsius & text-celsius \\
+% textdegree & text-degree \\
+% textminute & text-arcminute \\
+% textmode & mode \\
+% textmu & text-micro \\
+% textOmega & text-ohm \\
+% textringA & text-angstrom \\
+% textrm & text-rm \\
+% textsecond & text-arcsecond \\
+% textsf & text-sf \\
+% texttt & text-tt \\
+% tightpm & tight-spacing \\
+% tophrase & range-phrase \\
+% trapambigerr & multi-part-units \\
+% trapambigfrac & bracket-numbers \\
+% trapambigrange & range-units \\
+% unitcolor & unit-color \\
+% unitcolour & unit-color \\
+% unitmathrm & unit-math-rm \\
+% unitmathsf & unit-math-sf \\
+% unitmathsrm & unit-math-rm \\
+% unitmathssf & unit-math-sf \\
+% unitmathstt & unit-math-tt \\
+% unitmathtt & unit-math-tt \\
+% unitmode & unit-mode \\
+% unitsep & inter-unit-separator \\
+% unitspace & inter-unit-separator \\
+% 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 \\
+% valuemode & value-mode \\
+% valuesep & number-unit-separator \\
+% xspace & use-xparse \\
+% \end{xtabular}
+%\end{center}
+%
%\section{Correct application of (SI) units}
%
% Consistent and logical units are a necessity for scientific work,
@@ -3702,7 +3875,7 @@ This work consists of the file siunitx.dtx
%
% The usual preliminaries.
% \begin{macrocode}
-\ProvidesExplPackage {siunitx} {2010/05/28} {2.0a}
+\ProvidesExplPackage {siunitx} {2010/06/01} {2.0b}
{A comprehensive (SI) units package}
% \end{macrocode}
%
@@ -3872,6 +4045,7 @@ This work consists of the file siunitx.dtx
\_siunitx_tmp:w { closeerr }
\_siunitx_tmp:w { closrfrac }
\_siunitx_tmp:w { closerange }
+\_siunitx_tmp:w { colour }
\_siunitx_tmp:w { colorall }
\_siunitx_tmp:w { colourall }
\_siunitx_tmp:w { colorneg }
@@ -3895,6 +4069,8 @@ This work consists of the file siunitx.dtx
\_siunitx_tmp:w { fixsf }
\_siunitx_tmp:w { fraction }
\_siunitx_tmp:w { inlinebold }
+\_siunitx_tmp:w { locale }
+\_siunitx_tmp:w { loctolang }
\_siunitx_tmp:w { log }
\_siunitx_tmp:w { load }
\_siunitx_tmp:w { mathOmega }
@@ -3932,6 +4108,7 @@ This work consists of the file siunitx.dtx
\_siunitx_tmp:w { numsign }
\_siunitx_tmp:w { obeyall }
\_siunitx_tmp:w { obeybold }
+\_siunitx_tmp:w { obeyfamily }
\_siunitx_tmp:w { obeymode }
\_siunitx_tmp:w { obeyitalic }
\_siunitx_tmp:w { openerr }
@@ -4030,6 +4207,22 @@ This work consists of the file siunitx.dtx
}
}
}
+\AtBeginDocument {
+ \keys_define:nn { siunitx } {
+ unknown .code:n =
+ {
+ \seq_if_in:NVTF \_c_siunitx_old_options_seq \l_keys_key_tl
+ {
+ \msg_error:nnx { siunitx } { version-1-option }
+ { \exp_not:V \l_keys_key_tl }
+ }
+ {
+ \msg_error:nnx { siunitx } { unknown-option }
+ { \exp_not:V \l_keys_key_tl }
+ }
+ }
+}
+}
% \end{macrocode}
%\end{macro}
%
@@ -8009,7 +8202,7 @@ This work consists of the file siunitx.dtx
}
{
\IfNoValueTF {#3}
- { \_siunitx_error:nn { invalid-arc-format } { #1 ; #2 } }
+ { \_siunitx_error:nx { invalid-arc-format } { #1 ; #2 } }
{ \_siunitx_angle_output_aux:nnn {#1} {#2} {#3} }
}
}
@@ -12134,10 +12327,14 @@ This work consists of the file siunitx.dtx
The~option~file~'#1'~is~not~known~by~siunitx: \\
perhaps~it~is~spelled~incorrectly.
}
-\msg_set:nnn { siunitx } { version-1-option }
- {
- Version~1~option~'#1'~detected: \\
- loading~compatibility~code.
+\msg_set:nnnn { siunitx } { version-1-option }
+ { Version~1~option~'#1'~detected. }
+ {
+ Use: \\
+ \c_space_tl \c_space_tl
+ \token_to_str:N \usepackage[load-configurations = version-1]
+ \token_to_str:N { siunitx \token_to_str:N } \\
+ in~the~preamble~to~load~the~appropriate~code.
}
% \end{macrocode}
%
@@ -12905,13 +13102,14 @@ This work consists of the file siunitx.dtx
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplFile {siunitx-version-1.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-version-1.cfg} {2010/06/01} {2.0b}
{siunitx: Version 1 settings}
% \end{macrocode}
%
% The abbreviations are loaded by default be version one.
% \begin{macrocode}
-\keys_set:nn { siunitx } { load-configurations = abbreviations }
+\keys_set:nn { siunitx }
+ { load-configurations = { abbreviations , binary } }
% \end{macrocode}
%
% The re-arrangements made to the code in version two, and in particular
@@ -12921,9 +13119,17 @@ This work consists of the file siunitx.dtx
% \begin{macrocode}
\keys_define:nn { siunitx } {
addsign .choice: ,
+ addsign /
+ all .meta:n = { explicit-sign = + },
+ addsign /
+ exp .meta:n = { explicit-sign = + },
addsign /
false .meta:n = { explicit-sign = },
addsign /
+ mant .meta:n = { explicit-sign = + },
+ addsign /
+ none .meta:n = { explicit-sign = },
+ addsign /
true .meta:n = { explicit-sign = + },
addsign .default:n = { true },
allowlitunits .meta:n = { free-standing-units = #1 },
@@ -12974,6 +13180,7 @@ This work consists of the file siunitx.dtx
closeerr .meta:n = { close-bracket = #1 },
closefrac .meta:n = { close-bracket = #1 },
closerange .meta:n = { close-bracket = #1 },
+ colour .code:n = { color = #1 },
colorall .code:n = ,
colourall .code:n = ,
colorneg .code:n = ,
@@ -13064,6 +13271,7 @@ This work consists of the file siunitx.dtx
two .meta:n = { exponent-base = 2 },
expbase /
unknown .meta:n = { exponent-base = #1 },
+ expproduct .choice: ,
expproduct /
cdot .meta:n =
{ exponent-product = { } \cdot { } },
@@ -13103,8 +13311,10 @@ This work consists of the file siunitx.dtx
per-mode = symbol-or-fraction
},
inlinebold .meta:n = { detect-inline-weight = #1 },
+ locale .code:n = ,
log .code:n = ,
load .code:n = ,
+ loctolang .code:n = ,
mathOmega .meta:n = { math-ohm = #1 },
mathcelsius .meta:n = { math-celsius = #1 },
mathdegree .meta:n = { math-degree = #1 },
@@ -13148,6 +13358,8 @@ This work consists of the file siunitx.dtx
obeyall .default:n = { true },
obeybold .meta:n = { detect-weight = #1 },
obeybold .default:n = { true },
+ obeyfamily .meta:n = { detect-family = #1 },
+ obeyfamily .default:n = { true },
obeyitalic .meta:n = { detect-italic = #1 },
obeyitalic .default:n = { true },
obeymode .meta:n = { detect-mode = #1 },
@@ -13163,6 +13375,7 @@ This work consists of the file siunitx.dtx
add-arc-minute-zero = true,
add-arc-second-zero = true
},
+ padangle /
both .meta:n =
{
add-arc-degree-zero = true,
@@ -13246,7 +13459,9 @@ This work consists of the file siunitx.dtx
add-decimal-zero = true,
add-integer-zero = true
},
- per .choice: ,
+ per .choice: ,
+ per /
+ frac .meta:n = { per-mode = fraction },
per /
fraction .meta:n = { per-mode = fraction },
per /
@@ -13265,19 +13480,19 @@ This work consists of the file siunitx.dtx
repeatunits /
false .meta:n =
{
- multi-part-numbers = single,
+ multi-part-units = single,
product-units = single,
},
repeatunits /
power .meta:n =
{
- multi-part-numbers = repeat,
+ multi-part-units = repeat,
product-units = power,
},
repeatunits /
true .meta:n =
{
- multi-part-numbers = repeat,
+ multi-part-units = repeat,
product-units = repeat,
},
repeatunits .default:n = { true },
@@ -13297,24 +13512,57 @@ This work consists of the file siunitx.dtx
slash /
slash .meta:n = { per-symbol = / },
slash /
- unknown .meta:n = { per symbol = #1 },
+ unknown .meta:n = { per-symbol = #1 },
stickyper .meta:n = { sticky-per = #1 },
stickyper .default:n = { true },
strictarc .code:n = ,
- tabalign .meta:n =
+ tabalign .code:n =
{
- table-number-alignment = #1,
- table-text-alignment = #1,
- table-unit-alignment = #1
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-alignment = center } }
+ { \keys_set:nn { siunitx } { table-alignment = #1 } }
},
tabalignexp .code:n = ,
tabautofit .meta:n = { table-auto-round = #1 },
+ tabautofit .default:n = { true },
tabformat .meta:n = { table-format = #1 },
- tabnumalign .meta:n = { table-number-alignment = #1 },
+ tabnumalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-number-alignment = center } }
+ {
+ \tl_if_eq:nnTF {#1} { centredecimal }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = center-decimal-marker }
+ }
+ {
+ \tl_if_eq:nnTF {#1} { centerdecimal }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = center-decimal-marker }
+ }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = #1 }
+ }
+ }
+ }
+ },
tabparseonly .meta:n = { table-parse-only = #1 },
tabparseonly .default:n = { true },
- tabtextalign .meta:n = { table-text-numbers = #1 },
- tabunitalign .meta:n = { table-unit-alignment = #1 },
+ tabtextalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-text-alignment = center } }
+ { \keys_set:nn { siunitx } { table-text-alignment = #1 } }
+ },
+ tabunitalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-unit-alignment = center } }
+ { \keys_set:nn { siunitx } { table-unit-alignment = #1 } }
+ },
textOmega .meta:n = { text-ohm = #1 },
textcelsius .meta:n = { text-celsius = #1 },
textdegree .meta:n = { text-degree = #1 },
@@ -13433,39 +13681,39 @@ This work consists of the file siunitx.dtx
valuesep .choice: ,
valuesep /
cdot .meta:n =
- { unit-value-separator = { } \cdot { } },
+ { number-unit-separator = { } \cdot { } },
valuesep /
- comma .meta:n = { unit-value-separator = { {,} } },
+ comma .meta:n = { number-unit-separator = { {,} } },
valuesep /
- fullstop .meta:n = { unit-value-separator = { { . } } },
+ fullstop .meta:n = { number-unit-separator = { { . } } },
valuesep /
- med .meta:n = { unit-value-separator = \: },
+ med .meta:n = { number-unit-separator = \: },
valuesep /
- medium .meta:n = { unit-value-separator = \: },
+ medium .meta:n = { number-unit-separator = \: },
valuesep /
- none .meta:n = { unit-value-separator = },
+ none .meta:n = { number-unit-separator = },
valuesep /
- period .meta:n = { unit-value-separator = { { . } } },
+ period .meta:n = { number-unit-separator = { { . } } },
valuesep /
- space .meta:n = { unit-value-separator = \text { ~ } },
+ space .meta:n = { number-unit-separator = \text { ~ } },
valuesep /
- stop .meta:n = { unit-value-separator = { { . } } },
+ stop .meta:n = { number-unit-separator = { { . } } },
valuesep /
- thick .meta:n = { unit-value-separator = \; },
+ thick .meta:n = { number-unit-separator = \; },
valuesep /
- thin .meta:n = { unit-value-separator = \, },
+ thin .meta:n = { number-unit-separator = \, },
valuesep /
tightcdot .meta:n =
- { unit-value-separator = \bgroup \cdot \egroup },
+ { number-unit-separator = \bgroup \cdot \egroup },
valuesep /
tighttimes .meta:n =
- { unit-value-separator = \bgroup \times \egroup },
+ { number-unit-separator = \bgroup \times \egroup },
valuesep /
- times .meta:n = { unit-value-separator = \times },
+ times .meta:n = { number-unit-separator = \times },
valuesep /
- unknown .meta:n = { unit-value-separator = #1 },
+ unknown .meta:n = { number-unit-separator = #1 },
xspace .meta:n = { use-xspace = #1 },
- xpace .default:n = { true }
+ xpace .default:n = { true },
}
% \end{macrocode}
%
@@ -13566,9 +13814,11 @@ This work consists of the file siunitx.dtx
%\begin{macro}{\providequalifier}
% The functions for creating qualifiers are easy to create again.
% \begin{macrocode}
-\cs_set_eq:NN \newqualifier \DeclareSIQualifier
-\cs_set_eq:NN \renewqualifier \DeclareSIQualifier
-\cs_set_eq:NN \providequalifier \DeclareSIQualifier
+\NewDocumentCommand \newqualifier { m m } {
+ \_siunitx_declare_qualifier:Nn #1 {#2}
+}
+\cs_set_eq:NN \renewqualifier \newqualifier
+\cs_set_eq:NN \providequalifier \newqualifier
% \end{macrocode}
%\end{macro}
%\end{macro}
@@ -13685,6 +13935,31 @@ This work consists of the file siunitx.dtx
%\end{macro}
%\end{macro}
%
+%\begin{macro}{\centimetrecubed}
+%\begin{macro}{\centimetresquared}
+%\begin{macro}{\cubiccentimetre}
+%\begin{macro}{\cubicdecimetre}
+%\begin{macro}{\squarecentimetre}
+%\begin{macro}{\squaremetre}
+%\begin{macro}{\squarekilometre}
+% Units from version one that did not seem like a good idea to retain.
+% \begin{macrocode}
+\DeclareSIUnit \centimetrecubed { \centi \metre \cubed }
+\DeclareSIUnit \centimetresquared { \centi \metre \squared }
+\DeclareSIUnit \cubiccentimetre { \centi \metre \cubed }
+\DeclareSIUnit \cubicdecimetre { \deci \metre \cubed }
+\DeclareSIUnit \squarecentimetre { \centi \metre \squared }
+\DeclareSIUnit \squaremetre { \metre \squared }
+\DeclareSIUnit \squarekilometre { \kilo \metre \squared }
+% \end{macrocode}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%\end{macro}
+%
%\begin{macro}{\parsec}
%\begin{macro}{\lightyear}
% A few units for astronomy that version 1 provided.
@@ -13793,7 +14068,7 @@ This work consists of the file siunitx.dtx
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplFile {siunitx-abbreviations.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-abbreviations.cfg} {2010/06/01} {2.0b}
{siunitx: Abbreviated units}
% \end{macrocode}
%
@@ -14001,7 +14276,7 @@ This work consists of the file siunitx.dtx
% \end{macrocode}
%
% \begin{macrocode}
-\ProvidesExplFile {siunitx-binary.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-binary.cfg} {2010/06/01} {2.0b}
{siunitx: Binary units}
% \end{macrocode}
%
diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg
index cfa9241cd4d..b1fdb37b386 100644
--- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg
+++ b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-abbreviations.cfg
@@ -13,7 +13,7 @@
%% See http://www.latex-project.org/lppl.txt
%% ---------------------------------------------------------------
%%
-\ProvidesExplFile {siunitx-abbreviations.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-abbreviations.cfg} {2010/06/01} {2.0b}
{siunitx: Abbreviated units}
\DeclareSIUnit \pA { \pico \ampere }
\DeclareSIUnit \nA { \nano \ampere }
diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg
index 3db2a7eb0dd..81912d50d4a 100644
--- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg
+++ b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-binary.cfg
@@ -13,7 +13,7 @@
%% See http://www.latex-project.org/lppl.txt
%% ---------------------------------------------------------------
%%
-\ProvidesExplFile {siunitx-binary.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-binary.cfg} {2010/06/01} {2.0b}
{siunitx: Binary units}
\DeclareBinaryPrefix \kibi { Ki } { 10 }
\DeclareBinaryPrefix \mebi { Mi } { 20 }
diff --git a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg
index 790ecfc3f67..ddeb173e1cf 100644
--- a/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg
+++ b/Master/texmf-dist/tex/latex/siunitx/config/siunitx-version-1.cfg
@@ -13,14 +13,23 @@
%% See http://www.latex-project.org/lppl.txt
%% ---------------------------------------------------------------
%%
-\ProvidesExplFile {siunitx-version-1.cfg} {2010/05/28} {2.0a}
+\ProvidesExplFile {siunitx-version-1.cfg} {2010/06/01} {2.0b}
{siunitx: Version 1 settings}
-\keys_set:nn { siunitx } { load-configurations = abbreviations }
+\keys_set:nn { siunitx }
+ { load-configurations = { abbreviations , binary } }
\keys_define:nn { siunitx } {
addsign .choice: ,
addsign /
+ all .meta:n = { explicit-sign = + },
+ addsign /
+ exp .meta:n = { explicit-sign = + },
+ addsign /
false .meta:n = { explicit-sign = },
addsign /
+ mant .meta:n = { explicit-sign = + },
+ addsign /
+ none .meta:n = { explicit-sign = },
+ addsign /
true .meta:n = { explicit-sign = + },
addsign .default:n = { true },
allowlitunits .meta:n = { free-standing-units = #1 },
@@ -71,6 +80,7 @@
closeerr .meta:n = { close-bracket = #1 },
closefrac .meta:n = { close-bracket = #1 },
closerange .meta:n = { close-bracket = #1 },
+ colour .code:n = { color = #1 },
colorall .code:n = ,
colourall .code:n = ,
colorneg .code:n = ,
@@ -161,6 +171,7 @@
two .meta:n = { exponent-base = 2 },
expbase /
unknown .meta:n = { exponent-base = #1 },
+ expproduct .choice: ,
expproduct /
cdot .meta:n =
{ exponent-product = { } \cdot { } },
@@ -200,8 +211,10 @@
per-mode = symbol-or-fraction
},
inlinebold .meta:n = { detect-inline-weight = #1 },
+ locale .code:n = ,
log .code:n = ,
load .code:n = ,
+ loctolang .code:n = ,
mathOmega .meta:n = { math-ohm = #1 },
mathcelsius .meta:n = { math-celsius = #1 },
mathdegree .meta:n = { math-degree = #1 },
@@ -245,6 +258,8 @@
obeyall .default:n = { true },
obeybold .meta:n = { detect-weight = #1 },
obeybold .default:n = { true },
+ obeyfamily .meta:n = { detect-family = #1 },
+ obeyfamily .default:n = { true },
obeyitalic .meta:n = { detect-italic = #1 },
obeyitalic .default:n = { true },
obeymode .meta:n = { detect-mode = #1 },
@@ -260,6 +275,7 @@
add-arc-minute-zero = true,
add-arc-second-zero = true
},
+ padangle /
both .meta:n =
{
add-arc-degree-zero = true,
@@ -343,7 +359,9 @@
add-decimal-zero = true,
add-integer-zero = true
},
- per .choice: ,
+ per .choice: ,
+ per /
+ frac .meta:n = { per-mode = fraction },
per /
fraction .meta:n = { per-mode = fraction },
per /
@@ -362,19 +380,19 @@
repeatunits /
false .meta:n =
{
- multi-part-numbers = single,
+ multi-part-units = single,
product-units = single,
},
repeatunits /
power .meta:n =
{
- multi-part-numbers = repeat,
+ multi-part-units = repeat,
product-units = power,
},
repeatunits /
true .meta:n =
{
- multi-part-numbers = repeat,
+ multi-part-units = repeat,
product-units = repeat,
},
repeatunits .default:n = { true },
@@ -394,24 +412,57 @@
slash /
slash .meta:n = { per-symbol = / },
slash /
- unknown .meta:n = { per symbol = #1 },
+ unknown .meta:n = { per-symbol = #1 },
stickyper .meta:n = { sticky-per = #1 },
stickyper .default:n = { true },
strictarc .code:n = ,
- tabalign .meta:n =
+ tabalign .code:n =
{
- table-number-alignment = #1,
- table-text-alignment = #1,
- table-unit-alignment = #1
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-alignment = center } }
+ { \keys_set:nn { siunitx } { table-alignment = #1 } }
},
tabalignexp .code:n = ,
tabautofit .meta:n = { table-auto-round = #1 },
+ tabautofit .default:n = { true },
tabformat .meta:n = { table-format = #1 },
- tabnumalign .meta:n = { table-number-alignment = #1 },
+ tabnumalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-number-alignment = center } }
+ {
+ \tl_if_eq:nnTF {#1} { centredecimal }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = center-decimal-marker }
+ }
+ {
+ \tl_if_eq:nnTF {#1} { centerdecimal }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = center-decimal-marker }
+ }
+ {
+ \keys_set:nn { siunitx }
+ { table-number-alignment = #1 }
+ }
+ }
+ }
+ },
tabparseonly .meta:n = { table-parse-only = #1 },
tabparseonly .default:n = { true },
- tabtextalign .meta:n = { table-text-numbers = #1 },
- tabunitalign .meta:n = { table-unit-alignment = #1 },
+ tabtextalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-text-alignment = center } }
+ { \keys_set:nn { siunitx } { table-text-alignment = #1 } }
+ },
+ tabunitalign .code:n =
+ {
+ \tl_if_eq:nnTF {#1} { centre }
+ { \keys_set:nn { siunitx } { table-unit-alignment = center } }
+ { \keys_set:nn { siunitx } { table-unit-alignment = #1 } }
+ },
textOmega .meta:n = { text-ohm = #1 },
textcelsius .meta:n = { text-celsius = #1 },
textdegree .meta:n = { text-degree = #1 },
@@ -530,39 +581,39 @@
valuesep .choice: ,
valuesep /
cdot .meta:n =
- { unit-value-separator = { } \cdot { } },
+ { number-unit-separator = { } \cdot { } },
valuesep /
- comma .meta:n = { unit-value-separator = { {,} } },
+ comma .meta:n = { number-unit-separator = { {,} } },
valuesep /
- fullstop .meta:n = { unit-value-separator = { { . } } },
+ fullstop .meta:n = { number-unit-separator = { { . } } },
valuesep /
- med .meta:n = { unit-value-separator = \: },
+ med .meta:n = { number-unit-separator = \: },
valuesep /
- medium .meta:n = { unit-value-separator = \: },
+ medium .meta:n = { number-unit-separator = \: },
valuesep /
- none .meta:n = { unit-value-separator = },
+ none .meta:n = { number-unit-separator = },
valuesep /
- period .meta:n = { unit-value-separator = { { . } } },
+ period .meta:n = { number-unit-separator = { { . } } },
valuesep /
- space .meta:n = { unit-value-separator = \text { ~ } },
+ space .meta:n = { number-unit-separator = \text { ~ } },
valuesep /
- stop .meta:n = { unit-value-separator = { { . } } },
+ stop .meta:n = { number-unit-separator = { { . } } },
valuesep /
- thick .meta:n = { unit-value-separator = \; },
+ thick .meta:n = { number-unit-separator = \; },
valuesep /
- thin .meta:n = { unit-value-separator = \, },
+ thin .meta:n = { number-unit-separator = \, },
valuesep /
tightcdot .meta:n =
- { unit-value-separator = \bgroup \cdot \egroup },
+ { number-unit-separator = \bgroup \cdot \egroup },
valuesep /
tighttimes .meta:n =
- { unit-value-separator = \bgroup \times \egroup },
+ { number-unit-separator = \bgroup \times \egroup },
valuesep /
- times .meta:n = { unit-value-separator = \times },
+ times .meta:n = { number-unit-separator = \times },
valuesep /
- unknown .meta:n = { unit-value-separator = #1 },
+ unknown .meta:n = { number-unit-separator = #1 },
xspace .meta:n = { use-xspace = #1 },
- xpace .default:n = { true }
+ xpace .default:n = { true },
}
\keys_define:nn { siunitx } {
unknown .code:n =
@@ -612,9 +663,11 @@
{ \DeclareSIPrefix #2 {#3} {#4} }
{ \DeclareBinaryPrefix #2 {#3} {#4} }
}
-\cs_set_eq:NN \newqualifier \DeclareSIQualifier
-\cs_set_eq:NN \renewqualifier \DeclareSIQualifier
-\cs_set_eq:NN \providequalifier \DeclareSIQualifier
+\NewDocumentCommand \newqualifier { m m } {
+ \_siunitx_declare_qualifier:Nn #1 {#2}
+}
+\cs_set_eq:NN \renewqualifier \newqualifier
+\cs_set_eq:NN \providequalifier \newqualifier
\DeclareSIPrePower \Square { 2 }
\DeclareSIPrePower \ssquare { 2 }
\DeclareSIUnit \BAR { \bar }
@@ -646,6 +699,13 @@
\DeclareSIUnit \cmc { \centi \metre \cubed }
\DeclareSIUnit \dmc { \deci \metre \cubed }
\DeclareSIUnit \cms { \centi \metre \squared }
+\DeclareSIUnit \centimetrecubed { \centi \metre \cubed }
+\DeclareSIUnit \centimetresquared { \centi \metre \squared }
+\DeclareSIUnit \cubiccentimetre { \centi \metre \cubed }
+\DeclareSIUnit \cubicdecimetre { \deci \metre \cubed }
+\DeclareSIUnit \squarecentimetre { \centi \metre \squared }
+\DeclareSIUnit \squaremetre { \metre \squared }
+\DeclareSIUnit \squarekilometre { \kilo \metre \squared }
\DeclareSIUnit \parsec { pc }
\DeclareSIUnit \lightyear { ly }
\DeclareSIUnit \gmol { g \text { - } mol }
diff --git a/Master/texmf-dist/tex/latex/siunitx/siunitx.sty b/Master/texmf-dist/tex/latex/siunitx/siunitx.sty
index 97211e1db54..f655f1b034b 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}
-\ProvidesExplPackage {siunitx} {2010/05/28} {2.0a}
+\ProvidesExplPackage {siunitx} {2010/06/01} {2.0b}
{A comprehensive (SI) units package}
\msg_set:nnnn { siunitx } { incompatible-package }
{ Package~'#1'~incompatible. }
@@ -94,6 +94,7 @@
\_siunitx_tmp:w { closeerr }
\_siunitx_tmp:w { closrfrac }
\_siunitx_tmp:w { closerange }
+\_siunitx_tmp:w { colour }
\_siunitx_tmp:w { colorall }
\_siunitx_tmp:w { colourall }
\_siunitx_tmp:w { colorneg }
@@ -117,6 +118,8 @@
\_siunitx_tmp:w { fixsf }
\_siunitx_tmp:w { fraction }
\_siunitx_tmp:w { inlinebold }
+\_siunitx_tmp:w { locale }
+\_siunitx_tmp:w { loctolang }
\_siunitx_tmp:w { log }
\_siunitx_tmp:w { load }
\_siunitx_tmp:w { mathOmega }
@@ -154,6 +157,7 @@
\_siunitx_tmp:w { numsign }
\_siunitx_tmp:w { obeyall }
\_siunitx_tmp:w { obeybold }
+\_siunitx_tmp:w { obeyfamily }
\_siunitx_tmp:w { obeymode }
\_siunitx_tmp:w { obeyitalic }
\_siunitx_tmp:w { openerr }
@@ -246,6 +250,22 @@
}
}
}
+\AtBeginDocument {
+ \keys_define:nn { siunitx } {
+ unknown .code:n =
+ {
+ \seq_if_in:NVTF \_c_siunitx_old_options_seq \l_keys_key_tl
+ {
+ \msg_error:nnx { siunitx } { version-1-option }
+ { \exp_not:V \l_keys_key_tl }
+ }
+ {
+ \msg_error:nnx { siunitx } { unknown-option }
+ { \exp_not:V \l_keys_key_tl }
+ }
+ }
+}
+}
\clist_new:N \_l_siunitx_option_deactivate_clist
\cs_set_protected_nopar:Npn \_siunitx_option_deactivate:n #1 {
\clist_put_right:Nn \_l_siunitx_option_deactivate_clist {#1}
@@ -2831,7 +2851,7 @@
}
{
\IfNoValueTF {#3}
- { \_siunitx_error:nn { invalid-arc-format } { #1 ; #2 } }
+ { \_siunitx_error:nx { invalid-arc-format } { #1 ; #2 } }
{ \_siunitx_angle_output_aux:nnn {#1} {#2} {#3} }
}
}
@@ -5573,10 +5593,14 @@
The~option~file~'#1'~is~not~known~by~siunitx: \\
perhaps~it~is~spelled~incorrectly.
}
-\msg_set:nnn { siunitx } { version-1-option }
+\msg_set:nnnn { siunitx } { version-1-option }
+ { Version~1~option~'#1'~detected. }
{
- Version~1~option~'#1'~detected: \\
- loading~compatibility~code.
+ Use: \\
+ \c_space_tl \c_space_tl
+ \token_to_str:N \usepackage[load-configurations = version-1]
+ \token_to_str:N { siunitx \token_to_str:N } \\
+ in~the~preamble~to~load~the~appropriate~code.
}
\cs_set_protected_nopar:Npn \DeclareBinaryPrefix #1#2#3 {
\_siunitx_declare_prefix:Nnnn #1 {#2} { 2 } {#3}