On Jan 17, 2009, at 2:46 PM, Marius Dumitru Florea wrote:
Hi Vincent,
I remember we talked about this when I started to work on the WYSIWYG.
Therefor I implemented the new editor having in mind that it should be
as much as possible independent of the storing syntax. The diagrams I
had attached to XWIKI-2497 show that:
* you can define a SyntaxValidator for a specific syntax (like
XWikiSyntaxValidator for xwiki/2.0) to disable/enable features in
particular contexts. This validator is loaded based on the syntax
configuration parameter. See editwysiwygnew.vm for:
var Wysiwyg0 = {
...
syntax: "$doc.syntaxId",
...
};
* each plugin has access to the configuration object and thus can
decide
based on the syntax parameter what to do. It can expose no features or
expose features based on the storing syntax. So you can put the bold
feature on the tool bar and the text plugin can associate a different
behavior based on the syntax.
All this is already implemented. Of course it needs to be improved.
But
anyone willing to customize the behavior of the editor based on the
storing syntax should be able to do it.
Great stuff! :)
So for me the question is: are we going to support
other syntaxes on
the
client side (custom WYSIWYG behavior) or just on the server side
(parser/renderer)? I guess the answer is: just on the server side for
the moment since the new editor is still not ready and it should work
perfectly with xwiki/2.0 syntax first.
Yep.
Re other syntaxes, I think it'll happen progressively depending on the
user demand and depending on contributions too. What we need to do
though is write some rendering tutorials to explain how to introduce
new syntaxes , new parsers, new macros and new renderers.
Thanks
-Vincent
Thanks,
Marius
Vincent Massol wrote:
> Hi,
>
> Just realized that our new WYSIWYG editor will only work fine with
> our
> xwiki 2.0 syntax since other wiki syntaxes are less powerful and
> won't
> be able to express some complex structures (like embedding a document
> inside a table cell) or simply like styling a portion of text.
>
> Of course this is not a problem of the wysiwyg editor per see but in
> practice it means that users using it for other syntaxes when they
> save will get a different rendered result.
>
> So I"m tempted to say that our GWT editor will only work for the
> xwiki
> 2.0 syntax and that for the other syntaxes users will have to use the
> wiki editor.
>
> WDYT?
>
> Thanks
> -Vincent
>