ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adammurd...@apache.org
Subject cvs commit: jakarta-ant-myrmidon/tools/xsl taskdoc-project.xsl taskdoc-summary.xsl taskdoc.xsl
Date Wed, 12 Jun 2002 07:08:31 GMT
adammurdoch    2002/06/12 00:08:31

  Modified:    tools/xsl taskdoc-project.xsl taskdoc-summary.xsl
                        taskdoc.xsl
  Log:
  Changes to type meta info -> xdoc transform:
  
  * Use role's display name in navigation bar, overview page, and role page.
  
  * Link to role page in navigation bar, rather than to the overview page.
  
  * Include a table on each role page, listing the (known) implementations.
  
  * Generate a page for each class used as nested elements.  Still needs
    some work.
  
  * For attributes, nested elements, and text content, include a link to the
    appropriate type (eg the nested element, or role, or whatever).  Doesn't
    understand special cases like ModelElement, File, etc yet.
  
  Revision  Changes    Path
  1.2       +4 -6      jakarta-ant-myrmidon/tools/xsl/taskdoc-project.xsl
  
  Index: taskdoc-project.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant-myrmidon/tools/xsl/taskdoc-project.xsl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- taskdoc-project.xsl	1 Jun 2002 06:59:53 -0000	1.1
  +++ taskdoc-project.xsl	12 Jun 2002 07:08:31 -0000	1.2
  @@ -1,8 +1,6 @@
   <!-- A stylesheet to tranform a typelib summary into an xdocs project file -->
   <xsl:stylesheet version="1.0"
  -                xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  -                xmlns:xalan="http://xml.apache.org/xalan"
  -               exclude-result-prefixes="xalan">
  +                xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
       <xsl:output indent="yes" omit-xml-declaration="yes"/>
   
       <xsl:template match="/types">
  @@ -11,9 +9,9 @@
               <body>
                   <menu name="Types">
                       <item name="All" href="/index.html"/>
  -                    <xsl:for-each select="xalan:distinct( type/@role )" >
  -                        <xsl:sort select="."/>
  -                        <item name="{.}" href="/index.html#{.}"/>
  +                    <xsl:for-each select="role" >
  +                        <xsl:sort select="normalize-space(display-name)"/>
  +                        <item name="{normalize-space(display-name)}" href="/{translate(@classname,
'.', '/')}.html"/>
                       </xsl:for-each>
                   </menu>
               </body>
  
  
  
  1.3       +5 -5      jakarta-ant-myrmidon/tools/xsl/taskdoc-summary.xsl
  
  Index: taskdoc-summary.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant-myrmidon/tools/xsl/taskdoc-summary.xsl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- taskdoc-summary.xsl	11 Jun 2002 11:56:37 -0000	1.2
  +++ taskdoc-summary.xsl	12 Jun 2002 07:08:31 -0000	1.3
  @@ -12,11 +12,11 @@
               </properties>
   
               <body>
  -                <xsl:for-each select="xalan:distinct( type/@role )" >
  -                    <xsl:sort select="."/>
  -                    <xsl:variable name="rolename" select="."/>
  -                    <section name="{$rolename}" anchor="{$rolename}">
  -                        <p><escaped><xsl:value-of select="/types/role[@name
= $rolename]/short-description"/></escaped></p>
  +                <xsl:for-each select="role" >
  +                    <xsl:sort select="normalize-space(display-name)"/>
  +                    <xsl:variable name="rolename" select="@name"/>
  +                    <section name="{normalize-space(display-name)}" anchor="{$rolename}">
  +                        <p><escaped><xsl:value-of select="short-description"/></escaped></p>
                           <table>
                               <tr><th>Name</th><th>Description</th></tr>
                               <xsl:for-each select="/types/type[@role = $rolename]">
  
  
  
  1.3       +43 -6     jakarta-ant-myrmidon/tools/xsl/taskdoc.xsl
  
  Index: taskdoc.xsl
  ===================================================================
  RCS file: /home/cvs/jakarta-ant-myrmidon/tools/xsl/taskdoc.xsl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- taskdoc.xsl	11 Jun 2002 11:56:37 -0000	1.2
  +++ taskdoc.xsl	12 Jun 2002 07:08:31 -0000	1.3
  @@ -3,10 +3,15 @@
                   xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
       <xsl:output indent="yes" omit-xml-declaration="yes"/>
   
  +    <xsl:param name="summaryurl"/>
  +    <xsl:variable name="summary" select="document( $summaryurl )/types"/>
  +
       <xsl:template match="/type">
           <!-- A type -->
           <xsl:variable name="typename">
  -            <xsl:value-of select="names/name[1]/@name"/>
  +            <xsl:for-each select="names/name[1]">
  +                <xsl:value-of select="@name"/>
  +            </xsl:for-each>
           </xsl:variable>
   
           <document>
  @@ -23,14 +28,34 @@
       </xsl:template>
   
       <xsl:template match="/role">
  +        <xsl:variable name="displayname" select="normalize-space(display-name)"/>
  +
           <!-- A role -->
           <document>
               <properties>
  -                <title><xsl:value-of select="@name"/></title>
  +                <title><xsl:value-of select="$displayname"/></title>
               </properties>
               <body>
  -                <section name="@name">
  +                <section name="{$displayname}">
                       <p><escaped><xsl:value-of select="long-description"/></escaped></p>
  +
  +                    <subsection name="Implementations">
  +                        <table>
  +                            <tr>
  +                                <th>Name</th>
  +                                <th>Description</th>
  +                            </tr>
  +
  +                            <xsl:for-each select="$summary/type[@role=current()/@name]">
  +                                <xsl:sort select="@name"/>
  +                                <tr>
  +                                    <td><a href="/{translate( @classname, '.',
'/' )}.html"><xsl:value-of select="@name"/></a></td>
  +                                    <td><escaped><xsl:value-of select="short-description"/></escaped></td>
  +                                </tr>
  +                            </xsl:for-each>
  +                        </table>
  +
  +                    </subsection>
                   </section>
               </body>
           </document>
  @@ -78,7 +103,11 @@
                   <tr>
                       <td><xsl:value-of select="@name"/></td>
                       <td><escaped><xsl:value-of select="description"/></escaped></td>
  -                    <td><code><xsl:value-of select="@type"/></code></td>
  +                    <td>
  +                        <a href="/{translate( @type, '.', '/' )}.html">
  +                            <code><xsl:value-of select="@type"/></code>
  +                        </a>
  +                    </td>
                   </tr>
               </xsl:for-each>
           </table>
  @@ -91,7 +120,11 @@
                   <tr>
                       <td><xsl:value-of select="@name"/></td>
                       <td><escaped><xsl:value-of select="description"/></escaped></td>
  -                    <td><code><xsl:value-of select="@type"/></code></td>
  +                    <td>
  +                        <a href="/{translate( @type, '.', '/' )}.html">
  +                            <code><xsl:value-of select="@type"/></code>
  +                        </a>
  +                    </td>
                   </tr>
               </xsl:for-each>
           </table>
  @@ -101,7 +134,11 @@
           <table>
               <tr>
                   <th>Type</th>
  -                <td><xsl:value-of select="@type"/></td>
  +                <td>
  +                    <a href="/{translate( @type, '.', '/' )}.html">
  +                        <code><xsl:value-of select="@type"/></code>
  +                    </a>
  +                </td>
               </tr>
               <tr>
                   <th>Description</th>
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message