Generate the book in XHTML instead of HTML

Øyvind A. Holm sunny at sunbase.org
Thu Mar 10 18:13:06 CST 2005


On 2005-03-10 17:43:18 Max Bowsher wrote:
> Øyvind A. Holm wrote:
> > [[[
> > Change the xsl stylesheets in tools/ so xsltproc generates XHTML 
> > instead of HTML. Default character set is now UTF-8 instead of 
> > ISO-8859-1 and the XHTML is properly indented and contains a DOCTYPE 
> > declaration, which the previous HTML version lacked.
> > [...]
> > ]]]
>
> I've no problems with UTF-8 and XHTML, but I'm extremely reluctant to 
> add 222kB of invisible whitespace to the chunked book.

Hm, the indents on single-page version did not have such an impact, I 
suppose it's because of all the headers in the chunked version.

> -0.99999 on turning on indentation (at least in the default build).

I'm not in a position to vote, but I try to contribute an additional 
-0.00001 anyhow, because of this.

> +0.5 on changing to XHTML.

So by removing the indents, the new patch changes to this:

[[[
Change the xsl stylesheets in tools/ so xsltproc generates XHTML instead 
of HTML. Default character set is now UTF-8 instead of ISO-8859-1 and 
contains a proper DOCTYPE declaration, which the previous HTML version 
lacked.

* src/tools/html-stylesheet.xsl
 Change <xsl:import href> to "xsl/xhtml/docbook.xsl".

* src/tools/chunk-stylesheet.xsl
 Change <xsl:import href> to "xsl/xhtml/chunk.xsl".

Patch by Marcus Rueckert <darix at irssi.org>.
]]]

Index: src/tools/html-stylesheet.xsl
===================================================================
--- src/tools/html-stylesheet.xsl	(revision 1164)
+++ src/tools/html-stylesheet.xsl	(working copy)
@@ -1,6 +1,6 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version='1.0'>
 
-  <xsl:import href="xsl/html/docbook.xsl"/>
+  <xsl:import href="xsl/xhtml/docbook.xsl"/>
 
   <xsl:param name="html.stylesheet">styles.css</xsl:param>
   <xsl:param name="toc.section.depth">3</xsl:param>
Index: src/tools/chunk-stylesheet.xsl
===================================================================
--- src/tools/chunk-stylesheet.xsl	(revision 1164)
+++ src/tools/chunk-stylesheet.xsl	(working copy)
@@ -1,6 +1,6 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version='1.0'>
 
-  <xsl:import href="xsl/html/chunk.xsl"/>
+  <xsl:import href="xsl/xhtml/chunk.xsl"/>
 
   <xsl:param name="html.stylesheet">styles.css</xsl:param>
   <xsl:param name="toc.section.depth">3</xsl:param>


-- sunny256



More information about the svnbook-dev mailing list