<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
                xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:output method="xml" omit-xml-declaration="yes" indent="yes" encoding="ISO-8859-1"/>
<xsl:strip-space elements="*"/>

<xsl:variable name="persondb" select="document('lfdb.persons.xml')"/>
<xsl:variable name="englishdb" select="document('lfdb.en.xml')"/>

<xsl:variable name="version" select="0.2"/>

<xsl:template match="/">
<html>
  <head>
    <title>LinuxFocus - Nederlandse Mainindex</title>
  </head>
<body bgcolor="#ffffff" text="#000000" alink="#336633" link="#336699">

<!-- MAP voor bovenste navigatiebalk -->  
<MAP name="top">  
<AREA shape="rect" coords="367,9,418,30" alt="Home" href="index.html"/>  
<AREA shape="rect" coords="423,9,457,30" alt="Map" href="map.html"/>
<AREA shape="rect" coords="463,9,508,30" alt="Index" href="indice.html"/>  
<AREA shape="rect" coords="514,9,558,30" alt="Zoek" href="Search/index.html"/>
</MAP>  
  
<!-- MAP voor onderste navigatiebalk -->  
<MAP name="bottom">
<AREA shape="rect" coords="78,0,163,15"  alt="Nieuws" href="News/"/>  
<AREA shape="rect" coords="189,0,284,15" alt="Archieven" href="Archives/index.html"/>
<AREA shape="rect" coords="319,0,395,15" alt="Links" href="Links/index.html"/>  
<AREA shape="rect" coords="436,0,523,15" alt="Over LinuxFocus" href="aboutus.html"/>
</MAP>

<!-- NAVIGATIEBALK -->
<CENTER>
<IMG src="../common/images/Topbar-nl.gif" width="600" height="40" border="0" 
     ismap="yes" usemap="#top" /><BR />
<IMG src="../common/images/Bottombar-nl.gif" width="600" height="21" border="0" 
     ismap="yes" usemap="#bottom" /><BR />
</CENTER>

<H1>LinuxFocus Overzicht</H1>
<P>Dit is een overzicht van alle LinuxFocus artikels. Artikels die al
vertaald zijn, hebben een witte achtergrond. Een grijze achtergrond
betekent 'nog niet vertaald' en artikels met een blauwe achtergrond
zijn reeds gereserveerd voor vertaling, maar nog niet afgewerkt.</P>

<P><B>U kan <FONT COLOR="#BB1100">LinuxFocus</FONT> helpen!</B>
Als je een artikel ziet dat nog niet vertaald is en
je graag zelf zou vertalen, reserveer het dan voor u door een e-mail te
sturen naar de Nederlandse mailing list op 
<A href="mailto:dutch@linuxfocus.org">dutch@linuxfocus.org</A>.
</P>

<H1>LinuxFocus translators page</H1>

<P>This is an index of all LinuxFocus articles. Already translated
articles are shown with white background. Articles that are grayed
are not translated yet and articles with blue background are reserved
for translation but not yet ready.</P>

<P><B>You can help <FONT COLOR="#BB1100">LinuxFocus</FONT>!</B> 
If you see an article that is not yet 
translated and you would like to translate it then reserve it for
you by sending an e-mail to the person mentioned as maintainer
at the end of this page.</P>

    <table bgcolor="grey">
    <th bgcolor="black">
      <td bgcolor="black"><font color="white">titel</font></td>
      <td bgcolor="black"><font color="white">vertaald?</font></td>
      <td bgcolor="black"><font color="white">gecontroleerd?</font></td>
    </th>
    <xsl:for-each select="database/issues/issue">
      <xsl:sort select="@code" data-type="number" 
                order="descending"/>
        <xsl:apply-templates select="."/>
    </xsl:for-each>
    </table>
<HR width="100%" size="4" NOSHADE="yes" />
<P>Deze pagina is gemaakt met <B><FONT COLOR="#008000">mainindex.xslt, version <xsl:value-of select="$version"/></FONT></B>.</P>
<P>Deze pagina wordt onderhouden door: <A href="mailto:dutch@linuxfocus.org?subject=lfmainindex">het Nederlandse LinuxFocus team</A></P>
<BR clear="all" />
<!-- start of footer -->
<hr WIDTH="85%" noshade="yes" size="1" />
<CENTER>
<table WIDTH="85%" >
 <TR bgcolor="#666666">
   <TD align="center">
   <FONT color="#FFFFFF">
    <B>&amp;copy; 2000 LinuxFocus</B><BR />
    </FONT>
    <A href="../common/lfteam.html"><FONT color="#FFFFFF">Ga naar de LinuxFocus Contact Personen Pagina</FONT></A>
   </TD>
 </TR>
</table>
</CENTER>
  </body>
</html>
</xsl:template>

<xsl:template match="issue">
  <xsl:variable name="issueid"><xsl:value-of select="@id"/></xsl:variable>
  <tr bgcolor="black">
    <td colspan="4"><font color="white"><xsl:value-of select="title"/></font></td>
  </tr>
  <xsl:for-each select="/database/articles/article">
    <xsl:sort select="@id" data-type="number" order="descending"/>
    <xsl:variable name="artid"><xsl:value-of select="@id"/></xsl:variable>
    <xsl:variable name="artissue">
      <xsl:value-of 
        select="$englishdb/database/articles/article[@id=$artid]/issue/@href"/>
    </xsl:variable>
    <xsl:if test="$artissue=$issueid">
      <xsl:apply-templates select="."/>
    </xsl:if>
  </xsl:for-each>
</xsl:template>

<xsl:template match="article">
  <xsl:choose>
    <xsl:when test="translation/finished">
      <xsl:element name="tr">
        <xsl:attribute name="bgcolor">white</xsl:attribute>
        <xsl:call-template name="article_data"/>
      </xsl:element>
    </xsl:when>
    <xsl:when test="@xml:lang='nl'">
      <xsl:element name="tr">
        <xsl:attribute name="bgcolor">white</xsl:attribute>
        <xsl:call-template name="article_data"/>
      </xsl:element>
    </xsl:when>
    <xsl:when test="translation/reserved">
      <xsl:element name="tr">
        <xsl:attribute name="bgcolor">#AAAAFF</xsl:attribute>
        <xsl:call-template name="article_data"/>
      </xsl:element>
    </xsl:when>
    <xsl:otherwise>
      <tr bgcolor="#C2C2C2"><xsl:call-template name="article_data"/></tr>
    </xsl:otherwise>
  </xsl:choose>
</xsl:template>

<xsl:template name="article_data">
    <xsl:variable name="artid"><xsl:value-of select="@id"/></xsl:variable>
    <xsl:variable name="issueid"><xsl:value-of select="$englishdb/database/articles/article[@id=$artid]/issue/@href"/></xsl:variable>
    <td><xsl:value-of select="@id"/> (<xsl:value-of select="@xml:lang"/>)</td>
    <td>
      <xsl:choose>
        <xsl:when test="substring(@id,1,3)='cov'">
          <a href="../Nederlands/{$issueid}/index.html"><xsl:value-of select="title"/></a>
        </xsl:when>
        <xsl:when test="translation/finished">
          <a href="../Nederlands/{$issueid}/article{$artid}.shtml"><xsl:value-of select="title"/></a>
          (<a href="../Nederlands/{$issueid}/article{$artid}.meta.shtml">meta</a>)
        </xsl:when>
        <xsl:when test="@xml:lang='nl'">
          <a href="../Nederlands/{$issueid}/article{$artid}.shtml"><xsl:value-of select="title"/></a>
          (<a href="../Nederlands/{$issueid}/article{$artid}.meta.shtml">meta</a>)
        </xsl:when>
        <xsl:otherwise>
          <a href="../English/{$issueid}/article{$artid}.shtml"><xsl:value-of select="title"/></a>
          (<a href="../English/{$issueid}/article{$artid}.meta.shtml">meta</a>)
        </xsl:otherwise>
      </xsl:choose>
    </td>
    <td>
    <xsl:choose>
      <xsl:when test="translation/finished">
        <font color="black">
          <xsl:apply-templates select="translation/person"/>
        </font>
      </xsl:when>
      <xsl:when test="translation/reserved">
        <font color="black">
          <xsl:apply-templates select="translation/person"/>
        </font>
      </xsl:when>
      <xsl:otherwise>
      </xsl:otherwise>
    </xsl:choose>  
    </td>
    <td>
    <xsl:choose>
      <xsl:when test="translation/proofread/finished">
        <font color="black">
          <xsl:apply-templates select="translation/proofread/person"/>
        </font>
      </xsl:when>
      <xsl:when test="translation/proofread/reserved">
        <font color="black">
          <xsl:apply-templates select="translation/proofread/person"/>
        </font>
      </xsl:when>
      <xsl:otherwise>
        <font color="black">
          <xsl:apply-templates select="translation/proofread/person"/>
        </font>
      </xsl:otherwise>
    </xsl:choose>  
    </td>
</xsl:template>

<xsl:template match="person">
  <xsl:variable name="code"><xsl:value-of select="@href"/></xsl:variable>
  <xsl:value-of select="$persondb//person[@id=$code]/name"/>
</xsl:template>

</xsl:stylesheet>
