<?xml version="1.0" encoding="euc-jp"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0" encoding="euc-jp">
<xsl:output method="html"/>
  <xsl:template match="/dictionaly">
    <html>
      <head>
        <title> evakichism dictionaly system ver. 0.1 -<xsl:value-of select="child::name"/>-</title>
      </head>
      <body bgcolor="#FFFFFF">
<CENTER><FONT SIZE="7"><xsl:value-of select="child::name"/></FONT></CENTER>
	<P/><A NAME="index">index</A>
	<CENTER>
	<xsl:for-each select="child::category">
		<A HREF="#{generate-id()}">    		
		[<xsl:value-of select="attribute::name"/>]
	</A>
	</xsl:for-each>
</CENTER>	
	<HR/>	
        <blockquote><xsl:apply-templates select="child::category"/></blockquote>
      </body>
    </html>
  </xsl:template>

  <xsl:template match="category">
	<A NAME="{generate-id(.)}"><FONT COLOR="BLUE" SIZE="5"><xsl:value-of select="attribute::name"/></FONT></A><P/>
	<xsl:for-each select="child::data">
		<xsl:sort/><A HREF="#{generate-id()}"><xsl:value-of select="child::keyword"/></A><xsl:text>  </xsl:text>
	</xsl:for-each>
	<HR/>
	<xsl:apply-templates select="child::data"><xsl:sort/></xsl:apply-templates>
	<A HREF="#index">return to index</A>
<BR/>
<BR/>
<BR/>
  </xsl:template>

<xsl:template match="data">
	<A NAME="{generate-id(.)}"><FONT COLOR="RED" SIZE="3"><xsl:value-of select="child::keyword"/></FONT></A><P/>
	<blockquote><xsl:for-each select="child::mean"><xsl:if test="last()!=1"><xsl:value-of select="position()"/>,</xsl:if><xsl:copy-of select="self::node()"/><xsl:if test="last()!=1"><BR/></xsl:if></xsl:for-each><BR/>
	<blockquote>
	<xsl:apply-templates select="example"/>
	</blockquote>
        <A href="#{generate-id(parent::category)}">return to category</A>
</blockquote>
</xsl:template>	

<xsl:template match="example">
	<xsl:copy-of select="child::text"/><xsl:text>	</xsl:text><xsl:apply-templates select="child::mean"/><xsl:if test='position()!=last()'><BR/></xsl:if>
</xsl:template>	

<xsl:template match="mean">
	<FONT COLOR="GREEN"><i><B><xsl:copy-of select="self::node()"/></B></i></FONT>
</xsl:template>	

</xsl:stylesheet>
