Mode:

Compact lists

Showing:

Documentation
Source
Main stylesheet from.xsl
Documentation

Description

This software is dual-licensed: 1. Distributed under a Creative Commons Attribution-ShareAlike 3.0 Unported License http://creativecommons.org/licenses/by-sa/3.0/ 2. http://www.opensource.org/licenses/BSD-2-Clause Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. This software is provided by the copyright holders and contributors "as is" and any express or implied warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose are disclaimed. In no event shall the copyright holder or contributors be liable for any direct, indirect, incidental, special, exemplary, or consequential damages (including, but not limited to, procurement of substitute goods or services; loss of use, data, or profits; or business interruption) however caused and on any theory of liability, whether in contract, strict liability, or tort (including negligence or otherwise) arising in any way out of the use of this software, even if advised of the possibility of such damage.

Author: See AUTHORS

Copyright: 2013, TEI Consortium

Stylesheet version 3.0
Template *
Namespace No namespace
Match *
Mode #default
Import precedence 0
Source
<xsl:template match="*">
  <xsl:choose>
    <xsl:when test="namespace-uri()=''">
      <xsl:element namespace="http://www.tei-c.org/ns/1.0" name="{local-name(.)}">
        <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
      </xsl:element>
    </xsl:when>
    <xsl:otherwise>
      <xsl:copy>
        <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
      </xsl:copy>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location from.xsl
Template @*|processing-instruction()|comment()
Namespace No namespace
Match @*|processing-instruction()|comment()
Mode #default
Import precedence 0
Source
<xsl:template match="@*|processing-instruction()|comment()">
  <xsl:copy/>
</xsl:template>
Stylesheet location from.xsl
Template text()
Namespace No namespace
Match text()
Mode #default
Import precedence 0
Source
<xsl:template match="text()">
  <xsl:value-of select="."/>
</xsl:template>
Stylesheet location from.xsl
Template teiCorpus.2
Namespace No namespace
Match teiCorpus.2
Mode #default
Import precedence 0
Source
<xsl:template match="teiCorpus.2">
  <teiCorpus>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </teiCorpus>
</xsl:template>
Stylesheet location from.xsl
Template witness/@sigil
Namespace No namespace
Match witness/@sigil
Mode #default
Import precedence 0
Source
<xsl:template match="witness/@sigil">
  <xsl:attribute name="xml:id">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template witList
Namespace No namespace
Match witList
Mode #default
Import precedence 0
Source
<xsl:template match="witList">
  <listWit>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </listWit>
</xsl:template>
Stylesheet location from.xsl
Template TEI.2
Namespace No namespace
Match TEI.2
Mode #default
Import precedence 0
Source
<xsl:template match="TEI.2">
  <TEI>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </TEI>
</xsl:template>
Stylesheet location from.xsl
Template xref
Namespace No namespace
Match xref
Mode #default
Import precedence 0
Source
<xsl:template match="xref">
  <xsl:element namespace="http://www.tei-c.org/ns/1.0" name="ref">
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </xsl:element>
</xsl:template>
Stylesheet location from.xsl
Template xptr
Namespace No namespace
Match xptr
Mode #default
Import precedence 0
Source
<xsl:template match="xptr">
  <xsl:element namespace="http://www.tei-c.org/ns/1.0" name="ptr">
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </xsl:element>
</xsl:template>
Stylesheet location from.xsl
Template figure[@url]
Namespace No namespace
Match figure[@url]
Mode #default
Import precedence 0
Source
<xsl:template match="figure[@url]">
  <figure>
    <graphic>
      <xsl:apply-templates select="@*"/>
    </graphic>
    <xsl:apply-templates/>
  </figure>
</xsl:template>
Stylesheet location from.xsl
Template figure/@entity
Namespace No namespace
Match figure/@entity
Mode #default
Import precedence 0
Source
<xsl:template match="figure/@entity"/>
Stylesheet location from.xsl
Template figure[@entity]
Namespace No namespace
Match figure[@entity]
Mode #default
Import precedence 0
Source
<xsl:template match="figure[@entity]">
  <figure>
    <graphic>
      <xsl:attribute name="url">
        <xsl:choose>
          <xsl:when test="unparsed-entity-uri(@entity)=''">
            <xsl:text>ENTITY_</xsl:text>
            <xsl:value-of select="@entity"/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:value-of select="unparsed-entity-uri(@entity)"/>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:attribute>
      <xsl:apply-templates select="@*"/>
    </graphic>
    <xsl:apply-templates/>
  </figure>
</xsl:template>
Stylesheet location from.xsl
Template state
Namespace No namespace
Match state
Mode #default
Import precedence 0
Source
<xsl:template match="state">
  <refState>
    <xsl:apply-templates select="@*|*|text()|comment()|processing-instruction()"/>
  </refState>
</xsl:template>
Stylesheet location from.xsl
Template @targType
Namespace No namespace
Match @targType
Mode #default
Import precedence 0
Source
<xsl:template match="@targType">
  <xsl:attribute name="type">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template dateRange
Documentation

Description

 lost elements 
Namespace No namespace
Match dateRange
Mode #default
Import precedence 0
Source
<xsl:template match="dateRange">
  <date>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </date>
</xsl:template>
Stylesheet location from.xsl
Template dateRange/@from
Namespace No namespace
Match dateRange/@from
Mode #default
Import precedence 0
Source
<xsl:template match="dateRange/@from">
  <xsl:copy-of select="."/>
</xsl:template>
Stylesheet location from.xsl
Template dateRange/@to
Namespace No namespace
Match dateRange/@to
Mode #default
Import precedence 0
Source
<xsl:template match="dateRange/@to">
  <xsl:copy-of select="."/>
</xsl:template>
Stylesheet location from.xsl
Template language
Namespace No namespace
Match language
Mode #default
Import precedence 0
Source
<xsl:template match="language">
  <xsl:element namespace="http://www.tei-c.org/ns/1.0" name="language">
    <xsl:choose>
      <xsl:when test="@id">
        <xsl:attribute name="ident">
          <xsl:value-of select="@id"/>
        </xsl:attribute>
      </xsl:when>
      <xsl:when test=".='English'">
        <xsl:attribute name="ident">en</xsl:attribute>
      </xsl:when>
    </xsl:choose>
    <xsl:apply-templates select="*|processing-instruction()|comment()|text()"/>
  </xsl:element>
</xsl:template>
Stylesheet location from.xsl
Template @date.created
Documentation

Description

 attributes lost 
 dropped from TEI. Added as new change records later 
Namespace No namespace
Match @date.created
Mode #default
Import precedence 0
Source
<xsl:template match="@date.created"/>
Stylesheet location from.xsl
Template @date.updated
Namespace No namespace
Match @date.updated
Mode #default
Import precedence 0
Source
<xsl:template match="@date.updated"/>
Stylesheet location from.xsl
Template refsDecl/@doctype
Documentation

Description

 dropped from TEI. No replacement 
Namespace No namespace
Match refsDecl/@doctype
Mode #default
Import precedence 0
Source
<xsl:template match="refsDecl/@doctype"/>
Stylesheet location from.xsl
Template date/@value
Documentation

Description

 attributes changed name 
Namespace No namespace
Match date/@value
Mode #default
Import precedence 0
Source
<xsl:template match="date/@value">
  <xsl:attribute name="when">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template @url
Namespace No namespace
Match @url
Mode #default
Import precedence 0
Source
<xsl:template match="@url">
  <xsl:attribute name="target">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template figure/@url
Namespace No namespace
Match figure/@url
Mode #default
Import precedence 0
Source
<xsl:template match="figure/@url">
  <xsl:attribute name="url">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template @doc
Namespace No namespace
Match @doc
Mode #default
Import precedence 0
Source
<xsl:template match="@doc">
  <xsl:attribute name="target">
    <xsl:value-of select="unparsed-entity-uri(.)"/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template @id
Namespace No namespace
Match @id
Mode #default
Import precedence 0
Source
<xsl:template match="@id">
  <xsl:choose>
    <xsl:when test="parent::lang">
      <xsl:attribute name="ident">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:when>
    <xsl:otherwise>
      <xsl:attribute name="xml:id">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location from.xsl
Template @lang
Namespace No namespace
Match @lang
Mode #default
Import precedence 0
Source
<xsl:template match="@lang">
  <xsl:attribute name="xml:lang">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template change/@date
Namespace No namespace
Match change/@date
Mode #default
Import precedence 0
Source
<xsl:template match="change/@date"/>
Stylesheet location from.xsl
Template date/@certainty
Namespace No namespace
Match date/@certainty
Mode #default
Import precedence 0
Source
<xsl:template match="date/@certainty">
  <xsl:attribute name="cert">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template variantEncoding/@location
Documentation

Description

 all pointing attributes preceded by # 
Namespace No namespace
Match variantEncoding/@location
Mode #default
Import precedence 0
Source
<xsl:template match="variantEncoding/@location">
  <xsl:copy-of select="."/>
</xsl:template>
Stylesheet location from.xsl
Template @ana|@active|@adj|@adjFrom|@adjTo|@children|@class|@code|@copyOf|@corresp|@decls|@domains|@end|@exclude|@fVal|@feats|@follow|@hand|@inst|@langKey|@location|@mergedin|@new|@next|@old|@origin|@otherLangs|@parent|@passive|@perf|@prev|@render|@resp|@sameAs|@scheme|@script|@select|@since|@start|@synch|@target|@targetEnd|@value|@value|@who|@wit
Namespace No namespace
Match @ana|@active|@adj|@adjFrom|@adjTo|@children|@class|@code|@copyOf|@corresp|@decls|@domains|@end|@exclude|@fVal|@feats|@follow|@hand|@inst|@langKey|@location|@mergedin|@new|@next|@old|@origin|@otherLangs|@parent|@passive|@perf|@prev|@render|@resp|@sameAs|@scheme|@script|@select|@since|@start|@synch|@target|@targetEnd|@value|@value|@who|@wit
Mode #default
Import precedence 0
Source
<xsl:template match="@ana|@active|@adj|@adjFrom|@adjTo|@children|@class|@code|@copyOf|@corresp|@decls|@domains|@end|@exclude|@fVal|@feats|@follow|@hand|@inst|@langKey|@location|@mergedin|@new|@next|@old|@origin|@otherLangs|@parent|@passive|@perf|@prev|@render|@resp|@sameAs|@scheme|@script|@select|@since|@start|@synch|@target|@targetEnd|@value|@value|@who|@wit">
  <xsl:variable name="vals">
    <xsl:for-each select="tokenize(.,' ')">
      <a>
        <xsl:choose>
          <xsl:when test="starts-with(.,'http') or starts-with(.,'ftp') or starts-with(.,'mailto')">
            <xsl:sequence select="."/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:text>#</xsl:text>
            <xsl:sequence select="."/>
          </xsl:otherwise>
        </xsl:choose>
      </a>
    </xsl:for-each>
  </xsl:variable>
  <xsl:attribute name="{name(.)}" select="string-join($vals/tei:a,' ')"/>
</xsl:template>
Stylesheet location from.xsl
Template bibl/imprint
Documentation

Description

 fool around with selected elements 
 imprint is no longer allowed inside bibl 
Namespace No namespace
Match bibl/imprint
Mode #default
Import precedence 0
Source
<xsl:template match="bibl/imprint">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location from.xsl
Template editionStmt/editor
Namespace No namespace
Match editionStmt/editor
Mode #default
Import precedence 0
Source
<xsl:template match="editionStmt/editor">
  <respStmt>
    <resp>
      <xsl:value-of select="@role"/>
    </resp>
    <name>
      <xsl:apply-templates/>
    </name>
  </respStmt>
</xsl:template>
Stylesheet location from.xsl
Template teiHeader
Documentation

Description

 header 
Namespace No namespace
Match teiHeader
Mode #default
Import precedence 0
Source
<xsl:template match="teiHeader">
  <teiHeader>
    <xsl:apply-templates select="@*|*|comment()|processing-instruction()"/>
    <xsl:if test="not(revisionDesc) and (@date.created or @date.updated)">
      <revisionDesc>
        <xsl:if test="@date.updated">
          <change>
            <label>updated</label>
            <date>
              <xsl:value-of select="@date.updated"/>
            </date>
            <label>Date edited</label>
          </change>
        </xsl:if>
        <xsl:if test="@date.created">
          <change>
            <label>created</label>
            <date>
              <xsl:value-of select="@date.created"/>
            </date>
            <label>Date created</label>
          </change>
        </xsl:if>
      </revisionDesc>
    </xsl:if>
    <!--
	  <change when="{$today}">Converted to TEI P5 XML by p4top5.xsl
	  written by Sebastian
	  Rahtz at Oxford University Computing Services.</change>
	  </revisionDesc>
	  </xsl:if>
      -->
  </teiHeader>
</xsl:template>
Stylesheet location from.xsl
Template revisionDesc
Namespace No namespace
Match revisionDesc
Mode #default
Import precedence 0
Source
<xsl:template match="revisionDesc">
  <revisionDesc>
    <xsl:apply-templates select="@*|*|comment()|processing-instruction()"/>
  </revisionDesc>
</xsl:template>
Stylesheet location from.xsl
Template publicationStmt
Namespace No namespace
Match publicationStmt
Mode #default
Import precedence 0
Source
<xsl:template match="publicationStmt">
  <publicationStmt>
    <xsl:apply-templates select="@*|*|comment()|processing-instruction()"/>
    <!--
	  <availability>
	  <p>Licensed under <ptr target="http://creativecommons.org/licenses/by-sa/2.0/uk/"/></p>
	  </availability>
      -->
  </publicationStmt>
</xsl:template>
Stylesheet location from.xsl
Template space/@extent
Documentation

Description

 space does not have @extent any more 
Namespace No namespace
Match space/@extent
Mode #default
Import precedence 0
Source
<xsl:template match="space/@extent">
  <xsl:attribute name="quantity">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template entryFree/@key
Documentation

Description

 word key 
Namespace No namespace
Match entryFree/@key
Mode #default
Import precedence 0
Source
<xsl:template match="entryFree/@key">
  <xsl:attribute name="sortKey">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template tagsDecl
Documentation

Description

 tagsDecl has a compulsory namespace child now 
Namespace No namespace
Match tagsDecl
Mode #default
Import precedence 0
Source
<xsl:template match="tagsDecl">
  <xsl:if test="*">
    <tagsDecl>
      <namespace name="http://www.tei-c.org/ns/1.0">
        <xsl:apply-templates select="*|comment()|processing-instruction"/>
      </namespace>
    </tagsDecl>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template orgName/orgTitle
Documentation

Description

 orgTitle inside orgName? redundant 
Namespace No namespace
Match orgName/orgTitle
Mode #default
Import precedence 0
Source
<xsl:template match="orgName/orgTitle">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location from.xsl
Template corr[@sic]
Documentation

Description

 no need for empty <p> in sourceDesc 
 xsl:template match="sourceDesc/p[string-length(.)=0]"/
 No, an empty sourceDesc is invalid in tei_all (LB) 
 start creating the new choice element 
Namespace No namespace
Match corr[@sic]
Mode #default
Import precedence 0
Source
<xsl:template match="corr[@sic]">
  <choice>
    <corr>
      <xsl:value-of select="text()"/>
    </corr>
    <sic>
      <xsl:value-of select="@sic"/>
    </sic>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template gap/@desc
Namespace No namespace
Match gap/@desc
Mode #default
Import precedence 0
Source
<xsl:template match="gap/@desc"/>
Stylesheet location from.xsl
Template gap
Namespace No namespace
Match gap
Mode #default
Import precedence 0
Source
<xsl:template match="gap">
  <gap>
    <xsl:apply-templates select="@*"/>
    <xsl:if test="@desc">
      <desc>
        <xsl:value-of select="@desc"/>
      </desc>
    </xsl:if>
  </gap>
</xsl:template>
Stylesheet location from.xsl
Template sic[@corr]
Namespace No namespace
Match sic[@corr]
Mode #default
Import precedence 0
Source
<xsl:template match="sic[@corr]">
  <choice>
    <sic>
      <xsl:apply-templates/>
    </sic>
    <corr>
      <xsl:value-of select="@corr"/>
    </corr>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template abbr[@expan]
Namespace No namespace
Match abbr[@expan]
Mode #default
Import precedence 0
Source
<xsl:template match="abbr[@expan]">
  <choice>
    <abbr>
      <xsl:apply-templates/>
    </abbr>
    <expan>
      <xsl:value-of select="@expan"/>
    </expan>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template expan[@abbr]
Namespace No namespace
Match expan[@abbr]
Mode #default
Import precedence 0
Source
<xsl:template match="expan[@abbr]">
  <choice>
    <expan>
      <xsl:apply-templates/>
    </expan>
    <abbr>
      <xsl:value-of select="@abbr"/>
    </abbr>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template change
Documentation

Description

 special consideration for <change> element 
Namespace No namespace
Match change
Mode #default
Import precedence 0
Source
<xsl:template match="change">
  <change>
    <xsl:apply-templates select="item/@*"/>
    <xsl:apply-templates select="date"/>
    <xsl:if test="respStmt/resp">
      <label>
        <xsl:value-of select="respStmt/resp/text()"/>
      </label>
    </xsl:if>
    <xsl:for-each select="respStmt/name">
      <name>
        <xsl:apply-templates select="@*|*|comment()|processing-instruction()|text()"/>
      </name>
    </xsl:for-each>
    <xsl:for-each select="item">
      <xsl:apply-templates select="*|comment()|processing-instruction()|text()"/>
    </xsl:for-each>
  </change>
</xsl:template>
Stylesheet location from.xsl
Template respStmt[resp]
Namespace No namespace
Match respStmt[resp]
Mode #default
Import precedence 0
Source
<xsl:template match="respStmt[resp]">
  <respStmt>
    <xsl:choose>
      <xsl:when test="resp/name">
        <resp>
          <xsl:value-of select="resp/text()"/>
        </resp>
        <xsl:for-each select="resp/name">
          <name>
            <xsl:apply-templates/>
          </name>
        </xsl:for-each>
      </xsl:when>
      <xsl:otherwise>
        <xsl:apply-templates/>
        <name>
        </name>
      </xsl:otherwise>
    </xsl:choose>
  </respStmt>
</xsl:template>
Stylesheet location from.xsl
Template q/@direct
Namespace No namespace
Match q/@direct
Mode #default
Import precedence 0
Source
<xsl:template match="q/@direct"/>
Stylesheet location from.xsl
Template q
Namespace No namespace
Match q
Mode #default
Import precedence 0
Source
<xsl:template match="q">
  <q>
    <xsl:apply-templates select="@*|*|comment()|processing-instruction()|text()"/>
  </q>
</xsl:template>
Stylesheet location from.xsl
Template @targOrder
Documentation

Description

 if we are reading the P4 with a DTD,
       we need to avoid copying the default values
       of attributes 
Namespace No namespace
Match @targOrder
Mode #default
Import precedence 0
Source
<xsl:template match="@targOrder">
  <xsl:if test="not(lower-case(.) ='u')">
    <xsl:attribute name="targOrder">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @opt
Namespace No namespace
Match @opt
Mode #default
Import precedence 0
Source
<xsl:template match="@opt">
  <xsl:if test="not(lower-case(.) ='n')">
    <xsl:attribute name="opt">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @to
Namespace No namespace
Match @to
Mode #default
Import precedence 0
Source
<xsl:template match="@to">
  <xsl:if test="not(lower-case(.) ='ditto')">
    <xsl:attribute name="to">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template interp/@value
Namespace No namespace
Match interp/@value
Mode #default
Import precedence 0
Source
<xsl:template match="interp/@value">
  <xsl:attribute name="inst">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template @default
Namespace No namespace
Match @default
Mode #default
Import precedence 0
Source
<xsl:template match="@default">
  <xsl:choose>
    <xsl:when test="lower-case(.)= 'no'"/>
    <xsl:otherwise>
      <xsl:attribute name="default">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location from.xsl
Template @part
Namespace No namespace
Match @part
Mode #default
Import precedence 0
Source
<xsl:template match="@part">
  <xsl:if test="not(lower-case(.) ='n')">
    <xsl:attribute name="part">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @full
Namespace No namespace
Match @full
Mode #default
Import precedence 0
Source
<xsl:template match="@full">
  <xsl:if test="not(lower-case(.) ='yes')">
    <xsl:attribute name="full">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @from
Namespace No namespace
Match @from
Mode #default
Import precedence 0
Source
<xsl:template match="@from">
  <xsl:if test="not(lower-case(.) ='root')">
    <xsl:attribute name="from">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @status
Namespace No namespace
Match @status
Mode #default
Import precedence 0
Source
<xsl:template match="@status">
  <xsl:choose>
    <xsl:when test="parent::teiHeader">
      <xsl:if test="not(lower-case(.) ='new')">
        <xsl:attribute name="status">
          <xsl:value-of select="."/>
        </xsl:attribute>
      </xsl:if>
    </xsl:when>
    <xsl:when test="parent::del">
      <xsl:if test="not(lower-case(.) ='unremarkable')">
        <xsl:attribute name="status">
          <xsl:value-of select="."/>
        </xsl:attribute>
      </xsl:if>
    </xsl:when>
    <xsl:otherwise>
      <xsl:attribute name="status">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location from.xsl
Template @place
Namespace No namespace
Match @place
Mode #default
Import precedence 0
Source
<xsl:template match="@place">
  <xsl:if test="not(lower-case(.) ='unspecified')">
    <xsl:attribute name="place">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @sample
Namespace No namespace
Match @sample
Mode #default
Import precedence 0
Source
<xsl:template match="@sample">
  <xsl:if test="not(lower-case(.) ='complete')">
    <xsl:attribute name="sample">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @org
Namespace No namespace
Match @org
Mode #default
Import precedence 0
Source
<xsl:template match="@org">
  <xsl:if test="not(lower-case(.) ='uniform')">
    <xsl:attribute name="org">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @type
Namespace No namespace
Match @type
Mode #default
Import precedence 0
Source
<xsl:template match="@type">
  <xsl:if test="not(normalize-space(.)='')">
    <xsl:attribute name="type">
      <xsl:value-of select="translate(.,' ','_')"/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template teiHeader/@type
Namespace No namespace
Match teiHeader/@type
Mode #default
Import precedence 0
Source
<xsl:template match="teiHeader/@type">
  <xsl:if test="not(lower-case(.) ='text')">
    <xsl:attribute name="type">
      <xsl:value-of select="."/>
    </xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @anchored
Documentation

Description

 yes|no to boolean 
Namespace No namespace
Match @anchored
Mode #default
Import precedence 0
Source
<xsl:template match="@anchored">
  <xsl:attribute name="anchored">
    <xsl:choose>
      <xsl:when test="lower-case(.)='yes'">true</xsl:when>
      <xsl:when test="lower-case(.)='no'">false</xsl:when>
    </xsl:choose>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template sourceDesc/@default
Namespace No namespace
Match sourceDesc/@default
Mode #default
Import precedence 0
Source
<xsl:template match="sourceDesc/@default"/>
Stylesheet location from.xsl
Template @tei
Documentation

Description

 attributes suppressed in P5 
Namespace No namespace
Match @tei
Mode #default
Import precedence 0
Source
<xsl:template match="@tei"/>
Stylesheet location from.xsl
Template @langKey
Namespace No namespace
Match @langKey
Mode #default
Import precedence 0
Source
<xsl:template match="@langKey"/>
Stylesheet location from.xsl
Template @TEIform
Namespace No namespace
Match @TEIform
Mode #default
Import precedence 0
Source
<xsl:template match="@TEIform"/>
Stylesheet location from.xsl
Template gi/@TEI
Documentation

Description

 assorted atts 
Namespace No namespace
Match gi/@TEI
Mode #default
Import precedence 0
Source
<xsl:template match="gi/@TEI">
  <xsl:if test=".='yes'">
    <xsl:attribute name="scheme">TEI</xsl:attribute>
  </xsl:if>
</xsl:template>
Stylesheet location from.xsl
Template @old
Namespace No namespace
Match @old
Mode #default
Import precedence 0
Source
<xsl:template match="@old"/>
Stylesheet location from.xsl
Template ref/@from
Namespace No namespace
Match ref/@from
Mode #default
Import precedence 0
Source
<xsl:template match="ref/@from"/>
Stylesheet location from.xsl
Template @mergedin
Namespace No namespace
Match @mergedin
Mode #default
Import precedence 0
Source
<xsl:template match="@mergedin">
  <xsl:attribute name="mergedIn">
    <xsl:value-of select="."/>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template div0|div1|div2|div3|div4|div5|div6
Documentation

Description

 deal with the loss of div0 
Namespace No namespace
Match div0|div1|div2|div3|div4|div5|div6
Mode #default
Import precedence 0
Source
<xsl:template match="div0|div1|div2|div3|div4|div5|div6">
  <xsl:element name="div" namespace="http://www.tei-c.org/ns/1.0">
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </xsl:element>
</xsl:template>
Stylesheet location from.xsl
Template orig[@reg]
Documentation

Description

 from Conal Tuohy 
Namespace No namespace
Match orig[@reg]
Mode #default
Import precedence 0
Source
<xsl:template match="orig[@reg]">
  <choice>
    <orig>
      <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
    </orig>
    <reg>
      <xsl:value-of select="@reg"/>
    </reg>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template reg[@orig]
Namespace No namespace
Match reg[@orig]
Mode #default
Import precedence 0
Source
<xsl:template match="reg[@orig]">
  <choice>
    <reg>
      <xsl:apply-templates select="*|@*|processing-instruction()|     comment()|text()"/>
    </reg>
    <orig>
      <xsl:value-of select="@orig"/>
    </orig>
  </choice>
</xsl:template>
Stylesheet location from.xsl
Template @orig|@reg
Namespace No namespace
Match @orig|@reg
Mode #default
Import precedence 0
Source
<xsl:template match="@orig|@reg"/>
Stylesheet location from.xsl
Template row/@role[.='data']
Documentation

Description

 remove default values for attributes 
Namespace No namespace
Match row/@role[.='data']
Mode #default
Import precedence 0
Source
<xsl:template match="row/@role[.='data']"/>
Stylesheet location from.xsl
Template cell/@role[.='data']
Namespace No namespace
Match cell/@role[.='data']
Mode #default
Import precedence 0
Source
<xsl:template match="cell/@role[.='data']"/>
Stylesheet location from.xsl
Template cell/@rows[.='1']
Namespace No namespace
Match cell/@rows[.='1']
Mode #default
Import precedence 0
Source
<xsl:template match="cell/@rows[.='1']"/>
Stylesheet location from.xsl
Template cell/@cols[.='1']
Namespace No namespace
Match cell/@cols[.='1']
Mode #default
Import precedence 0
Source
<xsl:template match="cell/@cols[.='1']"/>
Stylesheet location from.xsl
Template q/@broken[.='no']
Namespace No namespace
Match q/@broken[.='no']
Mode #default
Import precedence 0
Source
<xsl:template match="q/@broken[.='no']"/>
Stylesheet location from.xsl
Template text[not(parent::TEI.2)]
Namespace No namespace
Match text[not(parent::TEI.2)]
Mode #default
Import precedence 0
Source
<xsl:template match="text[not(parent::TEI.2)]">
  <floatingText>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </floatingText>
</xsl:template>
Stylesheet location from.xsl
Template cesdoc
Documentation

Description

 from CES 
Namespace No namespace
Match cesdoc
Mode #default
Import precedence 0
Source
<xsl:template match="cesdoc">
  <cesDoc>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </cesDoc>
</xsl:template>
Stylesheet location from.xsl
Template lg1|lg2|lg3|lg4
Documentation

Description

 found in Perseus 
Namespace No namespace
Match lg1|lg2|lg3|lg4
Mode #default
Import precedence 0
Source
<xsl:template match="lg1|lg2|lg3|lg4">
  <lg>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </lg>
</xsl:template>
Stylesheet location from.xsl
Template spkr
Documentation

Description

 from OTA DTD 
Namespace No namespace
Match spkr
Mode #default
Import precedence 0
Source
<xsl:template match="spkr">
  <speaker>
    <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
  </speaker>
</xsl:template>
Stylesheet location from.xsl
Template letter
Namespace No namespace
Match letter
Mode #default
Import precedence 0
Source
<xsl:template match="letter">
  <floatingText type="letter">
    <body>
      <xsl:apply-templates select="*|@*|processing-instruction()|comment()|text()"/>
    </body>
  </floatingText>
</xsl:template>
Stylesheet location from.xsl
Template index
Documentation

Description

  and index 
Namespace No namespace
Match index
Mode #default
Import precedence 0
Source
<xsl:template match="index">
  <index indexName="level1">
    <xsl:value-of select="@level1"/>
    <xsl:if test="@level2">
      <index indexName="level2">
        <xsl:value-of select="@level2"/>
        <xsl:if test="@level3">
          <index indexName="level3">
            <xsl:value-of select="@level3"/>
          </index>
        </xsl:if>
      </index>
    </xsl:if>
  </index>
</xsl:template>
Stylesheet location from.xsl
Template foreName
Documentation

Description

 JC Additions 2013-06 
 foreName wasn't getting lower-cased. 
Namespace No namespace
Match foreName
Mode #default
Import precedence 0
Source
<xsl:template match="foreName">
  <forename><xsl:apply-templates select="@*|*|processing-instruction()|comment()|text()"/>
  </forename>
</xsl:template>
Stylesheet location from.xsl
Template event/@desc
Documentation

Description

 events can have @desc 
Namespace No namespace
Match event/@desc
Mode #default
Import precedence 0
Source
<xsl:template match="event/@desc"/>
Stylesheet location from.xsl
Template event
Namespace No namespace
Match event
Mode #default
Import precedence 0
Source
<xsl:template match="event">
  <incident>
    <xsl:apply-templates select="@*"/>
    <xsl:if test="@desc">
      <desc>
        <xsl:value-of select="@desc"/>
      </desc>
    </xsl:if>
  </incident>
</xsl:template>
Stylesheet location from.xsl
Template vocal/@desc
Documentation

Description

 and vocal can have desc as well 
Namespace No namespace
Match vocal/@desc
Mode #default
Import precedence 0
Source
<xsl:template match="vocal/@desc"/>
Stylesheet location from.xsl
Template vocal
Namespace No namespace
Match vocal
Mode #default
Import precedence 0
Source
<xsl:template match="vocal">
  <vocal>
    <xsl:apply-templates select="@*"/>
    <xsl:if test="@desc">
      <desc>
        <xsl:value-of select="@desc"/>
      </desc>
    </xsl:if>
  </vocal>
</xsl:template>
Stylesheet location from.xsl
Template birth/@date
Documentation

Description

 birth/@date wasn't being handled; because @date wasn't enforced as a date datatype
    I check if @date is indeed a date and if it is make it a @when and if not make it an @n
  
Namespace No namespace
Match birth/@date
Mode #default
Import precedence 0
Source
<xsl:template match="birth/@date">
  <xsl:choose>
    <xsl:when test="string(.) castable as xs:date">
      <xsl:attribute name="when">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:when>
    <xsl:otherwise>
      <xsl:attribute name="n">
        <xsl:value-of select="."/>
      </xsl:attribute>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location from.xsl
Template handList
Documentation

Description

 JC Additions 2013-11 
 handList and hand not catered for: they become handNotes and handNote 
Namespace No namespace
Match handList
Mode #default
Import precedence 0
Source
<xsl:template match="handList">
  <handNotes><xsl:apply-templates select="@*|*|processing-instruction()|comment()|text()"/>
  </handNotes>
</xsl:template>
Stylesheet location from.xsl
Template handList/hand
Documentation

Description

 hand inside handList 
Namespace No namespace
Match handList/hand
Mode #default
Import precedence 0
Source
<xsl:template match="handList/hand">
  <handNote>
    <xsl:apply-templates select="@*|*|processing-instruction()|comment()|text()"/>
    <xsl:if test="@scribe">
      <xsl:text>  Scribe: </xsl:text>
      <xsl:value-of select="@scribe"/>
    </xsl:if>
    <xsl:if test="@style">
      <xsl:text>  Style: </xsl:text>
      <xsl:value-of select="@style"/>
    </xsl:if>
    <xsl:if test="@character">
      <xsl:text>  Character: </xsl:text>
      <xsl:value-of select="@character"/>
    </xsl:if>
    <xsl:if test="@first">
      <xsl:text>  Main hand : </xsl:text>
      <xsl:value-of select="@first"/>
    </xsl:if>
    <xsl:if test="@mainLang">
      <xsl:text> Main language: </xsl:text>
      <xsl:value-of select="@mainLang"/>
    </xsl:if>
    <xsl:if test="@resp">
      <xsl:text>  Responsibility: </xsl:text>
      <xsl:value-of select="@resp"/>
    </xsl:if>
  </handNote>
</xsl:template>
Stylesheet location from.xsl
Template hand/@ink
Documentation

Description

 @ink on hand 
Namespace No namespace
Match hand/@ink
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@ink">
  <xsl:attribute name="medium">
    <xsl:value-of select="."/>
    <xsl:text>_ink</xsl:text>
  </xsl:attribute>
</xsl:template>
Stylesheet location from.xsl
Template hand/@scribe
Documentation

Description

 suppress other attributes  on hand 
Namespace No namespace
Match hand/@scribe
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@scribe"/>
Stylesheet location from.xsl
Template hand/@style
Namespace No namespace
Match hand/@style
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@style"/>
Stylesheet location from.xsl
Template hand/@character
Namespace No namespace
Match hand/@character
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@character"/>
Stylesheet location from.xsl
Template hand/@first
Namespace No namespace
Match hand/@first
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@first"/>
Stylesheet location from.xsl
Template hand/@mainLang
Namespace No namespace
Match hand/@mainLang
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@mainLang"/>
Stylesheet location from.xsl
Template hand/@resp
Namespace No namespace
Match hand/@resp
Mode #default
Import precedence 0
Source
<xsl:template match="hand/@resp"/>
Stylesheet location from.xsl
Variable processor
Namespace No namespace
Source
<xsl:variable name="processor">
  <xsl:value-of select="system-property('xsl:vendor')"/>
</xsl:variable>
Stylesheet location from.xsl
Variable today
Namespace No namespace
Source
<xsl:variable name="today">
  <xsl:value-of select="format-dateTime(current-dateTime(),'[Y]-[M02]-[D02]T[H02]:[m02]:[s02]Z')"/>
</xsl:variable>
Stylesheet location from.xsl
Output (default)
Documentation

Description

 
       
       P4 to P5 converter 
       
       Sebastian Rahtz <sebastian.rahtz@oucs.ox.ac.uk>
       
       $Date$  $Id$
       
  
Namespace No namespace
Output properties
method encoding cdata-section-elements omit-xml-declaration
xml utf-8 tei:eg yes
Source
<xsl:output method="xml" encoding="utf-8" cdata-section-elements="tei:eg" omit-xml-declaration="yes"/>
Stylesheet location from.xsl