diff options
Diffstat (limited to 'tangle-bootstrap.xsl')
-rw-r--r-- | tangle-bootstrap.xsl | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tangle-bootstrap.xsl b/tangle-bootstrap.xsl index baa9669..a646bca 100644 --- a/tangle-bootstrap.xsl +++ b/tangle-bootstrap.xsl @@ -29,10 +29,10 @@ _MPED_EOF <xsl:template match="text()"/> <xsl:template match="mped:copy" mode="copy-source-code"> <xsl:variable name="ref" select="@linkend"/> - <xsl:variable name="candidates" select="count(//docbook:programlisting[@xml:id = $ref])"/> + <xsl:variable name="candidates" select="count(//docbook:figure[@xml:id = $ref]/docbook:programlisting)"/> <xsl:if test="$candidates = 0"> <xsl:message terminate="yes"> - <xsl:text>There are no listing with ID '</xsl:text> + <xsl:text>There are no listing directly within a figure with ID '</xsl:text> <xsl:value-of select="$ref"/> <xsl:text>'. </xsl:text> @@ -40,12 +40,12 @@ _MPED_EOF </xsl:if> <xsl:if test="$candidates > 1"> <xsl:message terminate="yes"> - <xsl:text>There are multiple listings with ID '</xsl:text> + <xsl:text>There are multiple listings directly within a figure with ID '</xsl:text> <xsl:value-of select="$ref"/> <xsl:text>'. </xsl:text> </xsl:message> </xsl:if> - <xsl:apply-templates select="//docbook:programlisting[@xml:id = $ref]" mode="copy-source"/> + <xsl:apply-templates select="//docbook:figure[@xml:id = $ref]/docbook:programlisting" mode="copy-source"/> </xsl:template> </xsl:stylesheet> |