maven-doxia-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From br...@apache.org
Subject svn commit: r391968 - in /maven/doxia/trunk: doxia-decoration-model/src/main/mdo/decoration.mdo doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm
Date Thu, 06 Apr 2006 11:19:37 GMT
Author: brett
Date: Thu Apr  6 04:19:34 2006
New Revision: 391968

URL: http://svn.apache.org/viewcvs?rev=391968&view=rev
Log:
[MSITE-94] make it possible to add an image to an item
Submitted by: Vincent Siveton

Modified:
    maven/doxia/trunk/doxia-decoration-model/src/main/mdo/decoration.mdo
    maven/doxia/trunk/doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm

Modified: maven/doxia/trunk/doxia-decoration-model/src/main/mdo/decoration.mdo
URL: http://svn.apache.org/viewcvs/maven/doxia/trunk/doxia-decoration-model/src/main/mdo/decoration.mdo?rev=391968&r1=391967&r2=391968&view=diff
==============================================================================
--- maven/doxia/trunk/doxia-decoration-model/src/main/mdo/decoration.mdo (original)
+++ maven/doxia/trunk/doxia-decoration-model/src/main/mdo/decoration.mdo Thu Apr  6 04:19:34
2006
@@ -330,6 +330,13 @@
           <type>String</type>
           <identifier>true</identifier>
         </field>
+        <field xml.attribute="true">
+          <name>img</name>
+          <description>Image href.</description>
+          <version>1.0.0</version>
+          <type>String</type>
+          <identifier>true</identifier>
+        </field>
         <field xml.listStyle="flat">
           <name>items</name>
           <description>Menu item.</description>

Modified: maven/doxia/trunk/doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm
URL: http://svn.apache.org/viewcvs/maven/doxia/trunk/doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm?rev=391968&r1=391967&r2=391968&view=diff
==============================================================================
--- maven/doxia/trunk/doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm
(original)
+++ maven/doxia/trunk/doxia-site-renderer/src/main/resources/org/apache/maven/doxia/siterenderer/resources/default-site.vm
Thu Apr  6 04:19:34 2006
@@ -97,6 +97,15 @@
     #end
   #end
   <li class="$collapse">
+    #if ( $item.img )
+      #if ( ! ( $item.img.toLowerCase().startsWith("http") || $item.img.toLowerCase().startsWith("https")
) )
+        #set ( $src = $PathTool.calculateLink( $item.img, $relativePath ) )
+        #set ( $src = $item.img.replaceAll( "\\", "/" ) )
+        <img src="$src"/>
+      #else
+        <img src="$item.img" align="absbottom" style="border-width: 0"/>
+      #end
+    #end
     #if ( $currentFileName == $currentItemHref )
       <strong><a href="$currentFileName">$item.name</a></strong>
     #else



Mime
View raw message