Reputation: 21
While generating pdf using xsl:fo, I am getting overlapping border with fo:inline tag.
I am using apache-xmlgraphics-fop version 2.7.
Here is a code snippet
<fo:block margin-top="4px">
<fo:inline border-style="solid" border-width="1px" border-color="#E8EDF7" padding="2px" fox:border-radius="3pt">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce eu justo at quam hendrerit congue ac ac magna. Maecenas tincidunt vulputate justo, ut tempus lorem pulvinar a. Nulla fermentum metus sit amet metus tempus pretium. In massa sem, vestibulum a lectus eu, efficitur imperdiet odio.
</fo:inline>
</fo:block>
Upvotes: 1
Views: 38
Reputation: 8068
You need to increase the line-height
of the fo:block
.
line-stacking-strategy="max-height"
, the default (see https://www.w3.org/TR/xsl11/#line-stacking-strategy), doesn't consider the border and padding on the fo:inline
when positioning the line areas. (Still not sure why.)
If FOP supported line-stacking-strategy="line-height"
, then you could set theline-height
on the fo:inline
, and only the lines with the fo:inline
would have wider spacing.
Upvotes: 0