Guido Ostkamp <[EMAIL PROTECTED]> wrote:
<snip/>
> It fails on the 'dedication' stuff. If you remove it, the PDF doc can be
> produced.
>
> I have raised an dblatex error report for this:
> <http://sourceforge.net/tracker/index.php?func=detail&aid=1838293&group_id=72607&atid=535062>
>
> Let's see whether they can fix it.
<snip/>
Hi,
attached is a patch of dblatex's author (based on release 0.2.8) that
fixes the dedication issue. (By the way, to avoid adorning myself with
borrowed plumes: "they" is Benoit Guillon, contrary to the wrong
information in the SuSE and Fedora packages I'm only the Debian
packager, but not a dblatex author.)
The patch should be straightforward to apply if you want to further
experimentalize with AsciiDoc and dblatex. I will include the patch in
the upcoming Debian dblatex release 0.2.8-1, and I assume it will be
also part of the next upstream release.
Hope this helps, Andreas
--
Andreas Hoenen <[EMAIL PROTECTED]>
GPG: 1024D/B888D2CE
A4A6 E8B5 593A E89B 496B
82F0 728D 8B7E B888 D2CE
Index: component.xsl
===================================================================
RCS file: /usr/local/cvsroot/docbook/db2tex/dblatex/xsl/component.xsl,v
retrieving revision 1.3
diff -u -r1.3 component.xsl
--- component.xsl 14 Jun 2007 21:23:06 -0000 1.3
+++ component.xsl 26 Nov 2007 22:31:08 -0000
@@ -12,12 +12,22 @@
<xsl:template match="colophon">
<xsl:call-template name="section.unnumbered">
<xsl:with-param name="tocdepth" select="number($colophon.tocdepth)"/>
+ <xsl:with-param name="title">
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'Colophon'"/>
+ </xsl:call-template>
+ </xsl:with-param>
</xsl:call-template>
</xsl:template>
<xsl:template match="dedication">
<xsl:call-template name="section.unnumbered">
<xsl:with-param name="tocdepth" select="number($dedication.tocdepth)"/>
+ <xsl:with-param name="title">
+ <xsl:call-template name="gentext">
+ <xsl:with-param name="key" select="'Dedication'"/>
+ </xsl:call-template>
+ </xsl:with-param>
</xsl:call-template>
</xsl:template>
@@ -29,6 +39,7 @@
<xsl:template name="section.unnumbered">
<xsl:param name="tocdepth" select="0"/>
+ <xsl:param name="title"/>
<xsl:choose>
<xsl:when test="number($tocdepth) = -1">
<xsl:call-template name="mapheading"/>
@@ -40,10 +51,22 @@
<xsl:call-template name="set-tocdepth">
<xsl:with-param name="depth" select="$tocdepth - 1"/>
</xsl:call-template>
- <xsl:call-template name="makeheading">
- <xsl:with-param name="level" select="'0'"/>
- <xsl:with-param name="allnum" select="'1'"/>
- </xsl:call-template>
+ <!-- those sections have optional title -->
+ <xsl:choose>
+ <xsl:when test="title">
+ <xsl:call-template name="makeheading">
+ <xsl:with-param name="level" select="'0'"/>
+ <xsl:with-param name="allnum" select="'1'"/>
+ </xsl:call-template>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:call-template name="maketitle">
+ <xsl:with-param name="level" select="'0'"/>
+ <xsl:with-param name="allnum" select="'1'"/>
+ <xsl:with-param name="title" select="$title"/>
+ </xsl:call-template>
+ </xsl:otherwise>
+ </xsl:choose>
<xsl:apply-templates/>
<!-- restore the initial counters -->
<xsl:text>\setcounter{secnumdepth}{</xsl:text>
Index: labelid.xsl
===================================================================
RCS file: /usr/local/cvsroot/docbook/db2tex/dblatex/xsl/labelid.xsl,v
retrieving revision 1.9
diff -u -r1.9 labelid.xsl
--- labelid.xsl 14 Jun 2007 21:23:06 -0000 1.9
+++ labelid.xsl 26 Nov 2007 22:21:26 -0000
@@ -50,6 +50,37 @@
<xsl:apply-templates select="title" mode="foottext"/>
</xsl:template>
+<xsl:template name="maketitle">
+ <xsl:param name="num" select="'1'"/>
+ <xsl:param name="allnum" select="'0'"/>
+ <xsl:param name="level"/>
+ <xsl:param name="name"/>
+ <xsl:param name="command"/>
+ <xsl:param name="title"/>
+
+ <xsl:variable name="rcommand">
+ <xsl:choose>
+ <xsl:when test="$command=''">
+ <xsl:call-template name="map.sect.level">
+ <xsl:with-param name="name" select="$name"/>
+ <xsl:with-param name="level" select="$level"/>
+ <xsl:with-param name="num" select="$num"/>
+ <xsl:with-param name="allnum" select="$allnum"/>
+ </xsl:call-template>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$command"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
+
+ <xsl:value-of select="$rcommand"/>
+ <xsl:text>{</xsl:text>
+ <xsl:value-of select="$title"/>
+ <xsl:text>} </xsl:text>
+ <xsl:call-template name="label.id"/>
+</xsl:template>
+
<xsl:template name="label.id">
<xsl:param name="object" select="."/>
_______________________________________________
asciidoc-discuss mailing list
[email protected]
http://lists.metaperl.com/cgi-bin/mailman/listinfo/asciidoc-discuss