pretty print and <xsl:text> </xsl:text>
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 16
- Joined: Tue Jan 20, 2004 4:07 am
pretty print and <xsl:text> </xsl:text>
Hello,
The pretty print function has a very annoying funtion!
if you have a
<xsl:text> </xsl:text>
and then you pretty print it turns in to:
<xsl:text/>
This is bad as there are many times where you are using xsl:text to add a space!
The pretty print function has a very annoying funtion!
if you have a
<xsl:text> </xsl:text>
and then you pretty print it turns in to:
<xsl:text/>
This is bad as there are many times where you are using xsl:text to add a space!
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hi Peter,
You have 3 options.
1. <xsl:text><![CDATA[ ]]></xsl:text>
2. <xsl:text xml:space="preserve"> </xsl:text>
3. Add xsl:space to the Options->Preferences Editor/Format/Preserve space elements list and then use <xsl:text> </xsl:text> as you do now.
Option 1 is the most portable form, option 2 is portable only between tools that handle xml:space and option 3 is less portable, requires the same setting with oXygen or an equivalent setting with some other tool.
On the other hand option 3 is the easiest to write, option 2 is a little harder while option 1 is the hardest to write.
I personally use and recommend option 2 as it allows enough portability and it is not hard to write. Also this is very verbose.
Best Regards,
George
You have 3 options.
1. <xsl:text><![CDATA[ ]]></xsl:text>
2. <xsl:text xml:space="preserve"> </xsl:text>
3. Add xsl:space to the Options->Preferences Editor/Format/Preserve space elements list and then use <xsl:text> </xsl:text> as you do now.
Option 1 is the most portable form, option 2 is portable only between tools that handle xml:space and option 3 is less portable, requires the same setting with oXygen or an equivalent setting with some other tool.
On the other hand option 3 is the easiest to write, option 2 is a little harder while option 1 is the hardest to write.
I personally use and recommend option 2 as it allows enough portability and it is not hard to write. Also this is very verbose.
Best Regards,
George
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service