]> granicus.if.org Git - docbook-dsssl/commitdiff
Pass referrer and xrefstyle to "xref-to-suffix" and "xref-to-prefix"
authorThomas Schraitle <tom_schr@web.de>
Fri, 13 Sep 2013 07:07:05 +0000 (07:07 +0000)
committerThomas Schraitle <tom_schr@web.de>
Fri, 13 Sep 2013 07:07:05 +0000 (07:07 +0000)
modes (to use the same signature than "xref-to" mode) as discussed with
Bob on the mailinglist (2013-09-12)

xsl/fo/xref.xsl
xsl/html/xref.xsl

index 508398f046d83ac13c251185c153f40a3798cb59..bff98df2ef442fa5a7688fe68120f0dab0263cad 100644 (file)
   
         <xsl:when test="$target">
           <xsl:if test="not(parent::citation)">
-            <xsl:apply-templates select="$target" mode="xref-to-prefix"/>
+            <xsl:apply-templates select="$target" mode="xref-to-prefix">
+              <xsl:with-param name="referrer" select="."/>
+              <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
+            </xsl:apply-templates>
           </xsl:if>
   
           <xsl:apply-templates select="$target" mode="xref-to">
           </xsl:apply-templates>
   
           <xsl:if test="not(parent::citation)">
-            <xsl:apply-templates select="$target" mode="xref-to-suffix"/>
+            <xsl:apply-templates select="$target" mode="xref-to-suffix">
+              <xsl:with-param name="referrer" select="."/>
+              <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
+            </xsl:apply-templates>
           </xsl:if>
         </xsl:when>
         <xsl:otherwise>
 
 <!--- ==================================================================== -->
 
-<xsl:template match="*" mode="xref-to-prefix"/>
-<xsl:template match="*" mode="xref-to-suffix"/>
+<xsl:template match="*" mode="xref-to-prefix">
+  <xsl:param name="referrer"/>
+  <xsl:param name="xrefstyle"/>
+  <xsl:param name="verbose" select="1"/>
+</xsl:template>
+<xsl:template match="*" mode="xref-to-suffix">
+  <xsl:param name="referrer"/>
+  <xsl:param name="xrefstyle"/>
+  <xsl:param name="verbose" select="1"/>
+</xsl:template>
 
 <xsl:template match="*" mode="xref-to">
   <xsl:param name="referrer"/>
   <xsl:param name="xrefstyle"/>
   <xsl:param name="verbose" select="1"/>
 
-
   <xsl:if test="$verbose != 0">
     <xsl:message>
       <xsl:text>Don't know what gentext to create for xref to: "</xsl:text>
index d50aebd53788f37514f916904f74dabc074a8326..07581846cd449eb53872089f4a67fc031a60ced8 100644 (file)
   
       <xsl:when test="$target">
         <xsl:if test="not(parent::citation)">
-          <xsl:apply-templates select="$target" mode="xref-to-prefix"/>
+          <xsl:apply-templates select="$target" mode="xref-to-prefix">
+            <xsl:with-param name="referrer" select="."/>
+            <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
+          </xsl:apply-templates>
         </xsl:if>
   
         <xsl:apply-templates select="$target" mode="xref-to">
         </xsl:apply-templates>
   
         <xsl:if test="not(parent::citation)">
-          <xsl:apply-templates select="$target" mode="xref-to-suffix"/>
+          <xsl:apply-templates select="$target" mode="xref-to-suffix">
+            <xsl:with-param name="referrer" select="."/>
+            <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
+          </xsl:apply-templates>
         </xsl:if>
       </xsl:when>
 
 
 <!-- ==================================================================== -->
 
-<xsl:template match="*" mode="xref-to-prefix"/>
-<xsl:template match="*" mode="xref-to-suffix"/>
+<xsl:template match="*" mode="xref-to-prefix">
+  <xsl:param name="referrer"/>
+  <xsl:param name="xrefstyle"/>
+  <xsl:param name="verbose" select="1"/>
+</xsl:template>
+<xsl:template match="*" mode="xref-to-suffix">
+  <xsl:param name="referrer"/>
+  <xsl:param name="xrefstyle"/>
+  <xsl:param name="verbose" select="1"/>
+</xsl:template>
 
 <xsl:template match="*" mode="xref-to">
   <xsl:param name="referrer"/>