I am trying to figure out on which base value to apply the margin="5%"
on the <fo:region-body> (see fragment below):
page-width="5in" page-height="5in" margin="5%">
<fo:region-body margin="5%" />
<fo:region-before extent="5%" />
The margin in the page-master element is obviously based on the
page-width as there is no further containing block. The percentage on
the extend="5%" in the <fo:region-before> is also relative to the
page-width as the spec says so: "refer to the corresponding width of
the page-viewport-area". This leaves the margin on the region-body. My
interpretation is that the containing block / ancestor area of the
region-body is the page-reference-area. Its content rectangle would in
this case have the width (5in - 2*(5in * 0.05)). If my interpretation
is correct it would mean that in the above example the margins on the
region-body would be smaller than the extend on the region-before (=>
not nice). I am concerned because it seems to be somewhat inconsistent
that the percentage on extent in a region-before is evaluated against a
different base than the percentage on a margin in a region-body.
I would appreciate if others could cross-check if my interpretation
seems ok or not.