Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Lists of all kinds
  • Loading branch information
Klaus Thoden committed Nov 20, 2018
1 parent a03eaa5 commit 50b7ff8
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions tei2eoatex.xsl
Expand Up @@ -280,6 +280,41 @@ contexts, a double replacement is performed.
<xsl:text>&#x000a;\refstepcounter{figure}&#x2E0E;&#x000a;</xsl:text>
</xsl:template>

<xsl:template match="//tei:list">
<xsl:choose>
<xsl:when test="@type='ordered'">
<xsl:text>\begin{EOAlist}&#x000a;</xsl:text>
<xsl:apply-templates select="./tei:item"/>
<xsl:text>\end{EOAlist}&#x000a;</xsl:text>
</xsl:when>
<xsl:when test="@type='bulleted'">
<xsl:text>\begin{EOAitems}&#x000a;</xsl:text>
<xsl:apply-templates select="./tei:item"/>
<xsl:text>\end{EOAitems}&#x000a;</xsl:text>
</xsl:when>
<xsl:when test="@type='gloss'">
<xsl:text>\begin{EOAdescription}&#x000a;</xsl:text>
<xsl:call-template name="description"/>
<xsl:text>\end{EOAdescription}&#x000a;</xsl:text>
</xsl:when>
</xsl:choose>
</xsl:template>

<xsl:template match="//tei:item">
<xsl:text>\item </xsl:text>
<xsl:apply-templates/>
<xsl:text>&#x000a;</xsl:text>
</xsl:template>

<xsl:template name="description">
<xsl:for-each select="./tei:label">
<xsl:text>\item[</xsl:text>
<xsl:value-of select="."/>
<xsl:text>] </xsl:text>
<xsl:apply-templates select="following-sibling::tei:item[1]"/>
</xsl:for-each>
</xsl:template>

<xsl:template match="//tei:figure[not(@type='hionly')]">
<xsl:text>&#x000a;&#x000a;\EOAfigure{</xsl:text>
<xsl:value-of select="./tei:graphic/@url"/>
Expand Down

0 comments on commit 50b7ff8

Please sign in to comment.