forrest-svn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thors...@apache.org
Subject svn commit: r331578 - in /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer: output.xmap resources.xmap
Date Mon, 07 Nov 2005 19:06:20 GMT
Author: thorsten
Date: Mon Nov  7 11:06:15 2005
New Revision: 331578

URL: http://svn.apache.org/viewcvs?rev=331578&view=rev
Log:
Activated the hex-round corner images generating and the matching for the new image locations.
One big part that is still missing is the common svg2png generating pipes

Modified:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/output.xmap
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/resources.xmap

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/output.xmap
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/output.xmap?rev=331578&r1=331577&r2=331578&view=diff
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/output.xmap (original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/output.xmap Mon
Nov  7 11:06:15 2005
@@ -32,16 +32,19 @@
         src="org.apache.cocoon.generation.HTMLGenerator">
         <jtidy-config>jtidy.properties</jtidy-config>
       </map:generator>
-      
+      <map:generator name="text"
+        src="org.apache.cocoon.generation.TextGenerator">
+        <parameter name="localizable" value="true" />
+      </map:generator>
       <map:generator name="directory"
         src="org.apache.cocoon.generation.DirectoryGenerator" />
-        <!-- <map:generator name="structurerXsl"
+      <!-- <map:generator name="structurerXsl"
         src="org.apache.forrest.structurer.generation.StructurerXSLGenerator" /> -->
     </map:generators>
     <map:transformers default="xslt">
       <map:transformer name="cinclude"
         src="org.apache.cocoon.transformation.CIncludeTransformer" />
-      
+
       <map:transformer name="i18n"
         src="org.apache.cocoon.transformation.I18nTransformer">
         <catalogues default="contracts">
@@ -70,40 +73,96 @@
       <map:serializer name="txt"
         src="org.apache.cocoon.serialization.TextSerializer"
         mime-type="text/plain" logger="sitemap.serializer.text" />
+      <map:serializer mime-type="image/png" name="svg2png"
+        src="org.apache.cocoon.serialization.SVGSerializer">
+        <!--<parameter name="background_color" type="color" value="#ff00ff"/>-->
+        <!-- <parameter name="gamma" type="float" value="0.48"/> -->
+        <parameter name="gamma" type="float" value="0" />
+      </map:serializer>
     </map:serializers>
   </map:components>
-    
+  <map:resources>
+    <map:resource name="read-linked-text">
+      <map:generate type="text" src="{path}" />
+      <map:transform type="pattern"
+        src="{forrest:context}/resources/chaperon/grammars/link.xlex" />
+      <map:transform
+        src="{forrest:context}/resources/chaperon/stylesheets/pattern2link.xsl" />
+      <map:serialize type="text" mime-type="text/css" />
+    </map:resource>
+  </map:resources>
   <map:pipelines>
     <map:pipeline>
       <map:match pattern="test.**">
         <map:generate src="status.xml" />
         <!-- <map:generate src="{lm:structurer.html.{1}}" type="structurerXsl"/>
-->
         <map:transform src="resources/stylesheets/temp.xsl">
-          <map:parameter name="test"
-            value="{lm:themes/{1}.js}" />
+          <map:parameter name="test" value="{lm:themes/images/{1}.gif}" />
         </map:transform>
-        
+
         <map:serialize />
       </map:match>
     </map:pipeline>
-      <!-- DO NOT USE ANYMORE
-        FIXME: Finish rewriting move to lm ->  {lm:contract.{1}.{2}}del if finished-->
+    <!-- DO NOT USE ANYMORE
+      FIXME: Finish rewriting move to lm ->  {lm:contract.{1}.{2}}del if finished-->
     <!--FIXME:START-->
-    
+
     <map:pipeline>
       <!--
         Last processing step. 
         Here we are overriding the default skin generation.
       -->
-      
+
       <map:match pattern="themes/**.css">
-         <map:read mime-type="text/css" src="{lm:themes/{1}.css}" />
+        <map:call resource="read-linked-text">
+          <map:parameter name="path" value="{lm:themes/{1}.css}" />
+        </map:call>
+        <!-- <map:read mime-type="text/css" src="{lm:themes/{1}.css}" /> -->
       </map:match>
-      
+
       <map:match pattern="themes/**.js">
-         <map:read mime-type="application/x-javascript" src="{lm:themes/{1}.js}" />
+        <map:read mime-type="application/x-javascript"
+          src="{lm:themes/{1}.js}" />
+      </map:match>
+
+      <map:match
+        pattern="themes/images**/roundcorner-*-*-*-bg*-stroke*-fg*.svg">
+        <map:generate src="status.xml" />
+        <map:transform
+          src="resources/stylesheets/round-corner-hex.svg.xslt">
+          <map:parameter name="orientation-tb" value="{2}" />
+          <map:parameter name="orientation-lr" value="{3}" />
+          <map:parameter name="size" value="{4}" />
+          <map:parameter name="bg-color-name" value="{5}" />
+          <map:parameter name="stroke-color-name" value="{6}" />
+          <map:parameter name="fg-color-name" value="{7}" />
+        </map:transform>
+        <map:serialize type="xml" />
+      </map:match>
+      <map:match
+        pattern="themes/images**/roundcorner-*-*-*-bg*-stroke*-fg*.svg-to-png">
+        <map:generate
+          src="cocoon:/themes/images{1}/roundcorner-{2}-{3}-{4}-bg{5}-stroke{6}-fg{7}.svg"
/>
+        <map:serialize type="svg2png" />
+      </map:match>
+      <map:match
+        pattern="themes/images**/roundcorner-*-*-*-bg*-stroke*-fg*.png">
+        <map:read
+          src="cocoon:/themes/images{1}/roundcorner-{2}-{3}-{4}-bg{5}-stroke{6}-fg{7}.svg-to-png"
+          mime-type="image/png" />
+      </map:match>
+      <map:match pattern="themes/images/**.*">
+        <map:match type="regexp"
+          pattern="(.*\.)(jpg|JPG|Jpg|jpeg|Jpeg|JPEG)$">
+          <map:read src="{lm:{1}{2}}" mime-type="image/jpeg" />
+        </map:match>
+        <map:match type="regexp" pattern="(.*)(gif|GIF|Gif)$">
+          <map:read src="{lm:{1}{2}}" mime-type="image/gif" />
+        </map:match>
+        <map:match type="regexp" pattern="(.*)(png|PNG|Png)$">
+          <map:read src="{lm:{1}{2}}" mime-type="image/png" />
+        </map:match>
       </map:match>
-      
       <map:match pattern="**.js">
         <map:mount uri-prefix="" src="resources.xmap"
           check-reload="yes" />
@@ -112,10 +171,10 @@
         <map:mount uri-prefix="" src="resources.xmap"
           check-reload="yes" />
       </map:match>
-      <map:match pattern="**images**">
+      <!--       <map:match pattern="**images**">
         <map:mount uri-prefix="" src="resources.xmap"
-          check-reload="yes" />
-      </map:match>
+        check-reload="yes" />
+        </map:match>-->
       <map:match pattern="**.png">
         <map:mount uri-prefix="" src="resources.xmap"
           check-reload="yes" />

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/resources.xmap
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/resources.xmap?rev=331578&r1=331577&r2=331578&view=diff
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/resources.xmap
(original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.output.themer/resources.xmap
Mon Nov  7 11:06:15 2005
@@ -296,7 +296,7 @@
             </map:call>
          </map:match>
          <!-- special case corner generator pipeline -->
-         <map:match pattern="themes/images**/*c-*-*-*-1*-2*-3*.png">
+         <!--<map:match pattern="themes/images**/*c-*-*-*-1*-2*-3*.png">
             <map:call resource="read-svg2png-corner-resource">
                <map:parameter name="path" value="images/{1}" />
                <map:parameter name="name" value="{2}c" />
@@ -307,7 +307,9 @@
                <map:parameter name="stroke-color-name" value="{7}"/>
                <map:parameter name="fg-color-name" value="{8}"/>    
             </map:call>
-         </map:match>
+         </map:match>-->
+         <!-- special case corner generator pipeline -->
+         
          <map:match pattern="skin/images**/*.*">
             <map:call resource="skin-read">
                <map:parameter name="path" value="images/{1}" />



Mime
View raw message