Preserve text structure with XSL-FO

0
Share this on .. Tweet about this on Twitter0Share on LinkedIn0Share on Facebook0Share on Google+0Email this to someoneShare on TumblrBuffer this page

XSL-FO is all about the formatting of a document. For the interpretation of spaces and other special characters many options are available. To preserve the whitespaces and new lines in a text at least the property white-space-collapse should be set to false (the default setting is true). In my opinion does the name of this property not completely cover its meaning, because it also involves special characters like linefeeds and tabs, but alas it’s close enough. Since the described setting was succesful I did not investigate other properties, like linefeed-treatment and white-space-treatment. Also, the property white-space should specify a set of properties, but this did not seem to work.

Remarks: Do not always trust the console and the logging messages, because the printed output may differ from the actual content. Our java printXML method converted the carriage return control character into the entity but retained and used the linefeed. This resulted in some major confusion :-(.

Share this on .. Tweet about this on Twitter0Share on LinkedIn0Share on Facebook0Share on Google+0Email this to someoneShare on TumblrBuffer this page

About Author

Aino Andriessen is principal consultant and expertise lead 'Continuous Delivery'. His focus is on Oracle Fusion Middleware ADF and SOA development, Continuous Delivery, architecture, improving the software development proces and quality management. He is a frequent presenter at Oracle Open World, ODTUG Kaleidoscope, UKOUG Technology Conference and OUGN Vårseminar. He writes articles and publishes at the AMIS technology blog (http://technology.amis.nl/blog/).

Comments are closed.