Mode:

Compact lists

Showing:

Documentation
Parameters
Used by
References
Supersedes
Overriding
Imported modules
Imported from
Source
Stylesheet teitoodt.xsl
Documentation

Description

TEI stylesheet for making OpenOffice files from TEI XML. Originally derived from the OpenOffice /Docbook conversion, but largely rewritten

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 All rights reserved. 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

Id: $Id: teitoodt.xsl 11592 2013-02-05 22:49:31Z rahtz $

Copyright: 2008, TEI Consortium

Imported modules
Imported from
Stylesheet version 2.0
Template /
Namespace No namespace
Match /
Mode #default
References
Parameters
Template
Key
Import precedence 8
Source
<xsl:template match="/">
  <xsl:choose>
    <xsl:when test="$freestanding='true'">
      <xsl:result-document href="{concat($outputDir,'/meta.xml')}">
        <xsl:call-template name="META"/>
      </xsl:result-document>
      <office:document-content>
        <xsl:if test="$freestanding='true'">
          <xsl:for-each select="document(concat($outputDir,'/content.xml'))/office:document-content">
            <xsl:copy-of select="office:scripts"/>
            <xsl:copy-of select="office:font-face-decls"/>
            <xsl:copy-of select="office:automatic-styles"/>
          </xsl:for-each>
        </xsl:if>
        <office:body>
          <office:text>
            <xsl:apply-templates/>
          </office:text>
        </office:body>
      </office:document-content>
    </xsl:when>
    <xsl:otherwise>
      <office:document>
        <xsl:call-template name="META"/>
        <office:body>
          <office:text>
            <xsl:apply-templates/>
          </office:text>
        </office:body>
      </office:document>
    </xsl:otherwise>
  </xsl:choose>
  <xsl:result-document href="{concat($outputDir,'/META-INF/manifest.xml')}">
    <manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0">
      <manifest:file-entry manifest:media-type="application/vnd.oasis.opendocument.text" manifest:version="1.2" manifest:full-path="/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/statusbar/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/accelerator/current.xml"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/accelerator/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/floater/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/popupmenu/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/progressbar/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/menubar/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/toolbar/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/images/Bitmaps/"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Configurations2/images/"/>
      <manifest:file-entry manifest:media-type="application/vnd.sun.xml.ui.configuration" manifest:full-path="Configurations2/"/>
      <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="content.xml"/>
      <manifest:file-entry manifest:media-type="application/rdf+xml" manifest:full-path="manifest.rdf"/>
      <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="styles.xml"/>
      <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="meta.xml"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Thumbnails/thumbnail.png"/>
      <manifest:file-entry manifest:media-type="" manifest:full-path="Thumbnails/"/>
      <manifest:file-entry manifest:media-type="text/xml" manifest:full-path="settings.xml"/>
      <xsl:if test="count(key('GRAPHICS',1))>0">
        <manifest:file-entry manifest:media-type="" manifest:full-path="Pictures/"/>
        <xsl:for-each select="key('GRAPHICS',1)">
          <xsl:variable name="imagetype" select="tokenize(@url,'\.')[last()]"/>
          <manifest:file-entry>
            <xsl:attribute name="manifest:full-path">
              <xsl:text>Pictures/resource</xsl:text>
              <xsl:number level="any"/>
              <xsl:text>.</xsl:text>
              <xsl:value-of select="$imagetype"/>
            </xsl:attribute>
            <xsl:attribute name="manifest:media-type">
              <xsl:text>image/</xsl:text>
              <xsl:choose>
                <xsl:when test="$imagetype='png'">png</xsl:when>
                <xsl:when test="$imagetype='gif'">gif</xsl:when>
                <xsl:when test="$imagetype='jpg'">jpeg</xsl:when>
                <xsl:when test="$imagetype='jpeg'">jpg</xsl:when>
                <xsl:when test="$imagetype='tiff'">tiff</xsl:when>
                <xsl:when test="$imagetype='tif'">tiff</xsl:when>
                <xsl:otherwise>jpeg</xsl:otherwise>
              </xsl:choose>
            </xsl:attribute>
          </manifest:file-entry>
        </xsl:for-each>
      </xsl:if>
    </manifest:manifest>
  </xsl:result-document>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template META
Namespace No namespace
Used by
Template
References
Import precedence 8
Source
<xsl:template name="META">
  <xsl:for-each select="*">
    <office:meta>
      <meta:generator>TEI to OpenOffice XSLT</meta:generator>
      <dc:title>
        <xsl:sequence select="tei:generateTitle(.)"/>
      </dc:title>
      <dc:description/>
      <dc:subject/>
      <meta:creation-date>
        <xsl:sequence select="tei:generateDate(.)"/>
      </meta:creation-date>
      <dc:date>
        <xsl:sequence select="tei:generateRevDate(.)"/>
      </dc:date>
      <dc:language>
        <xsl:choose>
          <xsl:when test="/tei:TEI/@xml:lang">
            <xsl:value-of select="/tei:TEI/@xml:lang"/>
          </xsl:when>
          <xsl:otherwise>en</xsl:otherwise>
        </xsl:choose>
      </dc:language>
      <meta:editing-cycles>1</meta:editing-cycles>
      <meta:editing-duration>PT00H00M00S</meta:editing-duration>
      <meta:user-defined meta:name="Info 1"/>
      <meta:user-defined meta:name="Info 2"/>
      <meta:user-defined meta:name="Info 3"/>
      <meta:user-defined meta:name="Info 4"/>
      <meta:document-statistic meta:table-count="1" meta:image-count="0" meta:object-count="0" meta:page-count="1" meta:paragraph-count="42" meta:word-count="144" meta:character-count="820"/>
    </office:meta>
  </xsl:for-each>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:TEI
Documentation

Description

 base structure 
Namespace No namespace
Match tei:TEI
Mode #default
Import precedence 8
Source
<xsl:template match="tei:TEI">
  <xsl:apply-templates select="tei:text"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:body|tei:front|tei:back
Namespace No namespace
Match tei:body|tei:front|tei:back
Mode #default
Import precedence 8
Source
<xsl:template match="tei:body|tei:front|tei:back">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:head
Namespace No namespace
Match tei:head
Mode #default
Import precedence 8
Source
<xsl:template match="tei:head">
  <xsl:choose>
    <xsl:when test="parent::tei:figure"/>
    <xsl:when test="parent::tei:list"/>
    <xsl:when test="parent::tei:div"/>
    <xsl:when test="parent::tei:div1"/>
    <xsl:when test="parent::tei:div2"/>
    <xsl:when test="parent::tei:div3"/>
    <xsl:when test="parent::tei:div4"/>
    <xsl:when test="parent::tei:div5"/>
    <xsl:when test="parent::tei:div6"/>
    <xsl:when test="parent::tei:table"/>
    <xsl:otherwise>
      <xsl:choose>
        <xsl:when test="parent::tei:appendix">
          <text:p text:style-name="Appendix">
            <xsl:apply-templates/>
          </text:p>
        </xsl:when>
        <xsl:when test="parent::tei:body">
          <text:h text:outline-level="1">
            <xsl:apply-templates/>
          </text:h>
        </xsl:when>
        <xsl:otherwise>
          <text:p>
            <xsl:apply-templates/>
          </text:p>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:div
Namespace No namespace
Match tei:div
Mode #default
References
Template
Import precedence 8
Source
<xsl:template match="tei:div">
  <xsl:variable name="depth">
    <xsl:value-of select="count(ancestor::tei:div)"/>
  </xsl:variable>
  <text:h>
    <xsl:attribute name="text:outline-level">
      <xsl:value-of select="$depth + 1"/>
    </xsl:attribute>
    <xsl:call-template name="test.id"/>
    <xsl:apply-templates select="tei:head" mode="show"/>
  </text:h>
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6
Namespace No namespace
Match tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6
Mode #default
References
Template
Import precedence 8
Source
<xsl:template match="tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6">
  <xsl:variable name="depth">
    <xsl:value-of select="substring-after(name(.),'div')"/>
  </xsl:variable>
  <text:h>
    <xsl:attribute name="text:outline-level">
      <xsl:value-of select="$depth + 1"/>
    </xsl:attribute>
    <xsl:call-template name="test.id"/>
    <xsl:apply-templates select="tei:head" mode="show"/>
  </text:h>
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:pb
Documentation

Description

 paragraphs 
Namespace No namespace
Match tei:pb
Mode #default
Import precedence 8
Source
<xsl:template match="tei:pb">
  <text:soft-page-break/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:p
Namespace No namespace
Match tei:p
Mode #default
References
Function
Template
Import precedence 8
Source
<xsl:template match="tei:p">
  <xsl:variable name="style">
    <xsl:choose>
      <xsl:when test="ancestor::tei:note[@place='foot']">
        <xsl:text>Footnote</xsl:text>
      </xsl:when>
      <xsl:otherwise>
        <xsl:text>Text_20_body</xsl:text>
      </xsl:otherwise>
    </xsl:choose>
  </xsl:variable>
  <xsl:for-each-group select="node()" group-adjacent="if        (self::text())        then 1        else if        (tei:is-inline(.))        then 1        else 2        ">
    <xsl:choose>
      <xsl:when test="current-grouping-key()=2">
        <xsl:apply-templates select="current-group()"/>
      </xsl:when>
      <xsl:otherwise>
        <text:p text:style-name="{$style}">
          <xsl:call-template name="test.id"/>
          <xsl:apply-templates select="current-group()"/>
        </text:p>
      </xsl:otherwise>
    </xsl:choose>
  </xsl:for-each-group>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:figure
Documentation

Description

 figures 
Namespace No namespace
Match tei:figure
Mode #default
References
Template
Import precedence 8
Source
<xsl:template match="tei:figure">
  <text:p text:style-name="Standard">
    <xsl:call-template name="test.id"/>
    <xsl:apply-templates select="tei:graphic"/>
  </text:p>
  <xsl:if test="tei:head">
    <text:p text:style-name="Caption">
      <text:span text:style-name="Figurenum">
        <xsl:text>Figure </xsl:text>
        <text:sequence text:ref-name="refFigure0" text:name="Figure" text:formula="Figure+1" style:num-format="1">
          <xsl:number level="any"/>
          <xsl:text>.</xsl:text>
        </text:sequence>
      </text:span>
      <xsl:text> </xsl:text>
      <xsl:apply-templates select="tei:head" mode="show"/>
    </text:p>
  </xsl:if>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:graphic
Namespace No namespace
Match tei:graphic
Mode #default
References
Parameters
Keys
H;
Function
Import precedence 8
Source
<xsl:template match="tei:graphic">
  <xsl:variable name="id">
    <xsl:choose>
      <xsl:when test="@xml:id">
        <xsl:value-of select="@xml:id"/>
      </xsl:when>
      <xsl:otherwise>
        <xsl:text>Figure</xsl:text>
        <xsl:number level="any"/>
      </xsl:otherwise>
    </xsl:choose>
  </xsl:variable>
  <xsl:variable name="filename">
    <xsl:text>Pictures/resource</xsl:text>
    <xsl:number level="any"/>
    <xsl:text>.</xsl:text>
    <xsl:value-of select="tokenize(@url,'\.')[last()]"/>
  </xsl:variable>
  <xsl:variable name="origheight">
    <xsl:choose>
      <xsl:when test="@teidocx:height">
        <xsl:value-of select="@teidocx:height"/>
      </xsl:when>
      <xsl:when test="doc-available(concat($outputDir,'/image-size-info.xml'))">
        <xsl:for-each select="document(concat($outputDir,'/image-size-info.xml'))">
          <xsl:value-of select="(number(key('H',$filename)/height) div 72) * 9144"/>
        </xsl:for-each>
      </xsl:when>
      <xsl:otherwise>0</xsl:otherwise>
    </xsl:choose>
  </xsl:variable>
  <xsl:variable name="origwidth">
    <xsl:choose>
      <xsl:when test="@teidocx:width">
        <xsl:value-of select="@teidocx:width"/>
      </xsl:when>
      <xsl:when test="doc-available(concat($outputDir,'/image-size-info.xml'))">
        <xsl:for-each select="document(concat($outputDir,'/image-size-info.xml'))">
          <xsl:value-of select="(number(key('W',$filename)/width) div 72) * 9144"/>
        </xsl:for-each>
      </xsl:when>
      <xsl:otherwise>0</xsl:otherwise>
    </xsl:choose>
  </xsl:variable>
  <xsl:choose>
    <xsl:when test="$filename and  ( ($origwidth and $origheight) or (@width and @height))">
      <!-- work out page width / height and subtract 1inch on all sides -->
      <xsl:variable name="pageWidth">
        <xsl:for-each select="document(concat($outputDir,'/styles.xml'))/office:document-styles/office:automatic-styles/style:page-layout[1]/style:page-layout-properties">
          <xsl:value-of select="number(tei:convert-dim-pt(@fo:page-width) - 144)"/>
        </xsl:for-each>
      </xsl:variable>
      <xsl:variable name="pageHeight">
        <xsl:for-each select="document(concat($outputDir,'/styles.xml'))/office:document-styles/office:automatic-styles/style:page-layout[1]/style:page-layout-properties">
          <xsl:value-of select="number(tei:convert-dim-pt(@fo:page-height) - 144)"/>
        </xsl:for-each>
      </xsl:variable>
      <xsl:variable name="Width">
        <xsl:choose>
          <xsl:when test="contains(@width,'%')">
            <xsl:value-of select="(($pageWidth div 100) * number(substring-before(@width,'%'))) cast as xs:integer"/>
          </xsl:when>
          <xsl:when test="@width">
            <xsl:value-of select="tei:convert-dim-pt(@width)"/>
          </xsl:when>
          <xsl:when test="@scale and $origwidth">
            <xsl:value-of select="number($origwidth * number(@scale)) div 127 cast as xs:integer"/>
          </xsl:when>
          <xsl:when test="@height[not(contains(.,'%'))] and $origheight">
            <xsl:variable name="h">
              <xsl:value-of select="number(tei:convert-dim-pt(@height))"/>
            </xsl:variable>
            <xsl:value-of select="($h * number($origwidth)) div number($origheight)"/>
          </xsl:when>
          <xsl:when test="$origwidth">
            <xsl:value-of select="number($origwidth) div 127"/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:message terminate="yes">no way to work out image width for
              <xsl:value-of select="$filename"/>
            </xsl:message>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:variable>
      <xsl:variable name="Height">
        <xsl:choose>
          <xsl:when test="contains(@height,'%')">
            <xsl:value-of select="(($pageHeight div 100) * (number(substring-before(@height,'%')))) cast as xs:integer"/>
          </xsl:when>
          <xsl:when test="@height">
            <xsl:value-of select="tei:convert-dim-pt(@height)"/>
          </xsl:when>
          <xsl:when test="@scale and $origheight">
            <xsl:value-of select="($origheight *         number(@scale)) div 127 cast as xs:integer"/>
          </xsl:when>
          <xsl:when test="@width[contains(.,'%')]">
            <xsl:value-of select="number($pageHeight * (number(substring-before(@width,'%')))) cast as xs:integer"/>
          </xsl:when>
          <xsl:when test="@width[not(contains(.,'%'))] and $origheight and $origwidth">
            <xsl:variable name="w">
              <xsl:value-of select="number(tei:convert-dim-pt(@width))"/>
            </xsl:variable>
            <xsl:value-of select="($w * number($origheight)) div number($origwidth)"/>
          </xsl:when>
          <xsl:when test="$origheight">
            <xsl:value-of select="number($origheight) div 127"/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:message terminate="yes">no way to work out image height for
              <xsl:value-of select="$filename"/>
            </xsl:message>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:variable>
      <!-- check for sense -->
      <xsl:variable name="imageHeight">
        <xsl:choose>
          <xsl:when test="$Height < 0">
            <xsl:value-of select="$pageHeight"/>
          </xsl:when>
          <xsl:when test="number($Height) > $pageHeight">
            <xsl:value-of select="$pageHeight"/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:value-of select="$Height"/>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:variable>
      <xsl:variable name="imageWidth">
        <xsl:choose>
          <xsl:when test="$Width < 0">
            <xsl:value-of select="$pageWidth"/>
          </xsl:when>
          <xsl:when test="number($Width) > $pageWidth">
            <xsl:value-of select="$pageWidth"/>
          </xsl:when>
          <xsl:otherwise>
            <xsl:value-of select="$Width"/>
          </xsl:otherwise>
        </xsl:choose>
      </xsl:variable>
      <xsl:if test="$debug='true'">
        <xsl:message>
          <xsl:for-each select="@*">- @
            <xsl:value-of select="name(.)"/>:
            <xsl:value-of select="."/>
          </xsl:for-each>- pageWidth:
          <xsl:value-of select="$pageWidth"/>- pageHeight:
          <xsl:value-of select="$pageHeight"/>- Width:
          <xsl:value-of select="$Width"/>- Height:
          <xsl:value-of select="$Height"/>- imageWidth:
          <xsl:value-of select="$imageWidth"/>- imageHeight:
          <xsl:value-of select="$imageHeight"/>
        </xsl:message>
      </xsl:if>
      <draw:frame draw:style-name="fr1" draw:name="{$id}" draw:z-index="0">
        <xsl:attribute name="text:anchor-type">
          <xsl:choose>
            <xsl:when test="parent::tei:figure">
              <xsl:text>paragraph</xsl:text>
            </xsl:when>
            <xsl:otherwise>
              <xsl:text>as-char</xsl:text>
            </xsl:otherwise>
          </xsl:choose>
        </xsl:attribute>
        <xsl:attribute name="svg:width">
          <xsl:value-of select="$imageWidth"/>
          <xsl:text>pt</xsl:text>
        </xsl:attribute>
        <xsl:attribute name="svg:height">
          <xsl:value-of select="$imageHeight"/>
          <xsl:text>pt</xsl:text>
        </xsl:attribute>
        <draw:image xlink:href="{$filename}" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad" draw:filter-name="<All formats>"/>
      </draw:frame>
    </xsl:when>
    <xsl:otherwise>
      <xsl:message terminate="yes">ERROR. no image size info for
        <xsl:value-of select="$filename"/>, cannot proceed</xsl:message>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:list|tei:listBibl
Documentation

Description

 lists 
Namespace No namespace
Match tei:list|tei:listBibl
Mode #default
Import precedence 8
Source
<xsl:template match="tei:list|tei:listBibl">
  <xsl:if test="tei:head">
    <text:p>
      <xsl:attribute name="text:style-name">
        <xsl:choose>
          <xsl:when test="@type='ordered'">P2</xsl:when>
          <xsl:otherwise>P1</xsl:otherwise>
        </xsl:choose>
      </xsl:attribute>
      <xsl:apply-templates select="tei:head" mode="show"/>
    </text:p>
  </xsl:if>
  <text:list>
    <xsl:attribute name="text:style-name">
      <xsl:choose>
        <xsl:when test="self::tei:listBibl">L2</xsl:when>
        <xsl:when test="not(@type)">L1</xsl:when>
        <xsl:when test="@type='ordered'">L2</xsl:when>
        <xsl:when test="@type='unordered'">L1</xsl:when>
      </xsl:choose>
    </xsl:attribute>
    <xsl:apply-templates/>
  </text:list>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:list[@type='gloss' or @rend='valList']
Namespace No namespace
Match tei:list[@type='gloss' or @rend='valList']
Mode #default
Import precedence 8
Priority 10
Source
<xsl:template match="tei:list[@type='gloss' or @rend='valList']" priority="10">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:list[@type='gloss' or @rend='valList']/tei:item
Namespace No namespace
Match tei:list[@type='gloss' or @rend='valList']/tei:item
Mode #default
Import precedence 8
Source
<xsl:template match="tei:list[@type='gloss' or @rend='valList']/tei:item">
  <text:p text:style-name="List_20_Contents">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:list[@type='gloss' or @rend='valList']/tei:label
Namespace No namespace
Match tei:list[@type='gloss' or @rend='valList']/tei:label
Mode #default
Import precedence 8
Source
<xsl:template match="tei:list[@type='gloss' or @rend='valList']/tei:label">
  <text:p text:style-name="List_20_Heading">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:item/tei:p
Namespace No namespace
Match tei:item/tei:p
Mode #default
Import precedence 8
Source
<xsl:template match="tei:item/tei:p">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:item
Namespace No namespace
Match tei:item
Mode #default
Import precedence 8
Source
<xsl:template match="tei:item">
  <text:list-item>
    <xsl:choose>
      <xsl:when test="tei:list">
        <xsl:apply-templates/>
      </xsl:when>
      <xsl:otherwise>
        <text:p>
          <xsl:attribute name="text:style-name">
            <xsl:choose>
              <xsl:when test="parent::tei:list/@type='ordered'">P2</xsl:when>
              <xsl:otherwise>P1</xsl:otherwise>
            </xsl:choose>
          </xsl:attribute>
          <xsl:apply-templates/>
        </text:p>
      </xsl:otherwise>
    </xsl:choose>
  </text:list-item>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template displayNote
Namespace No namespace
Used by
Template
Supersedes
Template
Import precedence 8
Source
<xsl:template name="displayNote">
  <text:p text:style-name="tei_displayNote">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:emph
Documentation

Description

 inline stuff 
Namespace No namespace
Match tei:emph
Mode #default
Import precedence 8
Source
<xsl:template match="tei:emph">
  <text:span text:style-name="Emphasis">
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:gi
Namespace No namespace
Match tei:gi
Mode #default
Import precedence 8
Source
<xsl:template match="tei:gi">
  <xsl:text><</xsl:text>
  <xsl:apply-templates/>
  <xsl:text>></xsl:text>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:caesura
Namespace No namespace
Match tei:caesura
Mode #default
Import precedence 8
Source
<xsl:template match="tei:caesura">
  <xsl:text>   </xsl:text>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:q[not(tei:l)]
Namespace No namespace
Match tei:q[not(tei:l)]
Mode #default
Import precedence 8
Source
<xsl:template match="tei:q[not(tei:l)]">
  <text:span text:style-name="q">
    <xsl:text></xsl:text>
    <xsl:apply-templates/>
    <xsl:text></xsl:text>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template plainNote
Namespace No namespace
Used by
References
Function
Supersedes
Template
Import precedence 8
Source
<xsl:template name="plainNote">
  <text:span text:style-name="tei_inlineNote">
    <xsl:text> [</xsl:text>
    <xsl:choose>
      <xsl:when test="@n">
        <xsl:value-of select="@n"/>
      </xsl:when>
      <xsl:otherwise>
        <xsl:sequence select="tei:i18n('Note')"/>
        <xsl:text>: </xsl:text>
      </xsl:otherwise>
    </xsl:choose>
    <xsl:apply-templates/>
    <xsl:text>] </xsl:text>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template footNote
Namespace No namespace
Used by
Template
Supersedes
Template
Import precedence 8
Source
<xsl:template name="footNote">
  <text:note text:note-class="footnote">
    <text:note-citation>
      <xsl:number level="any" count="tei:note[@place='foot']"/>
    </text:note-citation>
    <text:note-body>
      <text:p text:style-name="Footnote">
        <xsl:apply-templates/>
      </text:p>
    </text:note-body>
  </text:note>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template endNote
Namespace No namespace
Used by
Template
Supersedes
Template
Import precedence 8
Source
<xsl:template name="endNote">
  <text:note text:note-class="endnote">
    <text:note-citation>
      <xsl:number format="i" level="any" count="tei:note[@place='end']"/>
    </text:note-citation>
    <text:note-body>
      <text:p text:style-name="Endnote">
        <xsl:apply-templates/>
      </text:p>
    </text:note-body>
  </text:note>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:table|tei:figure|tei:itemcrossref
Namespace No namespace
Match tei:table|tei:figure|tei:item
Mode crossref
Import precedence 8
Source
<xsl:template match="tei:table|tei:figure|tei:item" mode="crossref">
  <xsl:number level="any"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:divcrossref
Namespace No namespace
Match tei:div
Mode crossref
Import precedence 8
Source
<xsl:template match="tei:div" mode="crossref">
  <xsl:number format="1.1.1.1.1" level="multiple" count="tei:div"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6crossref
Namespace No namespace
Match tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6
Mode crossref
Import precedence 8
Source
<xsl:template match="tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6" mode="crossref">
  <xsl:number format="1.1.1.1.1" count="tei:div1|tei:div2|tei:div3|tei:div4|tei:div5|tei:div6" level="multiple"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template test.id
Namespace No namespace
Used by
Import precedence 8
Source
<xsl:template name="test.id">
  <xsl:if test="@xml:id">
    <text:bookmark text:name="{@xml:id}"/>
  </xsl:if>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:unclear
Namespace No namespace
Match tei:unclear
Mode #default
Supersedes
Template
Import precedence 8
Source
<xsl:template match="tei:unclear">
  <text:span text:style-name="Highlight">
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:hi
Namespace No namespace
Match tei:hi
Mode #default
Import precedence 8
Source
<xsl:template match="tei:hi">
  <text:span>
    <xsl:attribute name="text:style-name">
      <xsl:choose>
        <xsl:when test="@rend='normalweight'">
          <xsl:text>Standard</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='code' or @rend='typewriter'">
          <xsl:text>Source_20_Text</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='sup' or @rend='superscript'">
          <xsl:text>Superscript</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='sub' or @rend='subscript'">
          <xsl:text>Subscript</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='bold'">
          <xsl:text>Highlight</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='label'">
          <xsl:text>Highlight</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='it' or @rend='i' or @rend='italic'">
          <xsl:text>Emphasis</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='underline'">
          <xsl:text>Underline</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='sc' or @rend='smallcaps'">
          <xsl:text>SmallCaps</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='sc' or @rend='capsall'">
          <xsl:text>AllCaps</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='strikethrough'">
          <xsl:text>StrikeThrough</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='strikedoublethrough'">
          <xsl:text>StrikeDoubleThrough</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='underline'">
          <xsl:text>UnderLine</xsl:text>
        </xsl:when>
        <xsl:when test="@rend='underdoubleline'">
          <xsl:text>UnderDoubleLine</xsl:text>
        </xsl:when>
        <xsl:otherwise>
          <xsl:text>Emphasis</xsl:text>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:attribute>
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:term
Namespace No namespace
Match tei:term
Mode #default
Import precedence 8
Source
<xsl:template match="tei:term">
  <text:span>
    <xsl:attribute name="text:style-name">
      <xsl:text>Highlight</xsl:text>
    </xsl:attribute>
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:index
Namespace No namespace
Match tei:index
Mode #default
Import precedence 8
Source
<xsl:template match="tei:index"/>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:eg
Namespace No namespace
Match tei:eg
Mode #default
References
Template
Import precedence 8
Source
<xsl:template match="tei:eg">
  <xsl:call-template name="Literal">
    <xsl:with-param name="Text">
      <xsl:value-of select="."/>
    </xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template teix:egXML
Namespace No namespace
Match teix:egXML
Mode #default
References
Template
Import precedence 8
Source
<xsl:template match="teix:egXML">
  <xsl:call-template name="Literal">
    <xsl:with-param name="Text">
      <xsl:apply-templates mode="verbatim"/>
    </xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template comment()
Documentation

Description

 safest to drop comments entirely, I think 
Namespace No namespace
Match comment()
Mode #default
Import precedence 8
Source
<xsl:template match="comment()"/>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:headshow
Namespace No namespace
Match tei:head
Mode show
Import precedence 8
Source
<xsl:template match="tei:head" mode="show">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:lb
Namespace No namespace
Match tei:lb
Mode #default
References
Import precedence 8
Source
<xsl:template match="tei:lb">
  <xsl:choose>
    <xsl:when test="not(tei:is-inline(..)) and (tei:is-last(.) or tei:is-first(.))"/>
    <xsl:otherwise>
      <text:line-break/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:biblStruct
Namespace No namespace
Match tei:biblStruct
Mode #default
Import precedence 8
Source
<xsl:template match="tei:biblStruct">
  <text:list-item>
    <text:p text:style-name="P2">
      <xsl:apply-templates/>
    </text:p>
  </text:list-item>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:bibl|tei:signed|tei:byline
Namespace No namespace
Match tei:bibl|tei:signed|tei:byline
Mode #default
Import precedence 8
Source
<xsl:template match="tei:bibl|tei:signed|tei:byline">
  <text:p text:style-name="tei_{local-name(.)}">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:lg
Namespace No namespace
Match tei:lg
Mode #default
Import precedence 8
Source
<xsl:template match="tei:lg">
  <text:p text:style-name="lg">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:l
Namespace No namespace
Match tei:l
Mode #default
Import precedence 8
Source
<xsl:template match="tei:l">
  <xsl:choose>
    <xsl:when test="parent::tei:lg">
      <xsl:apply-templates/>
      <text:line-break/>
    </xsl:when>
    <xsl:otherwise>
      <text:p text:style-name="lg">
        <xsl:apply-templates/>
      </text:p>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template Literal
Namespace No namespace
Used by
Templates
References
Template
Parameters
QName Namespace
Text No namespace
Import precedence 8
Source
<xsl:template name="Literal">
  <xsl:param name="Text"/>
  <xsl:choose>
    <xsl:when test="contains($Text,'
')">
      <text:p text:style-name="Preformatted_20_Text">
        <xsl:value-of select="translate(substring-before($Text,'
'),' ',' ')"/>
      </text:p>
      <xsl:call-template name="Literal">
        <xsl:with-param name="Text">
          <xsl:value-of select="substring-after($Text,'
')"/>
        </xsl:with-param>
      </xsl:call-template>
    </xsl:when>
    <xsl:otherwise>
      <text:p text:style-name="Preformatted_20_Text">
        <xsl:value-of select="translate($Text,' ',' ')"/>
      </text:p>
    </xsl:otherwise>
  </xsl:choose>
  <!-- text:s c="6" to ident 6 spaces -->
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:sp
Namespace No namespace
Match tei:sp
Mode #default
Import precedence 8
Source
<xsl:template match="tei:sp">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:stage
Namespace No namespace
Match tei:stage
Mode #default
Import precedence 8
Source
<xsl:template match="tei:stage">
  <xsl:choose>
    <xsl:when test="parent::tei:sp or parent::tei:div">
      <text:p text:style-name="Stage">
        <xsl:apply-templates/>
      </text:p>
    </xsl:when>
    <xsl:otherwise>
      <text:span text:style-name="Stage">
        <xsl:apply-templates/>
      </text:span>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:speaker
Namespace No namespace
Match tei:speaker
Mode #default
Import precedence 8
Source
<xsl:template match="tei:speaker">
  <text:p text:style-name="Speaker">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:quote
Namespace No namespace
Match tei:quote
Mode #default
Import precedence 8
Source
<xsl:template match="tei:quote">
  <text:p text:style-name="Quote">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:ab
Namespace No namespace
Match tei:ab
Mode #default
Import precedence 8
Source
<xsl:template match="tei:ab">
  <text:p>
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:table
Documentation

Description

 tables
Namespace No namespace
Match tei:table
Mode #default
Import precedence 8
Source
<xsl:template match="tei:table">
  <xsl:variable name="tablenum">
    <xsl:choose>
      <xsl:when test="@xml:id">
        <xsl:value-of select="@xml:id"/>
      </xsl:when>
      <xsl:otherwise>table
        <xsl:number level="any"/>
      </xsl:otherwise>
    </xsl:choose>
  </xsl:variable>
  <table:table table:name="{$tablenum}" table:style-name="Table1">
    <xsl:for-each select="1 to max(for $i in tei:row return count($i/tei:cell))">
      <table:table-column table:style-name="Table{.}.col{.}">
      </table:table-column>
    </xsl:for-each>
    <xsl:apply-templates/>
  </table:table>
  <xsl:if test="tei:head">
    <text:p text:style-name="Caption">
      <xsl:apply-templates select="tei:head" mode="show"/>
    </text:p>
  </xsl:if>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:row[@role='label']
Namespace No namespace
Match tei:row[@role='label']
Mode #default
Import precedence 8
Source
<xsl:template match="tei:row[@role='label']">
  <table:table-header-rows>
    <table:table-row>
      <xsl:apply-templates/>
    </table:table-row>
  </table:table-header-rows>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:row
Namespace No namespace
Match tei:row
Mode #default
Import precedence 8
Source
<xsl:template match="tei:row">
  <table:table-row>
    <xsl:apply-templates/>
  </table:table-row>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:seg
Namespace No namespace
Match tei:seg
Mode #default
Import precedence 8
Source
<xsl:template match="tei:seg">
  <text:span>
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:seg[@rend='parent']
Namespace No namespace
Match tei:seg[@rend='parent']
Mode #default
Import precedence 8
Source
<xsl:template match="tei:seg[@rend='parent']">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:ident
Namespace No namespace
Match tei:ident
Mode #default
Import precedence 8
Source
<xsl:template match="tei:ident">
  <text:span>
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:cit[@rend='display' or not(@rend)]
Namespace No namespace
Match tei:cit[@rend='display' or not(@rend)]
Mode #default
Import precedence 8
Source
<xsl:template match="tei:cit[@rend='display' or not(@rend)]">
  <text:p text:style-name="tei_cit">
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:mentioned
Namespace No namespace
Match tei:mentioned
Mode #default
Import precedence 8
Source
<xsl:template match="tei:mentioned">
  <text:span text:style-name="Emphasis">
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:code
Namespace No namespace
Match tei:code
Mode #default
Import precedence 8
Source
<xsl:template match="tei:code">
  <text:span text:style-name="User_20_Entry">
    <xsl:apply-templates/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:cell
Namespace No namespace
Match tei:cell
Mode #default
Import precedence 8
Source
<xsl:template match="tei:cell">
  <table:table-cell>
    <xsl:if test="@cols">
      <xsl:attribute name="table:number-columns-spanned" select="@cols"/>
    </xsl:if>
    <xsl:if test="@rows">
      <xsl:attribute name="table:number-rows-spanned" select="@rows"/>
    </xsl:if>
    <xsl:variable name="cellContents">
      <xsl:apply-templates/>
    </xsl:variable>
    <xsl:for-each-group select="$cellContents/node()" group-adjacent="if (self::draw:frame or        self::text:note or self::text:span or self::text() or self::text:a)        then 1        else 2">
      <xsl:choose>
        <xsl:when test="current-grouping-key()=1">
          <text:p>
            <xsl:copy-of select="current-group()"/>
          </text:p>
        </xsl:when>
        <xsl:otherwise>
          <xsl:copy-of select="current-group()"/>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:for-each-group>
  </table:table-cell>
  <xsl:if test="@cols">
    <xsl:for-each select="2 to @cols">
      <table:covered-table-cell/>
    </xsl:for-each>
  </xsl:if>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template newLine
Namespace No namespace
Used by
Template
Import precedence 8
Source
<xsl:template name="newLine">
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template lineBreak
Namespace No namespace
Used by
Parameters
QName Namespace
id No namespace
Import precedence 8
Source
<xsl:template name="lineBreak">
  <xsl:param name="id"/>
  <xsl:text>
</xsl:text>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template comment()verbatim
Namespace No namespace
Match comment()
Mode verbatim
References
Template
Parameters
Import precedence 8
Source
<xsl:template match="comment()" mode="verbatim">
  <xsl:choose>
    <xsl:when test="ancestor::Wrapper"/>
    <xsl:when test="ancestor::xhtml:Wrapper"/>
    <xsl:otherwise>
      <xsl:call-template name="lineBreak">
        <xsl:with-param name="id">21</xsl:with-param>
      </xsl:call-template>
      <xsl:value-of disable-output-escaping="yes" select="$startComment"/>
      <xsl:text><!--</xsl:text>
      <xsl:value-of select="."/>
      <xsl:text>--></xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endComment"/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template text()verbatim
Namespace No namespace
Match text()
Mode verbatim
References
Import precedence 8
Source
<xsl:template match="text()" mode="verbatim">
  <xsl:choose>
    <xsl:when test="not(preceding-sibling::node() or contains(.,'
'))">
      <xsl:call-template name="Text">
        <xsl:with-param name="words">
          <xsl:value-of select="."/>
        </xsl:with-param>
      </xsl:call-template>
      <!--	
        <xsl:if test="substring(.,string-length(.))=' '">
	  <xsl:text> </xsl:text>
	</xsl:if>
-->
    </xsl:when>
    <xsl:when test="normalize-space(.)=''">
      <xsl:for-each select="following-sibling::*[1]">
        <xsl:call-template name="lineBreak">
          <xsl:with-param name="id">7</xsl:with-param>
        </xsl:call-template>
        <xsl:call-template name="makeIndent"/>
      </xsl:for-each>
    </xsl:when>
    <xsl:otherwise>
      <!--
	<xsl:if test="starts-with(.,' ')">
	  <xsl:text> </xsl:text>
	</xsl:if>
-->
      <xsl:call-template name="wraptext">
        <xsl:with-param name="count">0</xsl:with-param>
        <xsl:with-param name="indent">
          <xsl:for-each select="parent::*">
            <xsl:call-template name="makeIndent"/>
          </xsl:for-each>
        </xsl:with-param>
        <xsl:with-param name="text">
          <xsl:choose>
            <xsl:when test="starts-with(.,'
') and not          (preceding-sibling::node())">
              <xsl:call-template name="Text">
                <xsl:with-param name="words">
                  <xsl:value-of select="substring(.,2)"/>
                </xsl:with-param>
              </xsl:call-template>
            </xsl:when>
            <xsl:otherwise>
              <xsl:call-template name="Text">
                <xsl:with-param name="words">
                  <xsl:value-of select="."/>
                </xsl:with-param>
              </xsl:call-template>
            </xsl:otherwise>
          </xsl:choose>
        </xsl:with-param>
      </xsl:call-template>
      <!--
	<xsl:if test="substring(.,string-length(.))=' '">
	  <xsl:text> </xsl:text>
	</xsl:if>
	-->
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template wraptext
Namespace No namespace
Used by
References
Templates
Parameters
QName Namespace
count No namespace
indent No namespace
text No namespace
Import precedence 8
Source
<xsl:template name="wraptext">
  <xsl:param name="indent"/>
  <xsl:param name="text"/>
  <xsl:param name="count">0</xsl:param>
  <xsl:choose>
    <xsl:when test="normalize-space($text)=''"/>
    <xsl:when test="contains($text,'
')">
      <xsl:if test="$count > 0">
        <xsl:value-of select="$indent"/>
        <xsl:text> </xsl:text>
      </xsl:if>
      <xsl:call-template name="Text">
        <xsl:with-param name="words">
          <xsl:value-of select="substring-before($text,'
')"/>
        </xsl:with-param>
      </xsl:call-template>
      <!--	<xsl:if test="not(substring-after($text,'&#10;')='')">-->
      <xsl:call-template name="lineBreak">
        <xsl:with-param name="id">6</xsl:with-param>
      </xsl:call-template>
      <xsl:value-of select="$indent"/>
      <xsl:call-template name="wraptext">
        <xsl:with-param name="indent">
          <xsl:value-of select="$indent"/>
        </xsl:with-param>
        <xsl:with-param name="text">
          <xsl:value-of select="substring-after($text,'
')"/>
        </xsl:with-param>
        <xsl:with-param name="count">
          <xsl:value-of select="$count + 1"/>
        </xsl:with-param>
      </xsl:call-template>
    </xsl:when>
    <xsl:otherwise>
      <xsl:if test="$count > 0 and parent::*">
        <xsl:value-of select="$indent"/>
        <xsl:text> </xsl:text>
      </xsl:if>
      <xsl:call-template name="Text">
        <xsl:with-param name="words">
          <xsl:value-of select="$text"/>
        </xsl:with-param>
      </xsl:call-template>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template Text
Namespace No namespace
Used by
References
Template
Parameters
QName Namespace
words No namespace
Import precedence 8
Source
<xsl:template name="Text">
  <xsl:param name="words"/>
  <xsl:choose>
    <xsl:when test="contains($words,'&')">
      <xsl:value-of select="substring-before($words,'&')"/>
      <xsl:text>&amp;</xsl:text>
      <xsl:call-template name="Text">
        <xsl:with-param name="words">
          <xsl:value-of select="substring-after($words,'&')"/>
        </xsl:with-param>
      </xsl:call-template>
    </xsl:when>
    <xsl:otherwise>
      <xsl:value-of select="$words"/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template *verbatim
Namespace No namespace
Match *
Mode verbatim
References
Import precedence 8
Source
<xsl:template match="*" mode="verbatim">
  <xsl:choose>
    <xsl:when test="parent::xhtml:Wrapper"/>
    <!--      <xsl:when test="child::node()[last()]/self::text()[not(.='')] and child::node()[1]/self::text()[not(.='')]"/>-->
    <xsl:when test="not(parent::*)  or parent::teix:egXML">
      <xsl:choose>
        <xsl:when test="preceding-sibling::node()[1][self::text()]      and following-sibling::node()[1][self::text()]"/>
        <xsl:when test="preceding-sibling::*">
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">-1</xsl:with-param>
          </xsl:call-template>
        </xsl:when>
        <xsl:otherwise>
          <xsl:call-template name="newLine"/>
          <!-- <xsl:call-template name="makeIndent"/>-->
        </xsl:otherwise>
      </xsl:choose>
    </xsl:when>
    <xsl:when test="not(preceding-sibling::node())">
      <xsl:call-template name="lineBreak">
        <xsl:with-param name="id">-2</xsl:with-param>
      </xsl:call-template>
      <xsl:call-template name="makeIndent"/>
    </xsl:when>
    <xsl:when test="preceding-sibling::node()[1]/self::*">
      <xsl:call-template name="lineBreak">
        <xsl:with-param name="id">1</xsl:with-param>
      </xsl:call-template>
      <xsl:call-template name="makeIndent"/>
    </xsl:when>
    <xsl:when test="preceding-sibling::node()[1]/self::text()">
    </xsl:when>
    <xsl:otherwise>
      <xsl:call-template name="lineBreak">
        <xsl:with-param name="id">9</xsl:with-param>
      </xsl:call-template>
      <xsl:call-template name="makeIndent"/>
    </xsl:otherwise>
  </xsl:choose>
  <xsl:value-of disable-output-escaping="yes" select="$startElement"/>
  <xsl:text><</xsl:text>
  <xsl:call-template name="makeElementName">
    <xsl:with-param name="start">true</xsl:with-param>
  </xsl:call-template>
  <xsl:apply-templates select="@*" mode="verbatim"/>
  <xsl:if test="$showNamespaceDecls='true' or parent::teix:egXML[@rend='full']">
    <xsl:choose>
      <xsl:when test="not(parent::*)">
        <xsl:apply-templates select="." mode="ns"/>
      </xsl:when>
      <xsl:when test="parent::teix:egXML and not(preceding-sibling::*)">
        <xsl:apply-templates select="." mode="ns"/>
      </xsl:when>
    </xsl:choose>
  </xsl:if>
  <xsl:choose>
    <xsl:when test="child::node()">
      <xsl:text>></xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endElement"/>
      <xsl:apply-templates mode="verbatim"/>
      <xsl:choose>
        <xsl:when test="child::node()[last()]/self::text() and child::node()[1]/self::text()"/>
        <xsl:when test="not(parent::*)  or parent::teix:egXML">
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">23</xsl:with-param>
          </xsl:call-template>
        </xsl:when>
        <xsl:when test="child::node()[last()]/self::text()[normalize-space(.)='']">
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">3</xsl:with-param>
          </xsl:call-template>
          <xsl:call-template name="makeIndent"/>
        </xsl:when>
        <xsl:when test="child::node()[last()]/self::comment()">
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">4</xsl:with-param>
          </xsl:call-template>
          <xsl:call-template name="makeIndent"/>
        </xsl:when>
        <xsl:when test="child::node()[last()]/self::*">
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">5</xsl:with-param>
          </xsl:call-template>
          <xsl:call-template name="makeIndent"/>
        </xsl:when>
      </xsl:choose>
      <xsl:value-of disable-output-escaping="yes" select="$startElement"/>
      <xsl:text></</xsl:text>
      <xsl:call-template name="makeElementName">
        <xsl:with-param name="start">false</xsl:with-param>
      </xsl:call-template>
      <xsl:text>></xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endElement"/>
    </xsl:when>
    <xsl:otherwise>
      <xsl:text>/></xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endElement"/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeElementName
Namespace No namespace
Used by
Template
References
Parameters
QName Namespace
start No namespace
Import precedence 8
Source
<xsl:template name="makeElementName">
  <xsl:param name="start"/>
  <xsl:choose>
    <xsl:when test="namespace-uri()='http://docbook.org/ns/docbook'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>dbk:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/2001/XMLSchema'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>xsd:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.ascc.net/xml/schematron'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>sch:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/1998/Math/MathML'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>m:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>nvdl:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://relaxng.org/ns/compatibility/annotations/1.0'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>a:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/1999/xhtml'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>xhtml:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/1999/xlink'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>xlink:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://relaxng.org/ns/structure/1.0'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>rng:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://earth.google.com/kml/2.1'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>kml:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/2005/11/its'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>its:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/1999/XSL/Transform'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>xsl:</xsl:text>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.tei-c.org/ns/Examples'">
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/2005/Atom'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>atom:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://purl.org/rss/1.0/modules/event/'">
      <xsl:value-of disable-output-escaping="yes" select="$startNamespace"/>
      <xsl:text>ev:</xsl:text>
      <xsl:value-of disable-output-escaping="yes" select="$endNamespace"/>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:when>
    <xsl:when test="not(namespace-uri()='')">
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
      <xsl:if test="$start='true'">
        <xsl:text> xmlns="</xsl:text>
        <xsl:value-of select="namespace-uri()"/>
        <xsl:text>"</xsl:text>
      </xsl:if>
    </xsl:when>
    <xsl:otherwise>
      <xsl:value-of disable-output-escaping="yes" select="$startElementName"/>
      <xsl:value-of select="local-name(.)"/>
      <xsl:value-of disable-output-escaping="yes" select="$endElementName"/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeIndent
Namespace No namespace
Used by
References
Template
Import precedence 8
Source
<xsl:template name="makeIndent">
  <xsl:variable name="depth" select="count(ancestor::*[not(namespace-uri()='http://www.tei-c.org/ns/1.0')])"/>
  <xsl:call-template name="makeSpace">
    <xsl:with-param name="d">
      <xsl:value-of select="$depth"/>
    </xsl:with-param>
  </xsl:call-template>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeSpace
Namespace No namespace
Used by
Templates
References
Parameter
Template
Parameters
QName Namespace
d No namespace
Import precedence 8
Source
<xsl:template name="makeSpace">
  <xsl:param name="d"/>
  <xsl:if test="number($d)>1">
    <xsl:value-of select="$spaceCharacter"/>
    <xsl:call-template name="makeSpace">
      <xsl:with-param name="d">
        <xsl:value-of select="$d -1"/>
      </xsl:with-param>
    </xsl:call-template>
  </xsl:if>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template @*verbatim
Namespace No namespace
Match @*
Mode verbatim
References
Import precedence 8
Source
<xsl:template match="@*" mode="verbatim">
  <xsl:variable name="L">
    <xsl:for-each select="../@*">
      <xsl:value-of select="."/>
    </xsl:for-each>
  </xsl:variable>
  <xsl:if test="count(../@*)>$attsOnSameLine or string-length($L)>40 or     namespace-uri()='http://www.w3.org/2005/11/its' or     string-length(.)+string-length(name(.)) > 40">
    <xsl:call-template name="lineBreak">
      <xsl:with-param name="id">5</xsl:with-param>
    </xsl:call-template>
    <xsl:call-template name="makeIndent"/>
  </xsl:if>
  <xsl:value-of select="$spaceCharacter"/>
  <xsl:value-of disable-output-escaping="yes" select="$startAttribute"/>
  <xsl:choose>
    <xsl:when test="namespace-uri()='http://www.w3.org/2005/11/its'">
      <xsl:text>its:</xsl:text>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/XML/1998/namespace'">
      <xsl:text>xml:</xsl:text>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.w3.org/1999/xlink'">
      <xsl:text>xlink:</xsl:text>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://www.example.org/ns/nonTEI'">
      <xsl:text>my:</xsl:text>
    </xsl:when>
    <xsl:when test="namespace-uri()='http://relaxng.org/ns/compatibility/annotations/1.0'">
      <xsl:text>a:</xsl:text>
    </xsl:when>
    <!--    <xsl:otherwise>
    <xsl:for-each select="namespace::*">
      <xsl:if test="not(name(.)='')">
	  <xsl:value-of select="name(.)"/>
	  <xsl:text>:</xsl:text>
      </xsl:if>
    </xsl:for-each>
    </xsl:otherwise>
-->
  </xsl:choose>
  <xsl:value-of select="local-name(.)"/>
  <xsl:value-of disable-output-escaping="yes" select="$endAttribute"/>
  <xsl:text>="</xsl:text>
  <xsl:value-of disable-output-escaping="yes" select="$startAttributeValue"/>
  <xsl:apply-templates select="." mode="attributetext"/>
  <xsl:value-of disable-output-escaping="yes" select="$endAttributeValue"/>
  <xsl:text>"</xsl:text>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template @*attributetext
Namespace No namespace
Match @*
Mode attributetext
References
Template
Import precedence 8
Source
<xsl:template match="@*" mode="attributetext">
  <xsl:choose>
    <xsl:when test="string-length(.)>50">
      <xsl:choose>
        <xsl:when test="contains(.,'|')">
          <xsl:call-template name="breakMe">
            <xsl:with-param name="text">
              <xsl:value-of select="."/>
            </xsl:with-param>
            <xsl:with-param name="sep">
              <xsl:text>|</xsl:text>
            </xsl:with-param>
          </xsl:call-template>
        </xsl:when>
        <xsl:otherwise>
          <xsl:call-template name="breakMe">
            <xsl:with-param name="text">
              <xsl:value-of select="."/>
            </xsl:with-param>
            <xsl:with-param name="sep">
              <xsl:text> </xsl:text>
            </xsl:with-param>
          </xsl:call-template>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:when>
    <xsl:otherwise>
      <xsl:value-of select="."/>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template breakMe
Namespace No namespace
Used by
References
Template
Parameters
QName Namespace
sep No namespace
text No namespace
Import precedence 8
Source
<xsl:template name="breakMe">
  <xsl:param name="text"/>
  <xsl:param name="sep"/>
  <xsl:choose>
    <xsl:when test="string-length($text)<50">
      <xsl:value-of select="$text"/>
    </xsl:when>
    <xsl:otherwise>
      <xsl:value-of select="substring-before($text,$sep)"/>
      <xsl:text>
</xsl:text>
      <xsl:value-of select="$sep"/>
      <xsl:call-template name="breakMe">
        <xsl:with-param name="text">
          <xsl:value-of select="substring-after($text,$sep)"/>
        </xsl:with-param>
        <xsl:with-param name="sep">
          <xsl:value-of select="$sep"/>
        </xsl:with-param>
      </xsl:call-template>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template text()|comment()|processing-instruction()ns
Namespace No namespace
Match text()|comment()|processing-instruction()
Mode ns
Import precedence 8
Source
<xsl:template match="text()|comment()|processing-instruction()" mode="ns"/>
Stylesheet location ../../../odt/teitoodt.xsl
Template *ns
Namespace No namespace
Match *
Mode ns
References
Template
Parameters
QName Namespace
list No namespace
Import precedence 8
Source
<xsl:template match="*" mode="ns">
  <xsl:param name="list"/>
  <xsl:variable name="used">
    <xsl:for-each select="namespace::*">
      <xsl:variable name="ns" select="."/>
      <xsl:choose>
        <xsl:when test="contains($list,$ns)"/>
        <xsl:when test=".='http://relaxng.org/ns/structure/1.0'"/>
        <xsl:when test=".='http://www.w3.org/2001/XInclude'"/>
        <xsl:when test=".='http://www.tei-c.org/ns/Examples'"/>
        <xsl:when test=".='http://relaxng.org/ns/compatibility/annotations/1.0'"/>
        <xsl:when test="name(.)=''"/>
        <xsl:when test=".='http://www.w3.org/XML/1998/namespace'"/>
        <xsl:otherwise>
          <xsl:call-template name="lineBreak">
            <xsl:with-param name="id">22</xsl:with-param>
          </xsl:call-template>
          <xsl:text>   </xsl:text>
          <xsl:text>xmlns:</xsl:text>
          <xsl:value-of select="name(.)"/>
          <xsl:text>="</xsl:text>
          <xsl:value-of select="."/>
          <xsl:text>"</xsl:text>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:for-each>
  </xsl:variable>
  <xsl:copy-of select="$used"/>
  <xsl:apply-templates mode="ns">
    <xsl:with-param name="list">
      <xsl:value-of select="$list"/>
      <xsl:value-of select="$used"/>
    </xsl:with-param>
  </xsl:apply-templates>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template tei:soCalled
Namespace No namespace
Match tei:soCalled
Mode #default
References
Parameters
Import precedence 8
Source
<xsl:template match="tei:soCalled">
  <text:span>
    <xsl:value-of select="$preQuote"/>
    <xsl:apply-templates/>
    <xsl:value-of select="$postQuote"/>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeExternalLink
Namespace No namespace
Used by
Supersedes
Parameters
Import precedence 8
Source
Stylesheet location ../../../odt/teitoodt.xsl
Template makeSpan
Namespace No namespace
Used by
Import precedence 8
Source
<xsl:template name="makeSpan">
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeText
Namespace No namespace
Used by
Parameters
QName Namespace
letters No namespace
Import precedence 8
Source
<xsl:template name="makeText">
  <xsl:param name="letters"/>
  <xsl:value-of select="$letters"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template emphasize
Namespace No namespace
Used by
Parameters
QName Namespace
class No namespace
content No namespace
Import precedence 8
Source
<xsl:template name="emphasize">
  <xsl:param name="class"/>
  <xsl:param name="content"/>
  <text:span>
    <xsl:choose>
      <xsl:when test="$class='titlem'">
        <xsl:attribute name="text:style-name">Emphasis</xsl:attribute>
      </xsl:when>
      <xsl:when test="$class='titlej'">
        <xsl:attribute name="text:style-name">Emphasis</xsl:attribute>
      </xsl:when>
    </xsl:choose>
    <xsl:attribute name="xml:space">preserve</xsl:attribute>
    <xsl:choose>
      <xsl:when test="$class='titles'">
        <xsl:text>, </xsl:text>
      </xsl:when>
      <xsl:when test="$class='titleu'">
        <xsl:text></xsl:text>
      </xsl:when>
      <xsl:when test="$class='titlea'">
        <xsl:text></xsl:text>
      </xsl:when>
    </xsl:choose>
    <xsl:value-of select="$content"/>
    <xsl:choose>
      <xsl:when test="$class='titleu'">
        <xsl:text></xsl:text>
      </xsl:when>
      <xsl:when test="$class='titlea'">
        <xsl:text></xsl:text>
      </xsl:when>
    </xsl:choose>
  </text:span>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeBlock
Namespace No namespace
Used by
Parameters
QName Namespace
style No namespace
Import precedence 8
Source
<xsl:template name="makeBlock">
  <xsl:param name="style"/>
  <xsl:apply-templates/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeInline
Namespace No namespace
Used by
Parameters
QName Namespace
after No namespace
before No namespace
style No namespace
Import precedence 8
Source
<xsl:template name="makeInline">
  <xsl:param name="before"/>
  <xsl:param name="after"/>
  <xsl:param name="style"/>
  <xsl:value-of select="$before"/>
  <xsl:apply-templates/>
  <xsl:value-of select="$after"/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template generateEndLink
Namespace No namespace
Used by
Parameters
Import precedence 8
Source
Stylesheet location ../../../odt/teitoodt.xsl
Template makeSection
Namespace No namespace
Used by
References
Template
Parameters
QName Namespace
heading No namespace
implicitBlock No namespace
level No namespace
Import precedence 8
Source
<xsl:template name="makeSection">
  <xsl:param name="level"/>
  <xsl:param name="implicitBlock"/>
  <xsl:param name="heading"/>
  <text:p text:style-name="tei{local-name()}">
    <xsl:call-template name="test.id"/>
    <text:span>
      <xsl:value-of select="$heading"/>
    </text:span>
  </text:p>
  <text:p>
    <xsl:apply-templates/>
  </text:p>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Template makeWithLabel
Namespace No namespace
Used by
Parameters
QName Namespace
before No namespace
Import precedence 8
Source
<xsl:template name="makeWithLabel">
  <xsl:param name="before"/>
  <text:span text:style-name="Emphasis">
    <xsl:value-of select="$before"/>
    <xsl:text>: </xsl:text>
  </text:span>
  <text:span text:style-name="tei{local-name()}"/>
  <xsl:value-of select="."/>
</xsl:template>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter useFixedDate
Namespace No namespace
Used by
Supersedes
Parameter
Source
<xsl:param name="useFixedDate">false</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter debug
Namespace No namespace
Used by
Template
Source
<xsl:param name="debug">false</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter useHeaderFrontMatter
Namespace No namespace
Used by
Supersedes
Source
<xsl:param name="useHeaderFrontMatter">false</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter postQuote
Namespace No namespace
Used by
Template
Supersedes
Parameter
Source
<xsl:param name="postQuote"></xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter preQuote
Namespace No namespace
Used by
Template
Supersedes
Parameter
Source
<xsl:param name="preQuote"></xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter outputDir
Namespace No namespace
Used by
Templates
Source
<xsl:param name="outputDir">.</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter freestanding
Namespace No namespace
Overriding
Parameter
Source
<xsl:param name="freestanding">false</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter outputTarget
Namespace No namespace
Used by
Supersedes
Parameter
Source
<xsl:param name="outputTarget">odt</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter urlMarkup
Namespace No namespace
Used by
Template
Supersedes
Parameter
Source
<xsl:param name="urlMarkup"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter linkElement
Namespace No namespace
Used by
Supersedes
Parameter
Source
<xsl:param name="linkElement">a</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter linkAttribute
Namespace No namespace
Used by
Supersedes
Parameter
Source
<xsl:param name="linkAttribute">href</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter linkElementNamespace
Namespace No namespace
Used by
Supersedes
Source
<xsl:param name="linkElementNamespace">urn:oasis:names:tc:opendocument:xmlns:text:1.0</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter linkAttributeNamespace
Namespace No namespace
Used by
Supersedes
Source
<xsl:param name="linkAttributeNamespace">http://www.w3.org/1999/xlink</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startComment
Namespace No namespace
Used by
Source
<xsl:param name="startComment"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endComment
Namespace No namespace
Used by
Source
<xsl:param name="endComment"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startElement
Namespace No namespace
Used by
Template
Source
<xsl:param name="startElement"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endElement
Namespace No namespace
Used by
Template
Source
<xsl:param name="endElement"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startElementName
Namespace No namespace
Used by
Template
Source
<xsl:param name="startElementName"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endElementName
Namespace No namespace
Used by
Template
Source
<xsl:param name="endElementName"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startAttribute
Namespace No namespace
Used by
Template
Source
<xsl:param name="startAttribute"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endAttribute
Namespace No namespace
Used by
Template
Source
<xsl:param name="endAttribute"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startAttributeValue
Namespace No namespace
Used by
Template
Source
<xsl:param name="startAttributeValue"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endAttributeValue
Namespace No namespace
Used by
Template
Source
<xsl:param name="endAttributeValue"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter startNamespace
Namespace No namespace
Used by
Template
Source
<xsl:param name="startNamespace"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter endNamespace
Namespace No namespace
Used by
Template
Source
<xsl:param name="endNamespace"/>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter spaceCharacter
Namespace No namespace
Used by
Templates
Source
<xsl:param name="spaceCharacter"> </xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter showNamespaceDecls
Namespace No namespace
Used by
Template
Source
<xsl:param name="showNamespaceDecls">true</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter wrapLength
Namespace No namespace
Source
<xsl:param name="wrapLength">65</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Parameter attsOnSameLine
Namespace No namespace
Used by
Template
Source
<xsl:param name="attsOnSameLine">3</xsl:param>
Stylesheet location ../../../odt/teitoodt.xsl
Variable doc_type
Namespace No namespace
Source
<xsl:variable name="doc_type">TEI</xsl:variable>
Stylesheet location ../../../odt/teitoodt.xsl
Function tei:convert-dim-pt (dim)
Namespace http://www.tei-c.org/ns/1.0
Type xs:integer
Used by
Template
Parameters
QName Namespace
dim No namespace
Import precedence 8
Source
<xsl:function name="tei:convert-dim-pt" as="xs:integer">
  <xsl:param name="dim"/>
  <xsl:choose>
    <xsl:when test="ends-with($dim,'cm')">
      <xsl:value-of select="number(number(substring($dim,0,string-length($dim)-1))*28.3464567) cast as xs:integer"/>
    </xsl:when>
    <xsl:when test="ends-with($dim,'in')">
      <xsl:value-of select="number(number(substring($dim,0,string-length($dim)-1))*72) cast as xs:integer"/>
    </xsl:when>
    <xsl:when test="ends-with($dim,'mm')">
      <xsl:value-of select="number(number(substring($dim,0,string-length($dim)-1))*2.83464567) cast as xs:integer"/>
    </xsl:when>
    <xsl:when test="ends-with($dim,'pt')">
      <xsl:value-of select="number(substring($dim,0,string-length($dim)-1)) cast as xs:integer"/>
    </xsl:when>
    <xsl:when test="ends-with($dim,'px')">
      <xsl:value-of select="number(number(substring($dim,0,string-length($dim)-1))*0.75) cast as xs:integer"/>
    </xsl:when>
    <xsl:otherwise>-1</xsl:otherwise>
  </xsl:choose>
</xsl:function>
Stylesheet location ../../../odt/teitoodt.xsl
Output (default)
Namespace No namespace
Output properties
method encoding omit-xml-declaration
xml no
Source
<xsl:output method="xml" omit-xml-declaration="no"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key W
Namespace No namespace
Match image
Use @url
Used by
Template
Source
<xsl:key name="W" match="image" use="@url"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key H
Namespace No namespace
Match image
Use @url
Used by
Template
Source
<xsl:key name="H" match="image" use="@url"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key IDS
Namespace No namespace
Match tei:*[@xml:id]
Use @xml:id
Source
<xsl:key name="IDS" match="tei:*[@xml:id]" use="@xml:id"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key GRAPHICS
Namespace No namespace
Match tei:graphic
Use 1
Used by
Template
Source
<xsl:key name="GRAPHICS" match="tei:graphic" use="1"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key Page
Namespace No namespace
Match style:page-layout-properties
Use 1
Source
<xsl:key name="Page" match="style:page-layout-properties" use="1"/>
Stylesheet location ../../../odt/teitoodt.xsl
Key Namespaces
Namespace No namespace
Match *[not(ancestor::*)]
Use namespace-uri()
Source
<xsl:key name="Namespaces" match="*[not(ancestor::*)]" use="namespace-uri()"/>
Stylesheet location ../../../odt/teitoodt.xsl
Decimal format staff
Namespace No namespace
Decimal format properties
digit
D
Source
<xsl:decimal-format name="staff" digit="D"/>
Stylesheet location ../../../odt/teitoodt.xsl