Skip to content
Snippets Groups Projects
Commit 2021574e authored by Rolf Niepraschk's avatar Rolf Niepraschk
Browse files

in \printResultTable: "print-zero-exponent=true" only for the first 3 columns

parent 1edf036c
No related branches found
No related tags found
No related merge requests found
......@@ -285,16 +285,33 @@ footskip=0bp,
\RequirePackage{siunitx-PTB}
\newcounter{ks@colNum}
\newcounter{ks@colMax}
\newcommand*\ks@siTabColSet{%
\ifnum\c@ks@colNum < 3 % nur für erste 3 Spalten 0-Exponent verwenden
\sisetup{print-zero-exponent = true}%
\else
\sisetup{print-zero-exponent = false}%
\fi
\stepcounter{ks@colNum}%
\ifnum\c@ks@colNum = \c@ks@colMax
\setcounter{ks@colNum}{0}%
\fi
}
\newcolumntype{R}{>{\ks@siTabColSet}r}% rechtsbündig mit untersch. 0-Exponent
\newcommand\resultTable[3][]{%
%\begingroup
\@tempcntb=#2 %
\c@ks@colMax=#2 %
\edef\@tempa{\noexpand\begin{longtable}{%
@{\noexpand\extracolsep{\fill}}*\the\@tempcntb r
@{\noexpand\extracolsep{\fill}}*\the\c@ks@colMax R
}}%
\expandafter\ks@add\expandafter{\@tempa}%
\ks@add{\toprule}%
\ifx\relax#1\relax\else
\edef\@tempa{\noexpand\multicolumn{\the\@tempcntb}{@{}c@{}}{#1}%
\edef\@tempa{\noexpand\multicolumn{\the\c@ks@colMax}{@{}c@{}}{#1}%
\noexpand\\\noexpand\toprule}%
\expandafter\ks@add\expandafter{\@tempa}%
%\showthe\ks@tab
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment