summaryrefslogtreecommitdiff
path: root/writerfilter/source/ooxml/todo.xsl
blob: 80431ea904873017aba1588ab1e9e7836d2f8f76 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?xml version="1.0" encoding="UTF-8"?>

<xsl:stylesheet version="1.0" 
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
	xmlns:rng="http://relaxng.org/ns/structure/1.0">

<xsl:output method="xml" indent="yes"/>

<xsl:template match="/">
    <todo>
    <xsl:for-each select="/stage3">
        <xsl:for-each select="attribute|element">
            <xsl:choose>
                <xsl:when test="@qname and @resource='Properties' and not(file)">
                    <xsl:copy-of select="."/>
                </xsl:when>
                <xsl:when test="@qname and file/status[number(@done) &lt; 100 and number(@planned) &gt; 0]">
                    <xsl:copy>
                        <xsl:copy-of select="@*"/>
                        <xsl:copy-of select="file[status[number(@done) &lt; 100 and number(@planned) &gt; 0]]"/>
                    </xsl:copy>
                </xsl:when>
            </xsl:choose>
        </xsl:for-each>
    </xsl:for-each>
    </todo>
</xsl:template>

</xsl:stylesheet>