Padding on table-cells is currently broken. The sample fo file below
demonstrates the problem. I think I know the cause and the fix but
would like confirmation:
Am I correct in saying that in the collapsing border model any padding
is not part of the "collapsing", i.e. it only applies to the border
itself? If that is right than the fix is either for the border
resolution code to copy the original padding properties to what is
called in fop the "effective" CommonBorderAndPadding properties or in
later calculations involving padding do not refer to the "effective"
CommonBorderAndPadding properties (as the padding properties are not
set) but refer to the original CommonBorderAndPadding properties as set
on the cell. I am tending to the latter and let the border resolution
code just worry about the borders.
Manuel
<fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
<fo:layout-master-set>
<fo:simple-page-master master-name="normal" page-width="5in"
page-height="5in">
<fo:region-body/>
</fo:simple-page-master>
</fo:layout-master-set>
<fo:page-sequence master-reference="normal"
white-space-collapse="true">
<fo:flow flow-name="xsl-region-body">
<fo:table>
<fo:table-column column-number="1" />
<fo:table-body>
<fo:table-row>
<fo:table-cell margin="0pt" padding="5pt"
background-color="blue">
<fo:block>Row 1 Col 2</fo:block>
</fo:table-cell>
<fo:table-cell>
<fo:block>Row 1 Col 3</fo:block>
</fo:table-cell>-->
</fo:table-row>
</fo:table-body>
</fo:table>
<fo:block>Table with all yellow cells having 5% padding and
all blue cells having 5pt padding.</fo:block>
</fo:flow>
</fo:page-sequence>
</fo:root>