Reputation: 543
My problem is based on a table with two cells. If there is more text in the one cell, its getting expanded in down direction. In that case the other block is shorter (note that the table cell is as big as the other).
Basically I want to make a border around the table cell. But it shall be an image as a border. I'm making a padding in the table cell and the background color of the inside blocks white. With that strategy it looks kinda like a border. The problem is, that the block in the second cell is smaller, so there is more space beneath it. The border gets inconsistent.
Is there a way to scale the block to fit?
Upvotes: 1
Views: 1660
Reputation: 8068
Since you're using Antenna House, you can use <fo:block-container column-count="2">
and add break-before="column"
on the second fo:block
. See https://www.antennahouse.com/product/ahf64/ahf-ext.html#axf.column-count and https://www.w3.org/TR/xsl/#break-before
Upvotes: 0
Reputation: 2115
The block that contains the text in a cell is sized to fit the text. This is why your current background is uneven.
What you need is a background-color for the entire table: the table will be sized to fit the largest cell.
If the image is inside an fo:block, and this same block also contains the table, you get the result you want.
pseudocode:
<fo:block background-image="image.png">
table goes here, with background-color="white" and a transparent border around the table to set the width/height of the visible portion of the background image.
</fo:block>
Edit: comments revealed more specifics.
With the added constraint that the border should be around the table header only:
Upvotes: 1