i'm using fop libraries v1.1 produce pdf, , noted fop default collapse white-spaces inside strings. example block like:
<fo:block> sample text </fo:block>
render as
sample text
eliminating whitespaces. keep strings inner whitespaces in generated pdf, tried use white-space="pre"
attribute inside block tag, preserves white-spaces outside string.
then tried use white-space-treatment="preserve"
attribute inside block tag, rendered page had collapsed white-spaces.
finally tried use white-space-collapse="false"
attribute inside block, , in case rendered page had collapsed white-spaces.
why fop collapsing default white-spaces inside strings? there way change fop behaviour in order preserve white-spaces inside strings?
white-space="pre"
should work here or may use linefeed-treatment = "preserve", white-space-collapse = "false", white-space-treatment = "preserve", wrap-option = "no-wrap"
equal white-space="pre"
. more information may visit http://www.learn-xsl-fo-tutorial.com/blocks-inlines.cfm#h1.6
Comments
Post a Comment