The stylesheets had not caught up with the most recent changes in the DocBook 5 schema. Only recently was caption permitted in a CALS table. This is the fix that I just added to the XSL source:

<xsl:template match="table" mode="title.markup">
 <xsl:param name="allow-anchors" select="0"/>
 <xsl:apply-templates select="(title|caption)[1]" mode="title.markup">
   <xsl:with-param name="allow-anchors" select="$allow-anchors"/>
 </xsl:apply-templates>
</xsl:template>

You can add it to your customization layer, or wait for a new snapshot release.

Bob Stayton
Sagehill Enterprises
DocBook Consulting
[EMAIL PROTECTED]


----- Original Message ----- From: "Fabrizio Gotti" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Tuesday, March 13, 2007 10:30 AM
Subject: [docbook-apps] Caption duplication in CALS tables


Hello,

When I try to insert a caption in a CALS table, the html output contains its caption twice. For instance, the following valid docbook document produces a table with the caption in the title as well as in its "normal" place.

Is there a way to suppress the caption occurrence in the title?

I am using docbook 5, with Saxon 8B.

Thank you

Fabrizio Gotti

=================

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE book [<!ENTITY myent "My Entity" >]>
<book version="5.0" xmlns="http://docbook.org/ns/docbook";>
    <info><title>Example</title></info>

    <chapter xml:id="hello">
        <title>Chapter title</title>
        <para>
            This is a small paragraph
        </para>

        <table xml:id="ex.calstable" frame='all' shortentry="1">
            <title>Sample CALS Table (long title)</title>
            <titleabbrev>Short title</titleabbrev>
            <tgroup cols="1">
                <tbody>
<row><entry><simpara>empty line</simpara></ entry></row>
                </tbody>
            </tgroup>
            <caption>
<simpara>This is a caption, it should appear only once.</simpara>
            </caption>
       </table>
    </chapter>
</book>

produces an html table like this:
Table 1.1. Sample CALS Table (long title)

This is a caption, it should appear only once.

[empty line]

This is a caption, it should appear only once.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to