Changeset d6cbb12c for stylesheets/lfs-xsl/xhtml
- Timestamp:
- 01/18/2024 12:11:58 PM (9 months ago)
- Branches:
- 12.1, 12.1-rc1, 12.2, 12.2-rc1, multilib, trunk, xry111/arm64, xry111/clfs-ng, xry111/loongarch, xry111/loongarch-12.1, xry111/loongarch-12.2, xry111/mips64el, xry111/multilib, xry111/update-glibc
- Children:
- 9512d6c
- Parents:
- 0cbc2c0a
- git-author:
- Pierre Labastie <pierre.labastie@…> (01/18/2024 12:07:22 PM)
- git-committer:
- Pierre Labastie <pierre.labastie@…> (01/18/2024 12:11:58 PM)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
stylesheets/lfs-xsl/xhtml/lfs-xref.xsl
r0cbc2c0a rd6cbb12c 2 2 3 3 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 4 xmlns:xlink="http://www.w3.org/1999/xlink"5 4 xmlns="http://www.w3.org/1999/xhtml" 6 exclude-result-prefixes="xlink"7 5 version="1.0"> 8 6 … … 16 14 17 15 <!-- xref: 18 Added role variable and use it when calling mode xref-to.--> 16 Added role variable and use it when calling mode xref-to. 17 Also remove code for xlink:href attributes in xref elements 18 since we don't use it.--> 19 19 <!-- The original template is in {docbook-xsl}/xhtml/xref.xsl --> 20 20 <xsl:template match="xref" name="xref"> 21 <xsl:param name="xhref" select="@xlink:href"/>22 <!-- is the @xlink:href a local idref link? -->23 <xsl:param name="xlink.idref">24 <xsl:if test="starts-with($xhref,'#') and (not(contains($xhref,'('))25 or starts-with($xhref, '#xpointer(id('))">26 <xsl:call-template name="xpointer.idref">27 <xsl:with-param name="xpointer" select="$xhref"/>28 </xsl:call-template>29 </xsl:if>30 </xsl:param>31 <xsl:param name="xlink.targets" select="key('id',$xlink.idref)"/>32 21 <xsl:param name="linkend.targets" select="key('id',@linkend)"/> 33 <xsl:param name="target" select=" ($xlink.targets | $linkend.targets)[1]"/>22 <xsl:param name="target" select="$linkend.targets[1]"/> 34 23 <!-- Added role variable --> 35 24 <xsl:variable name="role" select="@role"/> … … 86 75 <xsl:message> 87 76 <xsl:text>ERROR: xref linking to </xsl:text> 88 <xsl:value-of select="@linkend |@xlink:href"/>77 <xsl:value-of select="@linkend"/> 89 78 <xsl:text> has no generated link text.</xsl:text> 90 79 </xsl:message>
Note:
See TracChangeset
for help on using the changeset viewer.