brett 2004/07/13 05:18:59 Modified: xdoc plugin.properties project.xml xdoc/src/plugin-resources site.jsl xdoc/src/plugin-resources/css maven-base.css maven-classic.css maven-theme.css xdoc/xdocs changes.xml properties.xml Log: add a legend to the left nav Revision Changes Path 1.21 +2 -0 maven-plugins/xdoc/plugin.properties Index: plugin.properties =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/plugin.properties,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- plugin.properties 5 May 2004 07:38:30 -0000 1.20 +++ plugin.properties 13 Jul 2004 12:18:59 -0000 1.21 @@ -27,6 +27,8 @@ maven.xdoc.theme.url= maven.xdoc.theme=theme +maven.xdoc.legend=true + # Location where the artifacts are distributed. This property is optional. # If it is not defined, then the Download report will not be added to the # navigation menu. 1.60 +1 -1 maven-plugins/xdoc/project.xml Index: project.xml =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/project.xml,v retrieving revision 1.59 retrieving revision 1.60 diff -u -r1.59 -r1.60 --- project.xml 11 Jul 2004 02:20:19 -0000 1.59 +++ project.xml 13 Jul 2004 12:18:59 -0000 1.60 @@ -23,7 +23,7 @@ <pomVersion>3</pomVersion> <id>maven-xdoc-plugin</id> <name>Maven XDoc Plug-in</name> - <currentVersion>1.8</currentVersion> + <currentVersion>1.9-SNAPSHOT</currentVersion> <description>Convert xdocs into HTML. Requires Maven 1.0 RC2.</description> <shortDescription>Convert xdocs into HTML</shortDescription> <url>http://maven.apache.org/reference/plugins/xdoc/</url> 1.60 +99 -94 maven-plugins/xdoc/src/plugin-resources/site.jsl Index: site.jsl =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/src/plugin-resources/site.jsl,v retrieving revision 1.59 retrieving revision 1.60 diff -u -r1.59 -r1.60 --- site.jsl 13 Jun 2004 01:58:31 -0000 1.59 +++ site.jsl 13 Jul 2004 12:18:59 -0000 1.60 @@ -33,12 +33,12 @@ trim="true"> <jsl:template match="document" trim="true"> <j:useBean var="navbean" class="org.apache.maven.NavBean"/> - <j:set var="location" value="${outFile.substring(destdir.length())}"/> - <util:replace var="location" oldChar="\" newChar="/" value="${location}"/> + <j:set var="location" value="${outFile.substring(destdir.length())}"/> + <util:replace var="location" oldChar="\" newChar="/" value="${location}"/> <!-- Stores location for publish date / version --> <j:set var="date">${maven.xdoc.date}</j:set> - <j:setProperties object="${navbean}" document="${doc}" location="${location}"/> - + <j:setProperties object="${navbean}" document="${doc}" location="${location}"/> + <x:doctype name="html" publicId="-//W3C//DTD XHTML 1.0 Transitional//EN" systemId="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/> <html> <head> @@ -56,15 +56,15 @@ <style type="text/css" media="all"><![CDATA[ @import url("${relativePath}/style/maven-base.css"); ]]> - <j:if test="${!empty(themeUrl)}"><![CDATA[ - @import url("${maven.xdoc.theme.url}"); - ]]></j:if> - <j:if test="${empty(themeUrl)}"><![CDATA[ - @import url("${relativePath}/style/maven-${maven.xdoc.theme}.css"); - ]]></j:if> - <j:if test="${projectCssFile.exists()}"><![CDATA[ - @import url("${relativePath}/style/project.css"); - ]]></j:if> + <j:if test="${!empty(themeUrl)}"><![CDATA[ + @import url("${maven.xdoc.theme.url}"); + ]]></j:if> + <j:if test="${empty(themeUrl)}"><![CDATA[ + @import url("${relativePath}/style/maven-${maven.xdoc.theme}.css"); + ]]></j:if> + <j:if test="${projectCssFile.exists()}"><![CDATA[ + @import url("${relativePath}/style/project.css"); + ]]></j:if> </style> <link rel="stylesheet" type="text/css" href="${relativePath}/style/print.css" media="print"/> @@ -86,67 +86,67 @@ </j:whitespace> <div id="banner"> - <!-- organization logo --> - <j:set var="logo" value="${pom.organization.logo}"/> - <j:if test="${!empty(logo)}"> - <!-- set url to org or project url --> - <j:set var="url" value="${pom.organization.url}"/> - <j:if test="${!empty(url)}"> - <j:set var="home" value="${pom.organization.url}"/> - </j:if> - <j:if test="${empty(url)}"> - <j:set var="home" value="${pom.url}"/> - </j:if> - <!-- set image to relative or complete --> - <j:set var="image" value="${pom.organization.logo}"/> - <j:if test="${!image.startsWith('http://') and !image.startsWith('https://')}"> - <j:set var="image" value="${relativePath}${image}"/> - </j:if> - <a href="${home}" id="organizationLogo"> - <img src="${image}" alt="${pom.organization.name}" /> - </a> - </j:if> + <!-- organization logo --> + <j:set var="logo" value="${pom.organization.logo}"/> + <j:if test="${!empty(logo)}"> + <!-- set url to org or project url --> + <j:set var="url" value="${pom.organization.url}"/> + <j:if test="${!empty(url)}"> + <j:set var="home" value="${pom.organization.url}"/> + </j:if> + <j:if test="${empty(url)}"> + <j:set var="home" value="${pom.url}"/> + </j:if> + <!-- set image to relative or complete --> + <j:set var="image" value="${pom.organization.logo}"/> + <j:if test="${!image.startsWith('http://') and !image.startsWith('https://')}"> + <j:set var="image" value="${relativePath}${image}"/> + </j:if> + <a href="${home}" id="organizationLogo"> + <img src="${image}" alt="${pom.organization.name}" /> + </a> + </j:if> - <!-- project logo and link --> - <j:set var="logo" value="${pom.logo}"/> - <j:if test="${logo != null and logo != ''}"> - <!-- set image to relative or complete --> - <j:set var="image" value="${pom.logo}"/> - <j:if test="${!image.startsWith('http://') and !image.startsWith('https://')}"> - <j:set var="image" value="${relativePath}${image}"/> - </j:if> - - <a href="${pom.url}" id="projectLogo"> - <img src="${image}" alt="${pom.name}"/> - </a> - </j:if> - <j:if test="${logo == null or logo == ''}"> - <a href="${pom.url}" id="projectLogo"> - <span>${pom.name}</span> - </a> - </j:if> - <div class="clear"><hr /></div> + <!-- project logo and link --> + <j:set var="logo" value="${pom.logo}"/> + <j:if test="${logo != null and logo != ''}"> + <!-- set image to relative or complete --> + <j:set var="image" value="${pom.logo}"/> + <j:if test="${!image.startsWith('http://') and !image.startsWith('https://')}"> + <j:set var="image" value="${relativePath}${image}"/> + </j:if> + + <a href="${pom.url}" id="projectLogo"> + <img src="${image}" alt="${pom.name}"/> + </a> + </j:if> + <j:if test="${logo == null or logo == ''}"> + <a href="${pom.url}" id="projectLogo"> + <span>${pom.name}</span> + </a> + </j:if> + <div class="clear"><hr /></div> </div> <div id="breadcrumbs"> - <j:if test="${date == 'left'}"> - <maven:property var="version" name="maven.xdoc.version" defaultValue="${pom.currentVersion}"/> - <div class="xleft"> - Last published: ${build.date} - <j:if test="${!empty(version)}">| Doc for ${version}</j:if> - </div> - </j:if> - <div class="xright"> - <j:if test="${date == 'right'}"> - Last published: ${build.date} - <x:if select="$nav/body/links">|</x:if> - </j:if> - <!-- render links --> - <x:if select="$nav/body/links"> - <jsl:applyTemplates select="$nav/body/links"/> - </x:if> - </div> - <div class="clear"><hr /></div> + <j:if test="${date == 'left'}"> + <maven:property var="version" name="maven.xdoc.version" defaultValue="${pom.currentVersion}"/> + <div class="xleft"> + Last published: ${build.date} + <j:if test="${!empty(version)}">| Doc for ${version}</j:if> + </div> + </j:if> + <div class="xright"> + <j:if test="${date == 'right'}"> + Last published: ${build.date} + <x:if select="$nav/body/links">|</x:if> + </j:if> + <!-- render links --> + <x:if select="$nav/body/links"> + <jsl:applyTemplates select="$nav/body/links"/> + </x:if> + </div> + <div class="clear"><hr /></div> </div> <!-- left column start --> @@ -163,6 +163,15 @@ <x:if select="$nav"> <jsl:applyTemplates select="$nav/body/[EMAIL PROTECTED]'footer']"/> </x:if> + <j:if test="${context.getVariable('maven.xdoc.legend') == 'true'}"> + <div id="legend"> + <h5>Legend</h5> + <ul> + <li class="externalLink">External Link</li> + <li class="newWindow">Opens in a new window</li> + </ul> + </div> + </j:if> <!-- Standard Maven Navigation --> <j:set var="fileName">${file}</j:set> <j:set var="poweredbyimage">${maven.xdoc.poweredby.image}</j:set> @@ -177,24 +186,23 @@ <div id="lastPublished">Last published: ${build.date}</div> </j:if> </div> - </div> - <!-- left column end --> + </div> + <!-- left column end --> - <!-- body start --> - <div id="bodyColumn"> - <div class="contentBox"> - <!-- FIXME really shouldn't use $doc, but jelly loses it's context again --> - <jsl:applyTemplates select="$doc/document/body/section"/> - <jsl:applyTemplates select="$doc/document/body/release" /> - <jsl:applyTemplates select="$doc/document/body/goals" /> - </div> - </div> - <div class="clear"><hr /></div> - <!-- body end --> - + <!-- body start --> + <div id="bodyColumn"> + <div class="contentBox"> + <!-- FIXME really shouldn't use $doc, but jelly loses it's context again --> + <jsl:applyTemplates select="$doc/document/body/section"/> + <jsl:applyTemplates select="$doc/document/body/release" /> + <jsl:applyTemplates select="$doc/document/body/goals" /> + </div> + </div> + <div class="clear"><hr /></div> + <!-- body end --> - <!-- footer start --> - <div id="footer"> + <!-- footer start --> + <div id="footer"> <jsl:applyTemplates select="$nav/body/footer"/> <div class="xright"> <j:if test="${!empty(pom.organization.name)}"> @@ -217,8 +225,6 @@ <div class="clear"><hr /></div> </div> <!-- footer end --> - - </x:element> </html> </jsl:template> @@ -245,7 +251,6 @@ </div> </j:otherwise> </j:choose> - </jsl:template> <jsl:template match="item" trim="true"> @@ -456,14 +461,14 @@ <j:set var="href" value="${attr.value}" /> <j:choose> <j:when test="${href.startsWith('#')}"> - <x:attribute name="href"> - <doc:escapeNameToken value="${href}"/> - </x:attribute> + <x:attribute name="href"> + <doc:escapeNameToken value="${href}"/> + </x:attribute> </j:when> <j:when test="${href.startsWith('http://')}"> <x:attribute name="href">${href}</x:attribute> - <x:attribute name="class">externalLink</x:attribute> - <x:attribute name="title">External Link</x:attribute> + <x:attribute name="class">externalLink</x:attribute> + <x:attribute name="title">External Link</x:attribute> </j:when> <j:otherwise> <x:attribute name="href">${href}</x:attribute> 1.8 +3 -0 maven-plugins/xdoc/src/plugin-resources/css/maven-base.css Index: maven-base.css =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/src/plugin-resources/css/maven-base.css,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- maven-base.css 10 Apr 2004 03:26:40 -0000 1.7 +++ maven-base.css 13 Jul 2004 12:18:59 -0000 1.8 @@ -62,6 +62,9 @@ #bodyColumn { margin-left: 20%; } +#legend { + padding: 8px 0 8px 0; +} #navcolumn { padding: 8px 4px 0 8px; } 1.4 +10 -2 maven-plugins/xdoc/src/plugin-resources/css/maven-classic.css Index: maven-classic.css =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/src/plugin-resources/css/maven-classic.css,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- maven-classic.css 18 May 2004 09:23:28 -0000 1.3 +++ maven-classic.css 13 Jul 2004 12:18:59 -0000 1.4 @@ -96,11 +96,19 @@ color: @UI_HREF_LINK_SELFREF@ !important; } +#legend li.externalLink { + background: url(../images/external-classic.png) left top no-repeat; + padding-left: 18px; +} a.externalLink, a.externalLink:link, a.externalLink:visited, a.externalLink:active, a.externalLink:hover { background: url(../images/external-classic.png) right center no-repeat; - padding-right: 15px; + padding-right: 18px; } +#legend li.newWindow { + background: url(../images/newwindow-classic.png) left top no-repeat; + padding-left: 18px; +} a.newWindow, a.newWindow:link, a.newWindow:visited, a.newWindow:active, a.newWindow:hover { background: url(../images/newwindow-classic.png) right center no-repeat; padding-right: 18px; 1.7 +9 -1 maven-plugins/xdoc/src/plugin-resources/css/maven-theme.css Index: maven-theme.css =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/src/plugin-resources/css/maven-theme.css,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- maven-theme.css 18 May 2004 09:23:28 -0000 1.6 +++ maven-theme.css 13 Jul 2004 12:18:59 -0000 1.7 @@ -14,9 +14,17 @@ a:active, a:hover { color:#69c; } +#legend li.externalLink { + background: url(../images/external.png) left top no-repeat; + padding-left: 18px; +} a.externalLink, a.externalLink:link, a.externalLink:visited, a.externalLink:active, a.externalLink:hover { background: url(../images/external.png) right center no-repeat; - padding-right: 15px; + padding-right: 18px; +} +#legend li.newWindow { + background: url(../images/newwindow.png) left top no-repeat; + padding-left: 18px; } a.newWindow, a.newWindow:link, a.newWindow:visited, a.newWindow:active, a.newWindow:hover { background: url(../images/newwindow.png) right center no-repeat; 1.61 +3 -0 maven-plugins/xdoc/xdocs/changes.xml Index: changes.xml =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/xdocs/changes.xml,v retrieving revision 1.60 retrieving revision 1.61 diff -u -r1.60 -r1.61 --- changes.xml 11 Jul 2004 02:20:19 -0000 1.60 +++ changes.xml 13 Jul 2004 12:18:59 -0000 1.61 @@ -25,6 +25,9 @@ <author email="[EMAIL PROTECTED]">Vincent Massol</author> </properties> <body> + <release version="1.9-SNAPSHOT" date="in CVS"> + <action dev="brett" type="add">Add a legend for the symbols in the xdoc, disabled by setting <code>maven.xdoc.legend=false</code></action> + </release> <release version="1.8" date="2004-07-10"> <action dev="brett" type="add">Add an externalLink attribute to a report to use if link is not present</action> <action dev="vmassol" type="add">Added a link to the release notes in the download report. Note that this link is only created if the project has a 1.14 +7 -0 maven-plugins/xdoc/xdocs/properties.xml Index: properties.xml =================================================================== RCS file: /home/cvs/maven-plugins/xdoc/xdocs/properties.xml,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- properties.xml 11 Jul 2004 00:57:59 -0000 1.13 +++ properties.xml 13 Jul 2004 12:18:59 -0000 1.14 @@ -154,6 +154,13 @@ </td> </tr> <tr> + <td>maven.xdoc.legend</td> + <td>Yes</td> + <td> + Whether to display the legend in the left navigation. Default is <code>true</code>. + </td> + </tr> + <tr> <td>maven.xdoc.poweredby.image</td> <td>Yes</td> <td>
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]