On 09/21/2012 01:42 AM, ray ye wrote:
Hi All,
Two WYSIWYG editors were included in XWiki -- tinyMCE and GWT-based.
I understand that
1. tinyMCE was used at the very beginning, and later GWT-based was
used to replace tinyMEC because tinyMCE was buggy, and its performance
was not good (at the time)
2. the version for tinyMCE included in XWiki 4.1.4 is 2.0.6.1 released
on 2006-05-04 ( I checked the code ), and the latest version is 3.5.7
release on 2012-09-20.
My questions are:
1. have any one revisit later release of tinyMCE, since lots have
changed over the 6 years?
Bugs and performance were not the only issues that led us to create a
new WYSIWYG; they're not even the most important ones.
TinyMCE is basically a HTML editor, while XWiki deals with wiki markup.
When the TinyMCE-based editor was developed, support for wiki markup was
added using a "theme" with several plugins. The gist of this theme was
regular expressions: run several regexps to convert wiki markup to HTML
and back.
This was acceptable because the early XWiki versions had just one syntax
(xwiki/1.0), which was fairly simple. Still, there were two different
implementations for the wiki rendering engine, one in Java and one in
JavaScript, and any code duplication is bad. The syntax was tightened
over time, using regexp features present only in Java (positive and
negative look arounds, greedy operators), so the WYSIWYG didn't
implement exactly the same syntax...
Another problem is that XWiki has support not just for basic wiki markup
(bold, italic, links, headers...), but also for complex macros, and
macros can't be implemented using just regular expressions.
And now XWiki knows more than one wiki syntax, so maintaining several
syntaxes in two very different places is definitely not something we'd
want to do.
We could consider upgrading to a more recent version of TinyMCE, but the
problem is that we've customized the sources so much that such an
upgrade would take a lot of time, and for something that's not going to
be that useful. We decided a long time ago that having our own editor is
the way to go.
2. for the GWT-based WYSIWYG solution, is it
developed by XWiki? and
is there a way that i can get WYSIWYG related codes only, and
integrate it into one of our internal project?
Marius already answered this question, I'll just add that the WYSIWYG
editor works best combined with the XWiki rendering engine, which can be
integrated in any project, since it has no dependencies on the XWiki
platform. See
http://rendering.xwiki.org/ for more details.
Thank you very much!
--
Sergiu Dumitriu
http://purl.org/net/sergiu/