OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: RE: Adding line breaks to HTML source files

Jennifer Moore [mailto:jennifer@uncharted-worlds.org] wrote:

> Not a major problem, but something I was puzzling over:  how 
> do the line 
> breaks get into HTML source files generated from DocBook XML?  (or 
> indeed any XML I suppose.)

This is handled automatically by the XSLT processor. There is an
attribute on <xsl:output> and <xsl:result-document> called "indent" that
can be set to "yes" or "no". If you set it to "yes", the processor adds
whitespace to make the code more readable. But as you might imagine,
this can cause problems with HTML content that's intended to be laid out
as is--mainly the contents of the <pre> element, which is often used to
display code.

The slegdehammer alternative to getting more line breaks in your code
might be to force them in with an <xsl:text> element:


Rob Cavicchio
Principal Technical Writer
EMC Captiva
EMC Corporation
10145 Pacific Heights Boulevard, 6th Floor
San Diego, CA 92121-4234

P: (858) 320-1208
F: (858) 320-1010
E: Cavicchio_Rob@emc.com

The opinions expressed here are my personal opinions. Content published
here is not read or approved in advance by EMC and does not necessarily
reflect the views and opinions of EMC.

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]