diff options
Diffstat (limited to 'xslt/docbook/html/db2html-media.xsl')
-rw-r--r-- | xslt/docbook/html/db2html-media.xsl | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/xslt/docbook/html/db2html-media.xsl b/xslt/docbook/html/db2html-media.xsl index 454ea66..1cb1a63 100644 --- a/xslt/docbook/html/db2html-media.xsl +++ b/xslt/docbook/html/db2html-media.xsl @@ -195,7 +195,12 @@ as a text-only mode. <div class="mediaobject"> <xsl:call-template name="db2html.anchor"/> <xsl:call-template name="db2html.mediaobject"/> - <xsl:apply-templates select="caption"/> + <!-- When a figure contains only a single mediaobject, it eats the caption --> + <xsl:if test="not(../self::figure) or + ../*[not(self::blockinfo) and not(self::title) and + not(self::titleabbrev) and not(. = current()) ]"> + <xsl:apply-templates select="caption"/> + </xsl:if> </div> </xsl:template> |