Showing:

Documentation
Parameters
Used by
References
Included from
Source
Stylesheet i18n.xsl
Documentation

Description

TEI stylesheet definitions common for all of HTML, FO and LaTeX outputs

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Author: See AUTHORS

Id: $Id: i18n.xsl 7666 2010-06-08 19:23:31Z rahtz $

Copyright: 2008, TEI Consortium

Included from
Stylesheet version 2.0
Template i18n
Documentation

Description

[common] give language-specific version of a word or phrase

Parameters

word the word(s) to translate

Namespace No namespace
Used by
References
Template myi18n
Key KEYS
Parameter documentationLanguage
Parameters
QName Namespace
word No namespace
Import precedence 1
Source
<xsl:template name="i18n">
  <xsl:param name="word"/>
  <xsl:variable name="Word">
    <xsl:value-of select="normalize-space($word)"/>
  </xsl:variable>
  <xsl:variable name="local">
    <xsl:call-template name="myi18n">
      <xsl:with-param name="word">
        <xsl:value-of select="$word"/>
      </xsl:with-param>
    </xsl:call-template>
  </xsl:variable>
  <xsl:choose>
    <xsl:when test="string-length($local)>0">
      <xsl:value-of select="$local"/>
    </xsl:when>
    <xsl:otherwise>
      <xsl:for-each select="document('../i18n.xml',document(''))">
        <xsl:choose>
          <xsl:when test="key('KEYS',$Word)/text[@xml:lang=$documentationLanguage]">
            <xsl:value-of select="key('KEYS',$Word)/text[@xml:lang=$documentationLanguage]"/>
          </xsl:when>
          <xsl:when test="key('KEYS',$Word)/text[@lang3=$documentationLanguage]">
            <xsl:value-of select="key('KEYS',$Word)/text[lang3=$documentationLanguage]"/>
          </xsl:when>
          <xsl:otherwise>
            <!--
		      <xsl:if test="$verbose='true'">
		      <xsl:message>NO TRANSLATION for <xsl:value-of 
		      select="$word"/> in <xsl:value-of select="$documentationLanguage"/></xsl:message>
		      </xsl:if>
		  -->
            <xsl:value-of select="key('KEYS',$Word)/text[@xml:lang='en']"/>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:for-each>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Template myi18n
Documentation

Description

[localisation] dummy template for overriding in a local system

Parameters

word the word(s) to translate

Namespace No namespace
Used by
Template i18n
Parameters
QName Namespace
word No namespace
Import precedence 1
Source
<xsl:template name="myi18n">
  <xsl:param name="word"/>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Template contentsHeading
Documentation

Description

[common] Prefix text before an auto-generated table of contents
Namespace No namespace
References
Template i18n
Import precedence 1
Source
<xsl:template name="contentsHeading">
  <xsl:call-template name="i18n">
    <xsl:with-param name="word">contentsHeading</xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Template contentsWord
Documentation

Description

[common] Title for "Contents"; by default uses language-specific lookup table.
Namespace No namespace
References
Template i18n
Import precedence 1
Source
<xsl:template name="contentsWord">
  <xsl:call-template name="i18n">
    <xsl:with-param name="word">contentsWord</xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Template feedbackWords
Documentation

Description

[common] Title for "Feedback"
Namespace No namespace
References
Template i18n
Import precedence 1
Source
<xsl:template name="feedbackWords">
  <xsl:call-template name="i18n">
    <xsl:with-param name="word">feedbackWords</xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Template searchWords
Documentation

Description

[common] Title for "Search"; by default uses language-specific lookup table.
Namespace No namespace
References
Template i18n
Import precedence 1
Source
<xsl:template name="searchWords">
  <xsl:call-template name="i18n">
    <xsl:with-param name="word">searchWords</xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../common2/i18n.xsl
Parameter documentationLanguage
Namespace No namespace
Used by
Template i18n
Source
<xsl:param name="documentationLanguage">en</xsl:param>
Stylesheet location ../../../common2/i18n.xsl
Parameter lang
Documentation

Description

The language to use when generating text (use ISO 2-letter codes)
Namespace No namespace
Source
<xsl:param name="lang">en</xsl:param>
Stylesheet location ../../../common2/i18n.xsl
Parameter doclang
Documentation

Description

[common] Prefix text before an auto-generated table of contents

Description

The language the text is in (use ISO 2-letter codes)
Namespace No namespace
Source
<xsl:param name="doclang">en</xsl:param>
Stylesheet location ../../../common2/i18n.xsl
Key KEYS
Namespace No namespace
Match entry
Use key
Used by
Template i18n
Source
<xsl:key match="entry" name="KEYS" use="key"/>
Stylesheet location ../../../common2/i18n.xsl