<xsl:template name="write.chunk">
<xsl:param name="filename" select="''"/>
<xsl:param name="method" select="'html'"/>
- <xsl:param name="encoding" select="'ISO-8859-1'"/>
+ <xsl:param name="encoding" select="$default.encoding"/>
<xsl:param name="indent" select="'no'"/>
<xsl:param name="content" select="''"/>
<xsl:document href="{$filename}"
method="{$method}"
encoding="{$encoding}"
- indent="{$indent}">
+ indent="{$indent}"
+ saxon:character-representation="{$saxon.character.representation}">
<xsl:copy-of select="$content"/>
</xsl:document>
</xsl:when>
href="{$filename}"
method="{$method}"
encoding="{$encoding}"
- indent="{$indent}">
+ indent="{$indent}"
+ saxon:character-representation="{$saxon.character.representation}">
<xsl:copy-of select="$content"/>
</saxon:output>
</xsl:when>
<xsl:template name="write.chunk.with.doctype">
<xsl:param name="filename" select="''"/>
<xsl:param name="method" select="'html'"/>
- <xsl:param name="encoding" select="'ISO-8859-1'"/>
+ <xsl:param name="encoding" select="$default.encoding"/>
<xsl:param name="indent" select="'no'"/>
<xsl:param name="doctype-public" select="''"/>
<xsl:param name="doctype-system" select="''"/>
encoding="{$encoding}"
indent="{$indent}"
doctype-public="{$doctype-public}"
- doctype-system="{$doctype-system}">
+ doctype-system="{$doctype-system}"
+ saxon:character-representation="{$saxon.character.representation}">
<xsl:copy-of select="$content"/>
</xsl:document>
</xsl:when>
encoding="{$encoding}"
indent="{$indent}"
doctype-public="{$doctype-public}"
- doctype-system="{$doctype-system}">
+ doctype-system="{$doctype-system}"
+ saxon:character-representation="{$saxon.character.representation}">
<xsl:copy-of select="$content"/>
</saxon:output>
</xsl:when>
</refdescription>
</doc:param>
+<!-- ==================================================================== -->
+<xsl:param name="default.encoding" select="'ISO-8859-1'" doc:type='string'/>
+
+<doc:param name="default.encoding" xmlns="">
+<refpurpose>Encoding used in generated HTML pages</refpurpose>
+<refdescription>
+<para>This encoding is used in files generated by chunking stylesheet. Currently
+only Saxon is able to change output encoding.
+</para>
+</refdescription>
+</doc:param>
+
+<!-- ==================================================================== -->
+<xsl:param name="saxon.character.representation" select="'entity;decimal'" doc:type='string'/>
+
+<doc:param name="saxon.character.representation" xmlns="">
+<refpurpose>Saxon character representation used in generated HTML pages</refpurpose>
+<refdescription>
+<para>This character representation is used in files generated by chunking stylesheet. If
+you want to suppress entity references for characters with direct representation
+in default.encoding, set this parameter to value <literal>native</literal>.
+</para>
+</refdescription>
+</doc:param>
+
+
</xsl:stylesheet>