diff options
Diffstat (limited to 'Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv')
-rw-r--r-- | Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv b/Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv index 1fde9e9c9c5..f2e39c66033 100644 --- a/Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv +++ b/Master/texmf-dist/tex/context/base/mkiv/page-lay.mkiv @@ -92,9 +92,12 @@ \newdimen\topdistance \newdimen\headerdistance +\newdimen\textdistance \newdimen\footerdistance \newdimen\bottomdistance +\newdimen\textovershoot % available in pagebuilder + %D We need to calculate the extra distances: \newdimen\naturalmarginwidth @@ -107,6 +110,7 @@ \newdimen\naturalrightmargindistance \newdimen\naturaltopdistance \newdimen\naturalheaderdistance +\newdimen\naturaltextdistance \newdimen\naturalfooterdistance \newdimen\naturalbottomdistance @@ -178,6 +182,7 @@ \global\naturalrightmargindistance\layoutparameter\c!rightmargindistance \global\naturaltopdistance \layoutparameter\c!topdistance \global\naturalheaderdistance \layoutparameter\c!headerdistance + \global\naturaltextdistance \layoutparameter\c!textdistance \global\naturalfooterdistance \layoutparameter\c!footerdistance \global\naturalbottomdistance \layoutparameter\c!bottomdistance % @@ -192,6 +197,7 @@ \global\rightmargindistance \layoutdistance\rightmarginwidth\naturalrightmargindistance \global\topdistance \layoutdistance\topheight \naturaltopdistance \global\headerdistance \layoutdistance\headerheight \naturalheaderdistance + \global\textdistance \naturaltextdistance \global\footerdistance \layoutdistance\footerheight \naturalfooterdistance \global\bottomdistance \layoutdistance\bottomheight \naturalbottomdistance } @@ -372,7 +378,11 @@ \doifelseassignment{#2} {\definelayouttarget[#1][#2]} {\setevalue{\??layoutpaper#1}{#2}% - \setevalue{\??layoutprint#1}{#3}}% + \ifthirdargument + \setevalue{\??layoutprint#1}{#3}% + \else + \setevalue{\??layoutprint#1}{#2}% + \fi}% \fi} \appendtoks @@ -447,15 +457,12 @@ \let\setuppaper\page_paper_setup_size_settings \unexpanded\def\adaptpapersize - {\global\let\page_paper_reinstate\page_paper_reinstate_indeed + {\glet\page_paper_reinstate\page_paper_restore \setuppapersize} -\unexpanded\def\page_paper_reinstate_indeed - {\page_paper_restore - \global\let\page_paper_reinstate\relax} - \appendtoks \page_paper_reinstate + \global\let\page_paper_reinstate\relax \to \everyaftershipout \unexpanded\def\page_paper_set_restore#1#2% |