hi,hans ,

Maybe I find some bug in file page-lay.mkxl, in \def\page_layouts_synchronize.

1. Here is the source code snippet from the above code file. I think it is reasonable if change the last line of code to:

\global\advanceby\makeupheight\dimexpr-\topdistance-\topheight-\scratchdimen\relax

\orelse\ifx\p_page_layouts_height\v!fit
\ifzeropt\bottomspace
\global\bottomspace\topspace
\fi
\global\makeupheight\dimexpr\paperheight-\bottomspace\relax
\scratchdimen\dimexpr\topspace-\topheight-\topdistance\relax
\ifdim\scratchdimen<\zeropoint
\scratchdimen\zeropoint
\fi
\global\advanceby\makeupheight\dimexpr-\bottomdistance-\bottomheight-\scratchdimen\relax


2. Here is the source code snippet from above code file. I think it is reasonable if change the last line of code to:

\global\advanceby\makeupwidth\dimexpr
-\leftmargindistance-\leftmarginwidth
-\leftedgedistance -\leftedgewidth
-\scratchdimen\relax

\orelse\ifx\p_page_layouts_width\v!fit
\ifzeropt\cutspace
\global\cutspace\backspace
\fi
\global\makeupwidth\dimexpr\paperwidth-\cutspace\relax
\scratchdimen\dimexpr\backspace
-\leftedgewidth -\leftedgedistance
-\leftmarginwidth-\leftmargindistance\relax
\ifdim\scratchdimen<\zeropoint
\scratchdimen\zeropoint
\fi

\global\advanceby\makeupwidth\dimexpr

-\rightmargindistance-\rightmarginwidth

-\rightedgedistance -\rightedgewidth
-\scratchdimen\relax


----------------------------

zhongtian wang

Shijiazhuang YouWen Information Technology Co.,Ltd,China

13311202589 wangzht@189.cn