\ExplSyntaxOn
\dim_new:N \l_kivi_tab_desc_dim
+\dim_new:N \l_kivi_tab_desc_leftskip_dim
\bool_new:N \l_kivi_col_desc_bool
\bool_set_true:N \l_kivi_col_desc_bool
}
% set default values for colwidth
-\dim_set:Nn \l_kivi_tab_pos_dim {3.5ex}
+\dim_set:Nn \l_kivi_tab_pos_dim {5ex}
\dim_set:Nn \l_kivi_tab_id_dim {4em}
\dim_set:Nn \l_kivi_tab_amount_dim {5em}
\dim_set:Nn \l_kivi_tab_price_dim {7em}
\dim_gset:Nn \g_kivi_tabcolsep_dim {.5\tabcolsep}
\cs_new:Nn \__kivi_calc_desc_column: {
+ \dim_gset:Nn \l_kivi_tab_desc_leftskip_dim {
+ 0pt
+ \bool_if:NT \l_kivi_col_pos_bool {+\l_kivi_tab_pos_dim +2\g_kivi_tabcolsep_dim}
+ \bool_if:NT \l_kivi_col_id_bool {+\l_kivi_tab_id_dim +2\g_kivi_tabcolsep_dim}
+ }
\dim_gset:Nn \l_kivi_tab_desc_dim {
\textwidth
- \bool_if:NT \l_kivi_col_pos_bool {-\l_kivi_tab_pos_dim -2\g_kivi_tabcolsep_dim}
- \bool_if:NT \l_kivi_col_id_bool {-\l_kivi_tab_id_dim -2\g_kivi_tabcolsep_dim}
+ -\l_kivi_tab_desc_leftskip_dim
\bool_if:NT \l_kivi_col_amount_bool {-\l_kivi_tab_amount_dim -2\g_kivi_tabcolsep_dim}
\bool_if:NT \l_kivi_col_pricetotal_bool {-\l_kivi_tab_pricetotal_dim -2\g_kivi_tabcolsep_dim}
\bool_if:NT \l_kivi_col_price_bool {-\l_kivi_tab_price_dim -2\g_kivi_tabcolsep_dim}
\newcommand{\FakeTable}[1]{
\par
\seq_set_split:Nnn \l_kivi_PricingTable_seq {\tabularnewline} {#1}
+ \seq_remove_all:Nn \l_kivi_PricingTable_seq {}
\begingroup
\setlength{\tabcolsep}{\g_kivi_tabcolsep_dim}
\seq_map_inline:Nn \l_kivi_PricingTable_seq {
}
\endtabular
\seq_if_empty:NTF \g_kivi_extraDescription_seq
- {\par\nointerlineskip}
- {\par\nointerlineskip
- \begin{tcolorbox}[
- empty,
- left=\dim_eval:n {\l_kivi_tab_pos_dim+ \l_kivi_tab_id_dim +4\g_kivi_tabcolsep_dim},
- right=\dim_eval:n {\l_kivi_tab_num_dim+ 2\l_kivi_tab_price_dim +6\g_kivi_tabcolsep_dim},top=0pt,bottom=0pt,
- boxsep=0pt,
- breakable,
- lines~before~break=1,
- ]
- \seq_use:Nn \g_kivi_extraDescription_seq {\\}
- \end{tcolorbox}
- \nointerlineskip
+ {\par}
+ {\par
+ \setlength{\hsize}{\dimexpr\l_kivi_tab_desc_dim+\l_kivi_tab_desc_leftskip_dim}
+ \setlength{\leftskip}{\l_kivi_tab_desc_leftskip_dim}
+ \seq_use:Nn \g_kivi_extraDescription_seq {\\}
+ \par\nointerlineskip
}
}
\endgroup
\bfseries\bezeichnung
\bool_if:NT \l_kivi_col_amount_bool {&\bfseries\menge}
\bool_if:NT \l_kivi_col_price_bool { &\multicolumn{1}{>{\raggedleft}p{\l_kivi_tab_price_dim}}{\bfseries\einzelpreis}}
- \bool_if:NT \l_kivi_col_pricetotal_bool {&\multicolumn{1}{>{\raggedleft}p{\l_kivi_tab_pricetotal_dim}@{}}{\bfseries\gesamtpreis}}\\
+ \bool_if:NT \l_kivi_col_pricetotal_bool {&\multicolumn{1}{>{\raggedleft}p{\l_kivi_tab_pricetotal_dim}@{}}{\bfseries\gesamtpreis}}
\\
- \midrule\\[-\dp\strutbox]
+ \midrule
\endtabular
}
\hbox_gset:Nn \g_kivi_LT@foot_box {