<xsl:variable name="htmlhelp.generate.index" select="//indexterm[1]"/>
+<xsl:variable name="raw.help.title">
+ <xsl:choose>
+ <xsl:when test="$htmlhelp.title = ''">
+ <xsl:choose>
+ <xsl:when test="$rootid != ''">
+ <xsl:apply-templates select="key('id',$rootid)" mode="title.markup"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:apply-templates select="/*" mode="title.markup"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$htmlhelp.title"/>
+ </xsl:otherwise>
+ </xsl:choose>
+</xsl:variable>
+
+<xsl:variable name="help.title" select="normalize-space($raw.help.title)"/>
+
<!-- ==================================================================== -->
<xsl:template match="/">
</xsl:for-each>
<xsl:text>
Title=</xsl:text>
- <xsl:choose>
- <xsl:when test="$htmlhelp.title = ''">
- <xsl:choose>
- <xsl:when test="$rootid != ''">
- <xsl:apply-templates select="key('id',$rootid)" mode="title.markup"/>
- </xsl:when>
- <xsl:otherwise>
- <xsl:apply-templates select="/*" mode="title.markup"/>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:when>
- <xsl:otherwise>
- <xsl:value-of select="$htmlhelp.title"/>
- </xsl:otherwise>
- </xsl:choose>
+ <xsl:value-of select="$help.title"/>
<xsl:text>
Enhanced decompilation=</xsl:text>
<xsl:choose>
[WINDOWS]
</xsl:text>
<xsl:value-of select="$htmlhelp.hhp.window"/>
-<xsl:text>=,"</xsl:text><xsl:value-of select="$htmlhelp.hhc"/>
+<xsl:text>="</xsl:text>
+<xsl:value-of select="$help.title"/>
+<xsl:text>","</xsl:text><xsl:value-of select="$htmlhelp.hhc"/>
<xsl:text>",</xsl:text>
<xsl:if test="$htmlhelp.generate.index">
<xsl:text>"</xsl:text>
</xsl:text>
</xsl:if>
+<!--
+ Needs more investigation to generate propetly all fields
+<xsl:text>search="</xsl:text>
+<xsl:value-of select="normalize-space(//title[1])"/>
+<xsl:text>","toc.hhc","index.hhk","</xsl:text>
+<xsl:value-of select="$root.filename"/>
+<xsl:text>.html","</xsl:text>
+<xsl:value-of select="$root.filename"/>
+<xsl:text>.html",,,,,</xsl:text>
+<xsl:value-of select="$xnavigation"/>
+<xsl:text>,</xsl:text>
+<xsl:value-of select="$htmlhelp.hhc.width"/>
+<xsl:text>,</xsl:text>
+<xsl:value-of select="$xbuttons"/>
+<xsl:text>,</xsl:text>
+<xsl:value-of select="$htmlhelp.window.geometry"/>
+<xsl:text>,,,,,2,,0
+</xsl:text>
+-->
+
<xsl:if test="$htmlhelp.hhp.windows">
<xsl:value-of select="$htmlhelp.hhp.windows"/>
</xsl:if>