W3C home > Mailing lists > Public > public-html-commits@w3.org > August 2010

html5/spec-author-view/tools preprocess.xsl,NONE,1.1 postprocess.xsl,1.5,1.6

From: Michael Smith via cvs-syncmail <cvsmail@w3.org>
Date: Tue, 17 Aug 2010 09:52:50 +0000
To: public-html-commits@w3.org
Message-Id: <E1OlIqg-0003xb-Ta@lionel-hutz.w3.org>
Update of /sources/public/html5/spec-author-view/tools
In directory hutz:/tmp/cvs-serv15167/tools

Modified Files:
	postprocess.xsl 
Added Files:
	preprocess.xsl 
Log Message:
further index diddling


--- NEW FILE: preprocess.xsl ---
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  xmlns:h="http://www.w3.org/1999/xhtml"
  exclude-result-prefixes="h"
  version='1.0'>
  <xsl:param name="RCSREVISION"/>
  <xsl:output method="html" indent="no" encoding="ascii"
    doctype-public="-//W3C//DTD HTML 4.01//EN"
    />
  <xsl:template match="node() | @*">
    <xsl:copy>
      <xsl:apply-templates select="@* | node()"/>
    </xsl:copy>
  </xsl:template>
  <xsl:template match="style[1]">
    <xsl:text>&#10;</xsl:text>
    <link href="whatwg.css" rel="stylesheet"/>
    <xsl:text>&#10;</xsl:text>
    <xsl:copy-of select="."/>
    <xsl:text>&#10;</xsl:text>
  </xsl:template>
  <xsl:template match="style[contains(.,'.domintro:before')]"/>
  <xsl:template match="link[starts-with(@href,'http://www.w3.org/StyleSheets/TR/')][last()]">
    <xsl:copy-of select="."/>
    <xsl:text>&#10;</xsl:text>
    <link href="style.css" rel="stylesheet"/>
    <xsl:text>&#10;</xsl:text>
    <script src="link-fixup.js"></script>
    <xsl:text>&#10;</xsl:text>
  </xsl:template>
  <xsl:template match="h1">
    <h1>
      <xsl:text>HTML5 (Edition for Web Authors)</xsl:text>
      <span class="rcsrevision">
        <xsl:text> </xsl:text>
        <xsl:value-of select="concat('revision ',$RCSREVISION)"/>
      </span>
    </h1>
  </xsl:template>
  <xsl:template match="title">
    <title>HTML5 (Edition for Web Authors)</title>
  </xsl:template>
  <xsl:template match="a[normalize-space(.)='http://www.w3.org/TR/html5/']">
    <a href="http://www.w3.org/TR/html5/author/">http://www.w3.org/TR/html5/author/</a>
  </xsl:template>
  <xsl:template match="a[normalize-space(.)='http://dev.w3.org/html5/spec/Overview.html']">
    <a
      href="http://dev.w3.org/html5/spec-author-view/">http://dev.w3.org/html5/spec-author-view/</a>
  </xsl:template>
  <xsl:template match="a[starts-with(normalize-space(.),'http://www.w3.org/TR/2010/WD-html5-201')]
    [not(normalize-space(.)='http://www.w3.org/TR/2010/WD-html5-20100304/')]
    ">
    <xsl:variable name="href">
      <xsl:value-of select="concat(.,'author/')"/>
    </xsl:variable>
    <a href="{$href}"><xsl:value-of select="$href"/></a>
  </xsl:template>
  <xsl:template match="p[contains(normalize-space(.),'This specification is available in the following formats')]">
    <p>
      <xsl:text>This specification is available in the following formats: </xsl:text>
      <a href="spec.html">single page HTML</a>
      <xsl:text>, </xsl:text>
      <a href="Overview.html">multipage HTML</a>
      <xsl:text>, </xsl:text>
      <a href="http://dev.w3.org/html5/spec/">full specification</a>.
      <xsl:text>This is revision </xsl:text>
      <xsl:value-of select="$RCSREVISION"/>
      <xsl:text>.</xsl:text>
    </p>
  </xsl:template>
  <xsl:template match="h2[@id='abstract']">
    <xsl:copy-of select="."/>
    <xsl:text>&#10;</xsl:text>
    <p class="strong-note">This is a strict subset of the
      <a href="http://dev.w3.org/html5/spec/">HTML5 specification</a>
      that omits user-agent (UA) implementation details. It is
      targeted toward Web authors and others who are not UA
      implementors and who want a view of the HTML specification
      that focuses more precisely on details relevant to using the
      HTML language to create Web documents and Web applications.
      Because this document does not provide implementation
      conformance criteria, UA implementors should not rely on it,
      but should instead refer to the full specification.</p>
  </xsl:template>
  <xsl:template match="*[@id='references']" name="insert-index-of-terms">
    <xsl:text>&#10;</xsl:text>
    <h2 id="index-of-terms" class="no-num">Index of terms</h2>
    <xsl:text>&#10;</xsl:text>
    <xsl:comment>index-terms</xsl:comment>
    <xsl:text>&#10;</xsl:text>
    <xsl:copy-of select="."/>
    <xsl:text>&#10;</xsl:text>
  </xsl:template>
</xsl:stylesheet>

Index: postprocess.xsl
===================================================================
RCS file: /sources/public/html5/spec-author-view/tools/postprocess.xsl,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- postprocess.xsl	12 Jul 2010 06:34:50 -0000	1.5
+++ postprocess.xsl	17 Aug 2010 09:52:48 -0000	1.6
@@ -1,10 +1,8 @@
 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
   xmlns:h="http://www.w3.org/1999/xhtml"
-  xmlns:xi="http://www.w3.org/2001/XInclude"
-  exclude-result-prefixes="xi h"
+  exclude-result-prefixes="h"
   version='1.0'>
-  <xsl:param name="RCSREVISION"/>
-  <xsl:output method="html" indent="no" encoding="UTF-8"
+  <xsl:output method="html" indent="no" encoding="ascii"
     doctype-public="-//W3C//DTD HTML 4.01//EN"
     />
   <xsl:key name="local-frags" match="." use="concat('#',@id)"/>
@@ -14,83 +12,13 @@
       <xsl:apply-templates select="@* | node()"/>
     </xsl:copy>
   </xsl:template>
-  <xsl:template match="style[1]">
-    <xsl:text>&#10;</xsl:text>
-    <link href="whatwg.css" rel="stylesheet"/>
-    <xsl:text>&#10;</xsl:text>
-    <xsl:copy-of select="."/>
-    <xsl:text>&#10;</xsl:text>
-  </xsl:template>
-  <xsl:template match="style[contains(.,'.domintro:before')]"/>
-  <xsl:template match="link[starts-with(@href,'http://www.w3.org/StyleSheets/TR/')][last()]">
-    <xsl:copy-of select="."/>
-    <xsl:text>&#10;</xsl:text>
-    <link href="style.css" rel="stylesheet"/>
-    <xsl:text>&#10;</xsl:text>
-    <script src="link-fixup.js"></script>
-    <xsl:text>&#10;</xsl:text>
-  </xsl:template>
-  <xsl:template match="h1">
-    <h1>
-      <xsl:text>HTML5 (Edition for Web Authors)</xsl:text>
-      <span class="rcsrevision">
-        <xsl:text> </xsl:text>
-        <xsl:value-of select="concat('revision ',$RCSREVISION)"/>
-      </span>
-    </h1>
-  </xsl:template>
-  <xsl:template match="title">
-    <title>HTML5 (Edition for Web Authors)</title>
-  </xsl:template>
-  <xsl:template match="a[normalize-space(.)='http://www.w3.org/TR/html5/']">
-    <a href="http://www.w3.org/TR/html5/author/">http://www.w3.org/TR/html5/author/</a>
-  </xsl:template>
-  <xsl:template match="a[normalize-space(.)='http://dev.w3.org/html5/spec/Overview.html']">
-    <a
-      href="http://dev.w3.org/html5/spec-author-view/">http://dev.w3.org/html5/spec-author-view/</a>
-  </xsl:template>
-  <xsl:template match="a[starts-with(normalize-space(.),'http://www.w3.org/TR/2010/WD-html5-201')]
-    [not(normalize-space(.)='http://www.w3.org/TR/2010/WD-html5-20100304/')]
-    ">
-    <xsl:variable name="href">
-      <xsl:value-of select="concat(.,'author/')"/>
-    </xsl:variable>
-    <a href="{$href}"><xsl:value-of select="$href"/></a>
-  </xsl:template>
-  <xsl:template match="p[contains(normalize-space(.),'This specification is available in the following formats')]">
-    <p>
-      <xsl:text>This specification is available in the following formats: </xsl:text>
-      <a href="spec.html">single page HTML</a>
-      <xsl:text>, </xsl:text>
-      <a href="Overview.html">multipage HTML</a>
-      <xsl:text>, </xsl:text>
-      <a href="http://dev.w3.org/html5/spec/">full specification</a>.
-      <xsl:text>This is revision </xsl:text>
-      <xsl:value-of select="$RCSREVISION"/>
-      <xsl:text>.</xsl:text>
-    </p>
-  </xsl:template>
-  <xsl:template match="h2[@id='abstract']">
-    <xsl:copy-of select="."/>
-    <xsl:text>&#10;</xsl:text>
-    <p class="strong-note">This is a strict subset of the
-      <a href="http://dev.w3.org/html5/spec/">HTML5 specification</a>
-      that omits user-agent (UA) implementation details. It is
-      targeted toward Web authors and others who are not UA
-      implementors and who want a view of the HTML specification
-      that focuses more precisely on details relevant to using the
-      HTML language to create Web documents and Web applications.
-      Because this document does not provide implementation
-      conformance criteria, UA implementors should not rely on it,
-      but should instead refer to the full specification.</p>
-  </xsl:template>
   <xsl:template match="a[@href[starts-with(.,'#')]]">
     <xsl:variable name="ref" select="@href"/>
     <xsl:choose>
       <xsl:when test="not(key('local-frags',$ref))">
-        <xsl:message>
-          <xsl:value-of select="$ref"/>
-        </xsl:message>
+        <!-- * <xsl:message> -->
+          <!-- * <xsl:value-of select="$ref"/> -->
+        <!-- * </xsl:message> -->
         <xsl:variable name="filename">
           <xsl:call-template name="get-filename">
             <xsl:with-param name="ref" select="$ref"/>
Received on Tuesday, 17 August 2010 09:52:52 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:10:02 UTC