[jsword-svn] bibledesktop/resource/xsl/cswing s
jswordcvs at crosswire.org
jswordcvs at crosswire.org
Mon May 2 20:13:17 MST 2005
Update of /cvs/jsword/bibledesktop/resource/xsl/cswing
In directory www.crosswire.org:/tmp/cvs-serv3130/resource/xsl/cswing
Modified Files:
simple.xsl
Log Message:
Fixed a problem with two or more strongs numbers per word.
Index: simple.xsl
===================================================================
RCS file: /cvs/jsword/bibledesktop/resource/xsl/cswing/simple.xsl,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** simple.xsl 6 Apr 2005 04:07:41 -0000 1.17
--- simple.xsl 3 May 2005 03:13:15 -0000 1.18
***************
*** 345,348 ****
--- 345,349 ----
<xsl:template name="lemma">
<xsl:param name="lemma"/>
+ <xsl:param name="part" select="0"/>
<xsl:variable name="orig-lemma" select="substring-after($lemma, ':')"/>
<xsl:variable name="protocol">
***************
*** 366,377 ****
</xsl:choose>
</xsl:variable>
<xsl:choose>
<xsl:when test="$separator = ''">
! <sub class="strongs"><a href="{$protocol}{$orig-lemma}">S<xsl:number level="any" from="/osis//verse" format="1"/></a></sub>
</xsl:when>
<xsl:otherwise>
! <sub class="strongs"><a href="{$protocol}{$orig-lemma}">S<xsl:number level="any" from="/osis//verse" format="1"/></a></sub>
<xsl:call-template name="lemma">
<xsl:with-param name="lemma" select="substring-after($lemma, $separator)"/>
</xsl:call-template>
</xsl:otherwise>
--- 367,398 ----
</xsl:choose>
</xsl:variable>
+ <xsl:variable name="sub">
+ <xsl:choose>
+ <xsl:when test="$separator != '' and $part = '0'">
+ <xsl:value-of select="$part + 1"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="$part"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:variable>
<xsl:choose>
<xsl:when test="$separator = ''">
! <sub class="strongs"><a href="{$protocol}{$orig-lemma}">S<xsl:number level="any" from="/osis//verse" format="1"/><xsl:number value="$sub" format="a"/></a></sub>
</xsl:when>
<xsl:otherwise>
! <sub class="strongs"><a href="{$protocol}{substring-before($orig-lemma, $separator)}">S<xsl:number level="single" from="/osis//verse" format="1"/><xsl:number value="$sub" format="a"/></a>, </sub>
<xsl:call-template name="lemma">
<xsl:with-param name="lemma" select="substring-after($lemma, $separator)"/>
+ <xsl:with-param name="part">
+ <xsl:choose>
+ <xsl:when test="$sub">
+ <xsl:value-of select="$sub + 1"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="1"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:with-param>
</xsl:call-template>
</xsl:otherwise>
More information about the jsword-svn
mailing list