today i noticed that docbook xsl stylesheets in 1.74 ignore a
mediaobject. According to the DTD a mediaobject is allowed inside a
table environment:
table ::=
(((blockinfo?,
(title,titleabbrev?),
(indexterm)*,
textobject*,
(graphic+|mediaobject+|tgroup+))|
(caption,
(col*|colgroup*),
thead?,tfoot?,
(tbody+|tr+))))
So i had something like
<table>
<title>test</title>
<mediaobject> ... </mediaobject>
</table>
Looking at the xsl stylesheet (quoted below) i found that one template
calls another for 'tgroup|mediaobject|graphic', but the later did not
process any mediaobject environment, only tgroups.
I added to the later stylesheet the following before </xsl:template>
----------------
<xsl:for-each select="mediaobject">
<xsl:apply-templates select="."/>
</xsl:for-each>
----------------
Which restults that the picture appears as table.
-------------------------------------------
<!--
==================================================================== -->
<xsl:template name="make.table.content">
<xsl:choose>
<xsl:when test="tgroup|mediaobject|graphic">
<xsl:call-template name="calsTable"/>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates select="." mode="htmlTable"/>
</xsl:otherwise>
</xsl:choose>
</xsl:template>
<!-- =================================================================== -->
<!--
==================================================================== -->
<xsl:template name="calsTable">
<xsl:variable name="keep.together">
<xsl:call-template name="pi.dbfo_keep-together"/>
</xsl:variable>
<xsl:for-each select="tgroup">
<fo:table xsl:use-attribute-sets="table.table.properties">
<xsl:if test="$keep.together != ''">
<xsl:attribute name="keep-together.within-column">
<xsl:value-of select="$keep.together"/>
</xsl:attribute>
</xsl:if>
<xsl:call-template name="table.frame"/>
<xsl:if test="following-sibling::tgroup">
<xsl:attribute name="border-bottom-width">0pt</xsl:attribute>
<xsl:attribute name="border-bottom-style">none</xsl:attribute>
<xsl:attribute name="padding-bottom">0pt</xsl:attribute>
<xsl:attribute name="margin-bottom">0pt</xsl:attribute>
<xsl:attribute name="space-after">0pt</xsl:attribute>
<xsl:attribute name="space-after.minimum">0pt</xsl:attribute>
<xsl:attribute name="space-after.optimum">0pt</xsl:attribute>
<xsl:attribute name="space-after.maximum">0pt</xsl:attribute>
</xsl:if>
<xsl:if test="preceding-sibling::tgroup">
<xsl:attribute name="border-top-width">0pt</xsl:attribute>
<xsl:attribute name="border-top-style">none</xsl:attribute>
<xsl:attribute name="padding-top">0pt</xsl:attribute>
<xsl:attribute name="margin-top">0pt</xsl:attribute>
<xsl:attribute name="space-before">0pt</xsl:attribute>
<xsl:attribute name="space-before.minimum">0pt</xsl:attribute>
<xsl:attribute name="space-before.optimum">0pt</xsl:attribute>
<xsl:attribute name="space-before.maximum">0pt</xsl:attribute>
</xsl:if>
<xsl:apply-templates select="."/>
</fo:table>
</xsl:for-each>
</xsl:template>
<!--
==================================================================== -->
P.S.: This may apply to html output as well
A fix for this issue has been added to the current codebase.
Please test the fix with the latest snapshot from:
http://docbook.sourceforge.net/snapshots/
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).