[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdelibs/kdoctools/customization
From:       Lauri Watts <lauri () kde ! org>
Date:       2004-10-23 23:28:57
Message-ID: 20041023232857.7AD5116BE9 () office ! kde ! org
[Download RAW message or body]

CVS commit by lauri: 

Obfuscate email in all versions, to cut some of the email traffic down to people
who actually mean to email the doc authors.


  M +32 -0     kde-navig.xsl   1.13


--- kdelibs/kdoctools/customization/kde-navig.xsl  #1.12:1.13
@@ -2,4 +2,36 @@
                 version="1.0">
 
+<xsl:template match="email">
+  <xsl:call-template name="inline.monoseq">
+    <xsl:with-param name="content">
+      <xsl:text>(</xsl:text>
+                <xsl:call-template name="replaceCharsInString">
+                        <xsl:with-param name="stringIn" select="."/>
+                        <xsl:with-param name="charsIn" select="'@'"/>
+                        <xsl:with-param name="charsOut" select="' AT '"/>
+                </xsl:call-template>
+      <xsl:text>)</xsl:text>
+    </xsl:with-param>
+  </xsl:call-template>
+</xsl:template>
+<xsl:template name="replaceCharsInString">
+  <xsl:param name="stringIn"/>
+  <xsl:param name="charsIn"/>
+  <xsl:param name="charsOut"/>
+  <xsl:choose>
+    <xsl:when test="contains($stringIn,$charsIn)">
+      <xsl:value-of select="concat(substring-before($stringIn,$charsIn),$charsOut)"/>
+      <xsl:call-template name="replaceCharsInString">
+        <xsl:with-param name="stringIn" select="substring-after($stringIn,$charsIn)"/>
+        <xsl:with-param name="charsIn" select="$charsIn"/>
+        <xsl:with-param name="charsOut" select="$charsOut"/>
+      </xsl:call-template>
+    </xsl:when>
+    <xsl:otherwise>
+      <xsl:value-of select="$stringIn"/>
+    </xsl:otherwise>
+  </xsl:choose>
+</xsl:template>
+
 
 <xsl:template name="header.navigation">


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic