Hi Cristina, On Tue, May 19, 2009 at 1:18 PM, Cristina Scheau <scheau.cristina@gmail.com>wrote:
Hello!
For the XOO project, I would need a conversion module which has two components: 1. converter from the swriter html in pure html. 2. bidirectional converter wiki syntax - html.
Is this already done in the Office Importer project? If yes, I would be grateful if you tell me where can I find this components.
Yes, both of these components are already present: swriter html -> xhtml converter: http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-officeimporter/... (This is an xwiki component) xhtml -> xwiki 2.0 syntax: You must first use xhtml parser ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-rendering/xwiki...) and then xwiki/2.0 renderer ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-rendering/xwiki...). Note that renderers are obtained from PrintRendererFactory ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-rendering/xwiki... ) (All of these are plexus components) xwiki 2.0 syntax -> xhtml: Do the reverse of above, use xwiki 2.0 parser ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-rendering/xwiki...) and then xhtml renderer ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-rendering/xwiki...). Again xhtml renderer is obtained through PrintRendererFactory component. Please have a look at officeimporter code base to see how i have done these conversions: ( http://svn.xwiki.org/svnroot/xwiki/platform/core/trunk/xwiki-officeimporter/... ) I hope you are already familair with xwiki components. Let me know if you need more help in this regard. Thanks. - Asiri
Best regards, Cristina Scheau _______________________________________________ devs mailing list devs@xwiki.org http://lists.xwiki.org/mailman/listinfo/devs