From: Marei Peischl Date: Wed, 27 Nov 2019 12:17:52 +0000 (+0100) Subject: introduce Pricingtable* X-Git-Tag: release-3.5.6.1~316 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=b3afb08d1af1eee3fa141658b4948e47b3c905fe;p=kivitendo-erp.git introduce Pricingtable* --- diff --git a/kiviletter.sty b/kiviletter.sty index bb2ab5646..5adf773ec 100644 --- a/kiviletter.sty +++ b/kiviletter.sty @@ -224,6 +224,43 @@ align=tl, \endgroup } +\usepackage{afterpage} + +\cs_new:cpn {PricingTabular*}{ + \bool_gset_true:N \g_kivi_inTable_bool + \endgroup + \@nameuse{Gm@restore@@kivi.letter@table}% + \Gm@changelayout + \begingroup + \def \@currenvir {PricingTabular*}\edef \@currenvline {\on@line } + \addtolength{\vsize}{-\box_ht:N \g_kivi_LT@foot_box} + \pagegoal\vsize + \widowpenalty0 + \clubpenalty0 + \bool_gset_true:N \g_kivi_TableFoot_bool + \leavevmode\box_use:N \g_kivi_LT@head_box + \par\nointerlineskip\ignorespaces +} + +\cs_new:cpn {endPricingTabular*} { + \thispagestyle{kivitendo.letter.PricingTable} + \bool_gset_false:N \g_kivi_TableFoot_bool + \@nameuse{Gm@restore@@kivi.letter@default} + \Gm@changelayout + \bool_gset_true:N \g_kivi_restore_geometry_bool + \afterpage{ + \kivi_conditional_restore_geometry: + } +} + +\cs_new:Nn \kivi_conditional_restore_geometry: { + \bool_if:NT \g_kivi_restore_geometry_bool + { + \@nameuse{Gm@restore@@kivi.letter@default} + \Gm@changelayout + } + \bool_gset_false:N \g_kivi_restore_geometry_bool +} \ExplSyntaxOff \if@kivi@infobox