You are viewing a plain text version of this content. The canonical link for it is here.
Posted to svn@forrest.apache.org by th...@apache.org on 2005/09/19 16:14:50 UTC

svn commit: r290164 - in /forrest/trunk/whiteboard/plugins: org.apache.forrest.plugin.internal.view/resources/views/ org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/

Author: thorsten
Date: Mon Sep 19 07:14:42 2005
New Revision: 290164

URL: http://svn.apache.org/viewcvs?rev=290164&view=rev
Log:
removed group/project logo and use a more generic logo approach. There is a dependency for  still in there but not to skinconf. Got rid of tabs in both view files and added new logos to pelt.fv

Added:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-logo.ft
Removed:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-grouplogo.ft
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-projectlogo.ft
Modified:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/default.fv
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/pelt.fv

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/default.fv
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/default.fv?rev=290164&r1=290163&r2=290164&view=diff
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/default.fv (original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/default.fv Mon Sep 19 07:14:42 2005
@@ -45,23 +45,23 @@
             </forrest:properties>
           </forrest:contract>
           <forrest:contract name="nav-main-sub">
-					  <forrest:properties contract="nav-main-sub">
-					    <forrest:property name="nav-main-sub" nugget="get.navigation">
-					      <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
-					    </forrest:property>
-					  </forrest:properties>
-					</forrest:contract>
+            <forrest:properties contract="nav-main-sub">
+              <forrest:property name="nav-main-sub" nugget="get.navigation">
+                <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
+              </forrest:property>
+            </forrest:properties>
+          </forrest:contract>
         </forrest:hook>
       </forrest:hook>
       <forrest:hook name="page">
         <forrest:hook name="leftbar">
           <forrest:contract name="nav-section">
-					  <forrest:properties contract="nav-section">
-					    <forrest:property name="nav-section" nugget="get.navigation">
-					      <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
-					    </forrest:property>
-					  </forrest:properties>
-					</forrest:contract>
+            <forrest:properties contract="nav-section">
+              <forrest:property name="nav-section" nugget="get.navigation">
+                <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
+              </forrest:property>
+            </forrest:properties>
+          </forrest:contract>
           <forrest:contract name="search-input"/>
         </forrest:hook>
 <!-- 

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/pelt.fv
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/pelt.fv?rev=290164&r1=290163&r2=290164&view=diff
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/pelt.fv (original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.view/resources/views/pelt.fv Mon Sep 19 07:14:42 2005
@@ -37,16 +37,16 @@
 
     <forrest:hook name="container">
       <forrest:contract name="branding-breadcrumbs">
-			  <forrest:properties contract="branding-breadcrumbs">
-			    <forrest:property name="branding-breadcrumbs">
-			      <trail>
-			        <link1 name="Apache Forrest" href="http://forrest.apache.org/"/>
-			        <link2 name="Plugins" href="http://forrest.apache.org/docs/plugins/"/>
-			        <link3 name="org.apache.forrest.plugin.output.viewHelper" href="http://forrest.apache.org/docs/plugins/org.apache.forrest.plugin.output.viewHelper/"/>
-			      </trail>
-			    </forrest:property>
-			  </forrest:properties>
-			</forrest:contract>
+        <forrest:properties contract="branding-breadcrumbs">
+          <forrest:property name="branding-breadcrumbs">
+            <trail>
+              <link1 name="Apache Forrest" href="http://forrest.apache.org/"/>
+              <link2 name="Plugins" href="http://forrest.apache.org/docs/plugins/"/>
+              <link3 name="org.apache.forrest.plugin.output.viewHelper" href="http://forrest.apache.org/docs/plugins/org.apache.forrest.plugin.output.viewHelper/"/>
+            </trail>
+          </forrest:property>
+        </forrest:properties>
+      </forrest:contract>
       <forrest:hook name="header">
         <forrest:contract name="branding-tagline">
           <forrest:properties contract="branding-tagline">
@@ -57,10 +57,32 @@
           </forrest:properties>
         </forrest:contract>
         <forrest:hook name="grouplogo">
-          <forrest:contract name="branding-grouplogo"/>
+          <forrest:contract name="branding-logo">
+            <forrest:properties contract="branding-logo">
+              <forrest:property name="branding-logo-name">
+                MyGroup</forrest:property>
+              <forrest:property name="branding-logo-description">MyGroup 
+                Description</forrest:property>
+              <forrest:property name="branding-logo-url">
+                http://mygroup.org/</forrest:property>
+              <forrest:property name="branding-logo-logo">
+                images/group.png</forrest:property>
+            </forrest:properties>
+          </forrest:contract>
         </forrest:hook>
         <forrest:hook name="projectlogo">
-          <forrest:contract name="branding-projectlogo"/>
+          <forrest:contract name="branding-logo">
+            <forrest:properties contract="branding-logo">
+              <forrest:property name="branding-logo-name">
+                MyProject</forrest:property>
+              <forrest:property name="branding-logo-description">MyProject 
+                Description</forrest:property>
+              <forrest:property name="branding-logo-url">
+                http://myproj.mygroup.org/</forrest:property>
+              <forrest:property name="branding-logo-logo">
+                images/project.png</forrest:property>
+            </forrest:properties>
+          </forrest:contract>
         </forrest:hook>
         <forrest:contract name="search-input">
           <forrest:properties contract="search-input">
@@ -77,36 +99,36 @@
           </forrest:contract>
           <forrest:hook name="publishedStrip">
             <forrest:contract name="nav-main-sub">
-						  <forrest:properties contract="nav-main-sub">
-						    <forrest:property name="nav-main-sub" nugget="get.navigation">
-						      <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
-						    </forrest:property>
-						  </forrest:properties>
-						</forrest:contract>
+              <forrest:properties contract="nav-main-sub">
+                <forrest:property name="nav-main-sub" nugget="get.navigation">
+                  <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
+                </forrest:property>
+              </forrest:properties>
+            </forrest:contract>
             <forrest:contract name="siteinfo-current-time"/>
           </forrest:hook>
         </forrest:hook>
       </forrest:hook>
       <forrest:hook name="page">
         <forrest:contract name="branding-breadcrumbs">
-				  <forrest:properties contract="branding-breadcrumbs">
-				    <forrest:property name="branding-breadcrumbs">
-				      <trail>
-				        <link1 name="Apache Forrest" href="http://forrest.apache.org/"/>
-				        <link2 name="Plugins" href="http://forrest.apache.org/docs/plugins/"/>
-				        <link3 name="org.apache.forrest.plugin.output.viewHelper" href="http://forrest.apache.org/docs/plugins/org.apache.forrest.plugin.output.viewHelper/"/>
-				      </trail>
-				    </forrest:property>
-				  </forrest:properties>
-				</forrest:contract>
+          <forrest:properties contract="branding-breadcrumbs">
+            <forrest:property name="branding-breadcrumbs">
+              <trail>
+                <link1 name="myGroup" href="http://www.apache.org/"/>
+                <link2 name="myProject" href="http://forrest.apache.org/"/>
+                <link3 name="" href=""/>
+              </trail>
+            </forrest:property>
+          </forrest:properties>
+        </forrest:contract>
         <forrest:hook name="leftbar">
           <forrest:contract name="nav-section">
-					  <forrest:properties contract="nav-section">
-					    <forrest:property name="nav-section" nugget="get.navigation">
-					      <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
-					    </forrest:property>
-					  </forrest:properties>
-					</forrest:contract>
+            <forrest:properties contract="nav-section">
+              <forrest:property name="nav-section" nugget="get.navigation">
+                <url>#{$cocoon/parameters/getRequest}.navigation.xml</url>
+              </forrest:property>
+            </forrest:properties>
+          </forrest:contract>
           <!-- FIXME - hr contract should disappear and be replaced by a top-separator contract argument just like
                        siteinfo-credits -->
           <forrest:contract name="hr"/>

Added: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-logo.ft
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-logo.ft?rev=290164&view=auto
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-logo.ft (added)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.viewHelper.xhtml/resources/templates/branding-logo.ft Mon Sep 19 07:14:42 2005
@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Copyright 2002-2005 The Apache Software Foundation or its licensors,
+  as applicable.
+
+  Licensed under the Apache License, Version 2.0 (the "License");
+  you may not use this file except in compliance with the License.
+  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+-->
+<forrest:contract name="branding-logo" type="nugget"
+  xmlns:forrest="http://apache.org/forrest/templates/1.0">
+  <description>
+    branding-logo will output the logo defined in the view.
+  </description>
+  <usage><![CDATA[<forrest:contract name="branding-logo">
+  <forrest:properties contract="branding-logo">
+    <forrest:property name="branding-logo-name">Apache Forrest</forrest:property>
+    <forrest:property name="branding-logo-description">Apache Forrest</forrest:property>
+    <forrest:property name="branding-logo-url">http://forrest.apache.org/</forrest:property>
+    <forrest:property name="branding-logo-logo">images/project-logo.gif</forrest:property>
+  </forrest:properties>
+</forrest:contract>]]></usage>
+  <forrest:template
+  xmlns:forrest="http://apache.org/forrest/templates/1.0"
+  format="xhtml" name="branding-logo" inputFormat="xsl" body="true" head="false">
+
+    <xsl:stylesheet version="1.1" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
+      <xsl:template name="branding-logo-body">
+        <xsl:param name="branding-logo-name"/>
+        <xsl:param name="branding-logo-description"/>
+        <xsl:param name="branding-logo-url"/>
+        <xsl:param name="branding-logo-logo"/>
+<xsl:comment>+
+    |start Logo
+    +</xsl:comment> 
+        <xsl:call-template name="renderlogo">
+          <xsl:with-param name="name" select="$branding-logo-name"/>
+          <xsl:with-param name="url" select="$branding-logo-url"/>
+          <xsl:with-param name="logo" select="$branding-logo-logo"/>
+          <xsl:with-param name="root" select="$root"/>
+          <xsl:with-param name="description" 
+            select="$branding-logo-description"/>
+        </xsl:call-template>
+<xsl:comment>+
+    |end group Logo
+    +</xsl:comment> 
+      </xsl:template>
+    </xsl:stylesheet>
+  </forrest:template>
+</forrest:contract>
\ No newline at end of file