]> granicus.if.org Git - docbook-dsssl/commitdiff
Eliminated spurious error messages when collecting olink targets.
authorBob Stayton <bobs@sagehill.net>
Fri, 28 May 2004 08:07:08 +0000 (08:07 +0000)
committerBob Stayton <bobs@sagehill.net>
Fri, 28 May 2004 08:07:08 +0000 (08:07 +0000)
xsl/common/gentext.xsl
xsl/common/targets.xsl
xsl/common/titles.xsl

index 1570b742f3b3aa1e66af0a4c7d3d5a015737beb5..ebd0ec0563bd03bc2d34b5d74664bad73888e3b4 100644 (file)
   <xsl:param name="purpose"/>
   <xsl:param name="xrefstyle"/>
   <xsl:param name="referrer"/>
+  <xsl:param name="verbose" select="1"/>
 
   <xsl:variable name="template">
     <xsl:choose>
   </xsl:message>
 -->
 
-  <xsl:if test="$template = ''">
+  <xsl:if test="$template = '' and $verbose != 0">
     <xsl:message>
       <xsl:text>object.xref.markup: empty xref template</xsl:text>
       <xsl:text> for linkend="</xsl:text>
     <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
     <xsl:with-param name="referrer" select="$referrer"/>
     <xsl:with-param name="template" select="$template"/>
+    <xsl:with-param name="verbose" select="$verbose"/>
   </xsl:call-template>
 </xsl:template>
 
 <xsl:template match="listitem" mode="object.xref.markup">
+  <xsl:param name="verbose" select="1"/>
+
   <xsl:choose>
     <xsl:when test="parent::orderedlist">
       <xsl:variable name="template">
         <xsl:with-param name="template" select="$template"/>
       </xsl:call-template>
     </xsl:when>
-    <xsl:otherwise>
+    <xsl:when test="$verbose != 0">
       <xsl:message>
         <xsl:text>Xref is only supported to listitems in an</xsl:text>
         <xsl:text> orderedlist: </xsl:text>
         <xsl:value-of select="@id"/>
       </xsl:message>
       <xsl:text>???</xsl:text>
-    </xsl:otherwise>
+    </xsl:when>
   </xsl:choose>
 </xsl:template>
 
   <xsl:param name="purpose"/>
   <xsl:param name="xrefstyle"/>
   <xsl:param name="referrer"/>
+  <xsl:param name="verbose"/>
 
   <xsl:choose>
     <xsl:when test="contains($template, '%')">
                 <xsl:otherwise>
                   <xsl:apply-templates select="." mode="title.markup">
                     <xsl:with-param name="allow-anchors" select="$allow-anchors"/>
+                    <xsl:with-param name="verbose" select="$verbose"/>
                   </xsl:apply-templates>
                 </xsl:otherwise>
               </xsl:choose>
         <xsl:with-param name="purpose" select="$purpose"/>
         <xsl:with-param name="xrefstyle" select="$xrefstyle"/>
         <xsl:with-param name="referrer" select="$referrer"/>
+        <xsl:with-param name="verbose" select="$verbose"/>
       </xsl:call-template>
     </xsl:when>
     <xsl:otherwise>
index df14b6ec2056f8d461b129559724c06336d8d8de..6da2037051af72eb9716438a573fe0b1d2bfa371 100644 (file)
@@ -140,7 +140,9 @@ document output.
       <xsl:with-param name="nd" select="$nd"/>
     </xsl:call-template>
     <ttl>
-      <xsl:apply-templates select="$nd" mode="title.markup"/>
+      <xsl:apply-templates select="$nd" mode="title.markup">
+        <xsl:with-param name="verbose" select="0"/>
+      </xsl:apply-templates>
     </ttl>
     <xreftext>
       <xsl:choose>
@@ -150,7 +152,9 @@ document output.
           </xsl:call-template>
         </xsl:when>
         <xsl:otherwise>
-          <xsl:apply-templates select="$nd" mode="xref-to"/>
+          <xsl:apply-templates select="$nd" mode="xref-to">
+            <xsl:with-param name="verbose" select="0"/>
+          </xsl:apply-templates>
         </xsl:otherwise>
       </xsl:choose>
     </xreftext>
index 33f0012fd3cf59cea572cc659d173a92cf3f507d..cabea01e8591dfa86eb50ef499da2cc1f132b576 100644 (file)
@@ -44,7 +44,7 @@ title of the element. This does not include the label.
       <xsl:apply-templates select="parent::*" mode="title.markup"/>
     </xsl:when>
     <xsl:otherwise>
-      <xsl:if test="$verbose">
+      <xsl:if test="$verbose != 0">
         <xsl:message>
           <xsl:text>Request for title of element with no title: </xsl:text>
           <xsl:value-of select="name(.)"/>