Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

39 lines
1.7 KiB

  1. <?xml version="1.0"?>
  2. <!-- Copyright (c) Microsoft Corporation. All rights reserved. -->
  3. <!-- Generic stylesheet for viewing XML -->
  4. <xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">
  5. <!-- This template will always be executed, even if this stylesheet is not run on the document root -->
  6. <xsl:template>
  7. <DIV STYLE="font-family:Courier; font-size:10pt; margin-bottom:2em">
  8. <!-- Scoped templates are used so they don't interfere with the "kick-off" template. -->
  9. <xsl:apply-templates select=".">
  10. <xsl:template><xsl:apply-templates/></xsl:template>
  11. <xsl:template match="*">
  12. <DIV STYLE="margin-left:1em; color:gray">
  13. &lt;<xsl:node-name/><xsl:apply-templates select="@*"/>/&gt;
  14. </DIV>
  15. </xsl:template>
  16. <xsl:template match="*[node()]">
  17. <DIV STYLE="margin-left:1em">
  18. <SPAN STYLE="color:gray">&lt;<xsl:node-name/><xsl:apply-templates select="@*"/>&gt;</SPAN><xsl:apply-templates select="node()"/><SPAN STYLE="color:gray">&lt;/<xsl:node-name/>&gt;</SPAN>
  19. </DIV>
  20. </xsl:template>
  21. <xsl:template match="@*">
  22. <SPAN STYLE="color:navy"> <xsl:node-name/>="<SPAN STYLE="color:black"><xsl:value-of /></SPAN>"</SPAN>
  23. </xsl:template>
  24. <xsl:template match="pi()">
  25. <DIV STYLE="margin-left:1em; color:maroon">&lt;?<xsl:node-name/><xsl:apply-templates select="@*"/>?&gt;</DIV>
  26. </xsl:template>
  27. <xsl:template match="cdata()"><pre>&lt;![CDATA[<xsl:value-of />]]&gt;</pre></xsl:template>
  28. <xsl:template match="textNode()"><xsl:value-of /></xsl:template>
  29. </xsl:apply-templates>
  30. </DIV>
  31. </xsl:template>
  32. </xsl:stylesheet>