summaryrefslogtreecommitdiff
path: root/fo/footnote.xsl
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2021-10-15 06:55:11 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2021-10-15 06:55:11 +0900
commitd2cfd1f36d94c2377115f9ac79213eae31f83464 (patch)
treed33d3aadc7edbb0b5dd84194e053e16fc4410c06 /fo/footnote.xsl
parent4c7d5230da2c9c32ccfd18cf1f46b8c50d32db7a (diff)
downloaddocbook-xsl-stylesheets-d2cfd1f36d94c2377115f9ac79213eae31f83464.tar.gz
docbook-xsl-stylesheets-d2cfd1f36d94c2377115f9ac79213eae31f83464.tar.bz2
docbook-xsl-stylesheets-d2cfd1f36d94c2377115f9ac79213eae31f83464.zip
Imported Upstream version 1.79.2upstream/1.79.2
Diffstat (limited to 'fo/footnote.xsl')
-rw-r--r--fo/footnote.xsl43
1 files changed, 21 insertions, 22 deletions
diff --git a/fo/footnote.xsl b/fo/footnote.xsl
index cc0242d..f4b8fa4 100644
--- a/fo/footnote.xsl
+++ b/fo/footnote.xsl
@@ -1,17 +1,16 @@
<?xml version='1.0'?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:fo="http://www.w3.org/1999/XSL/Format"
+ xmlns:d="http://docbook.org/ns/docbook"
+ xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:exsl="http://exslt.org/common"
- exclude-result-prefixes="exsl xlink"
+ exclude-result-prefixes="exsl xlink d"
version='1.0'>
<!-- ********************************************************************
- $Id: footnote.xsl 8359 2009-03-20 18:42:06Z bobstayton $
- ********************************************************************
This file is part of the XSL DocBook Stylesheet distribution.
- See ../README or http://docbook.sf.net/release/xsl/current/ for
+ See ../README or http://cdn.docbook.org/release/xsl/current/ for
copyright and other information.
******************************************************************** -->
@@ -31,9 +30,9 @@
</fo:inline>
</xsl:template>
-<xsl:template match="footnote">
+<xsl:template match="d:footnote">
<xsl:choose>
- <xsl:when test="ancestor::table or ancestor::informaltable">
+ <xsl:when test="ancestor::d:table or ancestor::d:informaltable">
<xsl:call-template name="format.footnote.mark">
<xsl:with-param name="mark">
<xsl:apply-templates select="." mode="footnote.number"/>
@@ -57,7 +56,7 @@
</xsl:choose>
</xsl:template>
-<xsl:template match="footnoteref">
+<xsl:template match="d:footnoteref">
<xsl:variable name="footnote" select="key('id',@linkend)"/>
<xsl:if test="not(local-name($footnote) = 'footnote')">
@@ -76,14 +75,14 @@ linkend/id: <xsl:value-of select="@linkend"/>
</xsl:call-template>
</xsl:template>
-<xsl:template match="footnote" mode="footnote.number">
+<xsl:template match="d:footnote" mode="footnote.number">
<xsl:choose>
<xsl:when test="string-length(@label) != 0">
<xsl:value-of select="@label"/>
</xsl:when>
- <xsl:when test="ancestor::table or ancestor::informaltable">
+ <xsl:when test="ancestor::d:table or ancestor::d:informaltable">
<xsl:variable name="tfnum">
- <xsl:number level="any" from="table|informaltable" format="1"/>
+ <xsl:number level="any" from="d:table|d:informaltable" format="1"/>
</xsl:variable>
<xsl:choose>
@@ -91,7 +90,7 @@ linkend/id: <xsl:value-of select="@linkend"/>
<xsl:value-of select="substring($table.footnote.number.symbols, $tfnum, 1)"/>
</xsl:when>
<xsl:otherwise>
- <xsl:number level="any" from="table|informaltable"
+ <xsl:number level="any" from="d:table|d:informaltable"
format="{$table.footnote.number.format}"/>
</xsl:otherwise>
</xsl:choose>
@@ -117,13 +116,13 @@ linkend/id: <xsl:value-of select="@linkend"/>
<!-- * non-zero -->
<!-- FIXME: list in @from is probably not complete -->
<xsl:number level="any"
- from="chapter|appendix|preface|article|refentry|bibliography"
- count="footnote[not(@label)][not(ancestor::table) and not(ancestor::informaltable)]
- |ulink[$ulink.footnotes != 0][node()][@url != .][not(ancestor::footnote)][$ulink.show != 0]
+ from="d:chapter|d:appendix|d:preface|d:article|d:refentry|d:bibliography"
+ count="d:footnote[not(@label)][not(ancestor::d:table) and not(ancestor::d:informaltable)]
+ |d:ulink[$ulink.footnotes != 0][node()][@url != .][not(ancestor::d:footnote)][$ulink.show != 0]
|*[node()][@xlink:href][not(@xlink:href = .)][not(starts-with(@xlink:href,'#'))]
[not(contains(@xlink:href,'#') and @xlink:role = $xolink.role)]
[not(@xlink:type) or @xlink:type='simple']
- [not(ancestor::footnote)][$ulink.footnotes != 0][$ulink.show != 0]
+ [not(ancestor::d:footnote)][$ulink.footnotes != 0][$ulink.show != 0]
"
format="1"/>
</xsl:variable>
@@ -145,7 +144,7 @@ linkend/id: <xsl:value-of select="@linkend"/>
<xsl:variable name="footnote.mark">
<xsl:call-template name="format.footnote.mark">
<xsl:with-param name="mark">
- <xsl:apply-templates select="ancestor::footnote" mode="footnote.number"/>
+ <xsl:apply-templates select="ancestor::d:footnote" mode="footnote.number"/>
</xsl:with-param>
</xsl:call-template>
</xsl:variable>
@@ -172,23 +171,23 @@ linkend/id: <xsl:value-of select="@linkend"/>
<!-- ==================================================================== -->
-<xsl:template match="footnote/para[1]
- |footnote/simpara[1]
- |footnote/formalpara[1]"
+<xsl:template match="d:footnote/d:para[1]
+ |d:footnote/d:simpara[1]
+ |d:footnote/d:formalpara[1]"
priority="2">
<!-- this only works if the first thing in a footnote is a para, -->
<!-- which is ok, because it usually is. -->
<fo:block>
<xsl:call-template name="format.footnote.mark">
<xsl:with-param name="mark">
- <xsl:apply-templates select="ancestor::footnote" mode="footnote.number"/>
+ <xsl:apply-templates select="ancestor::d:footnote" mode="footnote.number"/>
</xsl:with-param>
</xsl:call-template>
<xsl:apply-templates/>
</fo:block>
</xsl:template>
-<xsl:template match="footnote" mode="table.footnote.mode">
+<xsl:template match="d:footnote" mode="table.footnote.mode">
<xsl:choose>
<xsl:when test="local-name(*[1]) = 'para' or local-name(*[1]) = 'simpara'">
<fo:block xsl:use-attribute-sets="table.footnote.properties">