le 18/04/2006 01:35 Thorsten Scherler a écrit :
El lun, 17-04-2006 a las 23:32 +0100, Ross Gardler escribió:
...
The transformation to XHTML creates embedded CSS styles in the final output. Are these carried through to the final output?

http://localhost:8888/helloworld.xml

<document>
 <header>
  <title>Converted by odt_to_xhtml.xsl</title>
  <!--
<DEFANGED_meta content="text/html;charset=utf-8" http-equiv="Content-Type"/> -->
 <!-- <DEFANGED_STYLE type="text/css">
.T1{
font-weight: bold;
}
 --> </DEFANGED_STYLE>
</header>
 <body>
  <section>
   <title/>
   <div class="Standard">Hello World</div>
  </section>
 </body>
</document>

That is the outcome from the html-to-document.xsl (see above
{lm:transform.html.document}) transformation (last step in the odt
plugin).
The dispatcher ignores the  <!-- <DEFANGED_STYLE/> and as well skins from a 
xdoc, the
answer is *no*, embedded CSS styles in *xdocs* are *not* carried through
to the final output.

My question now is, do you think that we should suppress  <!-- 
<DEFANGED_STYLE/> in the
{lm:transform.html.document}?

May be we can keep the two possibilities with a good naming rule :

   * If the file is named **-ks.odt - meaning keep-styles then we keep
     the styles
   * Else we skip them.

<map:sitemap xmlns:map="http://apache.org/cocoon/sitemap/1.0";>
 <map:resources>
   <map:resource name="file-resolver">
     <map:select type="exists">
       <map:when test="{lm:project.{uri}.odt}">
         <map:generate src="zip://[EMAIL PROTECTED]:project.{uri}.odt}" />
         <map:transform src="{lm:transform.odt.xhtml}" />
         <map:transform src="{lm:transform.xml.xml-namespace-stripped}" />
         <map:transform src="{lm:transform.html.document}" />
         <map:serialize type="xml" />
       </map:when>
     </map:select>
   </map:resource>
   <map:resource name="file-resolver-keep-styles">
     <map:select type="exists">
       <map:when test="{lm:project.{uri}-ks.odt}">
         <map:generate src="zip://[EMAIL PROTECTED]:project.{uri}-ks.odt}" />
         <map:transform src="{lm:transform.odt.xhtml}" />
         <map:transform src="{lm:transform.xml.xml-namespace-stripped}" />
         <map:transform src="{lm:transform.html-keep-styles.document}" />
         <map:serialize type="xml" />
       </map:when>
     </map:select>
   </map:resource>
 </map:resources>

 <map:pipelines>
   <map:pipeline internal="true">
     <map:match pattern="**-ks.xml">
       <map:call resource="file-resolver-keep-styles">
         <map:parameter name="uri" value="{1}" />
       </map:call>
     </map:match>
   </map:pipeline>
   <map:pipeline internal="true">
     <map:match pattern="**.xml">
       <map:call resource="file-resolver">
         <map:parameter name="uri" value="{1}" />
       </map:call>
     </map:match>
   </map:pipeline>
   <map:pipeline />
 </map:pipelines>
salu2
Salutations,
Cyriaque,