[octc-svndiff] SF.net SVN: octc:[420] trunk/tools/xsl/tokenizer.xsl
Brought to you by:
bansp
|
From: <ba...@us...> - 2010-12-18 23:01:53
|
Revision: 420
http://octc.svn.sourceforge.net/octc/?rev=420&view=rev
Author: bansp
Date: 2010-12-18 23:01:47 +0000 (Sat, 18 Dec 2010)
Log Message:
-----------
keep head elements distinct
Modified Paths:
--------------
trunk/tools/xsl/tokenizer.xsl
Modified: trunk/tools/xsl/tokenizer.xsl
===================================================================
--- trunk/tools/xsl/tokenizer.xsl 2010-12-18 23:00:53 UTC (rev 419)
+++ trunk/tools/xsl/tokenizer.xsl 2010-12-18 23:01:47 UTC (rev 420)
@@ -18,7 +18,8 @@
</xd:doc>
<xd:doc>Should <head> elements be tokenized? There is no single good answer to this, but this information should
- definitely be kept in the file somehow, so that it can make it into the header.</xd:doc>
+ definitely be kept in the file somehow, so that it can make it into the header. If this is set, the relevant elements
+ will receive type="head".</xd:doc>
<xsl:param name="tokenize_heads" as="xs:boolean" select="true()"/>
<xd:doc>For debugging. Print the dereferenced string inside a comment after each segment.</xd:doc>
@@ -149,7 +150,7 @@
<xsl:when test="local-name() eq 'head' and not($tokenize_heads)"/>
<xsl:otherwise>
<xsl:element name="ab" namespace="http://www.tei-c.org/ns/1.0">
- <xsl:attribute name="type" select="'para'"/> <!-- note the type here - should it always be 'para'? -->
+ <xsl:attribute name="type" select="if (local-name() eq 'head') then 'head' else 'para'"/> <!-- note the type here - should it always be 'para'? -->
<xsl:attribute name="corresp" select="concat($my_fname,'#',./@xml:id)"/>
<xsl:variable name="text_seq" as="element()+">
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|