(My first message didn't seem to go through, so I'm trying this again.)

Recently I've been working on WYSIWYG editing for the text cells of
Sage.  I've made an spkg for the TinyMCE javascript editor.  The idea is
that you can double-click on any text cell and, in-place, a TinyMCE
editor pops up that lets you edit HTML code in a familiar word-processor
sort of environment.  I think this will make editing text in a worksheet
*much* easier and more accessible.

Information for this program
----------------------------

Website: http://tinymce.moxiecode.com/

License: LGPL

Demo of TinyMCE: http://tinymce.moxiecode.com/examples/full.php (this 
includes a lot of plugins I don't plan on including because I think it's 
better to be simpler).

Trac tickets: #4255 and #4267

I've made an spkg for TinyMCE and relevant patches to enable its
functionality at http://trac.sagemath.org/sage_trac/ticket/4255. 
Unfortunately, it also is intertwined with spkgs and the patch up at 
4267, so to try it out, do the following:

    1. Apply the jeditable-tinymce.patch patch from #4255
    2. Apply the make-javascript-spkgs.patch patch at #4267
    3. Install all of the spkgs listed at #4267, except the 
jsmath-images spkg if you don't want.
    4. Optionally, apply the extcode patch at #4267, which deletes the 
packages from the extcode directory.

Then please read the instructions on the ticket to try this out;
creating text cells is still not completely obvious. I am working on 
making creating text cells easier soon. The patch makes it so that Sage 
checks to see if TinyMCE is installed before enabling the features, so 
it's not necessary that TinyMCE be a standard spkg.

Note that the jqueryui spkg at 4267 will change the default theme for 
interact sliders.  This is purely a cosmetic issue and can be reverted 
back to the theme we currently have.

The TinyMCE javascript editor is very actively developed.  TinyMCE has a 
nice plugin architecture and includes capabilities such as a WYSIWYG 
table editor, the standard formatting commands, a special 
paste-from-word feature that does a decent job of letting you paste 
directly from a word document into the html cell, etc.  It is very 
cross-platform and cross-browser (see
http://wiki.moxiecode.com/index.php/TinyMCE:Compatibility).  The main
competitor to TinyMCE is FCKEdit, and from what I've seen and
read, TinyMCE generates cleaner HTML code.  TinyMCE is the
standard editor bundled with Wordpress (popular blogging software), and
a list of CMS systems which either have a TinyMCE plugin or include it
in the software are listed at
http://wiki.moxiecode.com/index.php/TinyMCE:CMS_systems.

Another person's review of javascript editors is here:
http://www.garretwilson.com/blog/2008/07/27/javascriptxhtmleditors.xhtml,
which concludes that there is no perfect, or really even really good,
javascript editor, but TinyMCE is the best available.


The downside to using TinyMCE is that it adds another 150k or so to the
javascript downloads (using the plugins that I enabled in it).  However,
usually this is cached by the browser, so it is a one-time cost.  If we
ever figure out how to turn on the automatic gzip compression on twisted
connections, this downside will be dramatically reduced. Even with the
extra 150k, though, I feel that the usability benefits far outweigh the
costs.

So, do you vote

[ ] Yes, include TinyMCE as a standard package
[ ] Yes, include TinyMCE as an optional package
[ ] No, do not include TinyMCE as a package


I personally think that the most prudent choice now is to include it as
an optional package, merge the patch at #4255, and let a few people try
it out.  I hope to have easy text-cell creation done "real soon now",
which would enable people to just shift-click on the "add-new-cell" line
and get a new text cell with a TinyMCE edit box if it's installed.  I
would hope then that we could include TinyMCE in as a standard package.
  I think this would make sage notebooks much friendlier to people
wanting to annotate the mathematics with prose and explanation.

Of course, questions are welcome.


Thanks,

Jason


--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to