<?xml version="1.0"?>
<!-- 
     Etymological view of Sikaiana dictionary
     G. Simons, SIL International (14 Oct 2005)
-->
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  <xsl:output method="html" version="4.0"/>
   <xsl:template match="/">
    <HTML>
      <HEAD>
        <TITLE>Sikaiana Reflexes of Proto-Polynesian</TITLE>
        <STYLE>
          BODY       { margin:30px; background-color: #DDFFEE; 
                       font-family: Arial, Helvetica, sans-serif;  }
          H1     { margin-left:-18px; }
          P      { text-indent:-18px; }
        </STYLE>
      </HEAD>
      <BODY>
          <H1>Sikaiana Reflexes of Proto-Polynesian</H1>
          <TABLE BORDER="0" CELLPADDING="8">
             <TR><TD><I>PPN</I></TD>
                 <TD><I>Sikaiana</I></TD>
                 <TD><I>Definition</I></TD></TR>
             <xsl:apply-templates select="dictionary/body/*"/>
          </TABLE>
      </BODY>
    </HTML>
  </xsl:template>
  
  <xsl:template match="entry">
     <xsl:if test="etym[lang/text() = 'PPN']">
     <TR valign="top">
        <TD><xsl:value-of select="etym/mentioned"/>
            <xsl:if test="etym/gloss">
             '<xsl:value-of select="etym/gloss"/>'
            </xsl:if></TD>
        <TD><xsl:value-of select="form"/></TD>
        <TD><xsl:apply-templates select="sense"/></TD> </TR>
     </xsl:if>
  </xsl:template>

  <xsl:template match="sense">
    <xsl:if test="@n">
        <xsl:value-of select="@n" />. 
    </xsl:if>
    <xsl:apply-templates select="def"/>
  </xsl:template>

  <xsl:template match="def">
    <xsl:apply-templates/>
  </xsl:template>

  <xsl:template match="sik">
    <I><xsl:apply-templates/></I>
  </xsl:template>

</xsl:stylesheet>
