<?xml version="1.0" encoding="Shift_JIS"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">

<xsl:template match="/">
<html lang="ja">
	<head>
		<title>ISO/IEC IT --- Simple Test ---</title>
	</head>
	<style>
		h1		{ font-size: 20pt ;
				color : white ;
				background-color: blue ;}
		h2		{ font-soze: 14pt ;
				background-color: yellow ;}
		h3		{ font-size: 12pt ;
				color : black ;
				background-color: white ;}				background-color: white ;}
		strong.blue	{ color: blue ;
				font-weight: bold ;}
		ul		{ list-style: lower-alpha outside }
		ol		{ list-style: lower-alpha outside }
		a:link		{ color: blue ;}
		a:visit		{ text-decoration: line-through ;}
		a:active	{ color: red ;}
		a:hover		{ color: white ;}
		p		{ margin-top : 0.5em ;
				margin-bottom : 1.5em ;}
    	</style>
<body>
    <H1><xsl:value-of select="html/document/body/title"/></H1>
    <xsl:apply-templates select="html/document/body/scope"/>
	<H2>1 Scope</H2>
    <xsl:apply-templates select="html/document/body/scope/p"/>
    <xsl:apply-templates select="html/document/body/conf"/>
	<H2>2 Conformance</H2>
    <xsl:apply-templates select="html/document/body/conf/p"/>
    <xsl:apply-templates select="html/document/body/refs"/>
	<H2>3 Normative Refernce</H2>
    <xsl:apply-templates select="html/document/body/refs/p"/>
    <xsl:apply-templates select="html/document/body/defs"/>
	<H2>4 Definitions</H2>
    <xsl:apply-templates select="html/document/body/defs/p"/>
    <xsl:apply-templates select="html/document/body/sec"/>
	<H2>5 Notation and Conventions</H2>
    <xsl:apply-templates select="html/document/body/sec/subsec"/>
	<H3>5.1 Syntax Production</H3>
    <xsl:apply-templates select="html/document/body/sec/subsec/p"/>
</body>
</html>
</xsl:template>

<xsl:template match="html/document/body/scope/p">
	<xsl:value-of select="./p1[0]"/>
	<ol type='a'>
		<li><p><xsl:value-of select="//scope/p/ol/li[0]"/></p></li>
		<li><p><xsl:value-of select="//scope/p/ol/li[1]"/></p></li>
	</ol>
	<p><xsl:value-of select="./p1[1]"/></p>
	<p><xsl:value-of select="./p1[2]"/></p>
	<p><xsl:value-of select="./p1[3]"/></p>
	<p><xsl:value-of select="./p1[4]"/></p>
	<ol type='a'>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[0]"/></p></li>
		<p><small>NOTE 1 - <xsl:value-of select="//scope/p/ol/note[0]"/></small></p>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[1]"/></p></li>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[2]"/></p></li>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[3]"/></p></li>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[4]"/></p></li>
		<li><p><xsl:value-of select="//scope/p/ol[1]/li[5]"/></p></li>
	</ol>
	<p><xsl:value-of select="./p1[5]"/></p>
</xsl:template>

<xsl:template match="html/document/body/conf/p">
	<xsl:for-each select="//body/conf/p/p1">
		<p><xsl:value-of select="."/></p>
	</xsl:for-each>
</xsl:template>

<xsl:template match="html/document/body/refs/p">
	<p><xsl:value-of select="//body/refs/p/p1[0]"/></p>
	<xsl:for-each select="//body/refs/p/p1">
		<p><xsl:value-of select="./ni"/>
		<i><xsl:value-of select="i"/></i>
		</p>
	</xsl:for-each>
</xsl:template>

<xsl:template match="html/document/body/defs/p">
	<p><xsl:value-of select="//body/defs/p/p1"/></p>
	<xsl:for-each select="//body/defs/p/dp">
		<p><b><xsl:value-of select="./tm"/></b>
		<br><xsl:value-of select="df"/></br>
		</p>
	</xsl:for-each>	
</xsl:template>

<xsl:template match="html/document/body/sec/subsec/p">
	<p><xsl:value-of select="."/></p>
</xsl:template>

</xsl:stylesheet>

