View Full Version : Rich text editor
Benibur
09-10-2006, 09:01 AM
After iFrames, another quest : the rich text editor ! (private joke).
Ok, seriously, the question is simple : i would like to be able to edit rich text from my application.
Developping my own would be too long.
I found a post
http://www.laszlosystems.com/developers/community/forums/showthread.php?s=&threadid=5136
and an exemple :
http://sbshine.net/proj/richtext/
=> this component is perfect ! there is hope !
But does anyone know when this component will be added to the laszlo platform ?
Benibur
09-10-2006, 11:04 AM
Another idea would be to participate to the finalization of this component.
No one knows if the sources are available ??
nicko
09-10-2006, 11:14 AM
The Laszlo RTE is in the incubator at the moment. We also wanted to use a rich text editor in our Laszlo app, but will probably go to iframes way with an html web editor if that works out.
I think the feature set for the Laszlo editor is about as far as it will go due to so many problems with getting it to work. It used to have buttons for alignment but they were removed b/c of inconsistencies.
Benibur
09-10-2006, 11:33 AM
I see we are aiming the same target : editing rich text within laszlo.
At the moment I have identified 4 solution to explore :
1 - laszlo : it seems very difficult to developp such a component, if it was easy the laszlo mail would have found a solution... In my case what can be seen in the incubator should be enought for me, at least for a start.
2 - iframes : another solution, but not that easy. Work in progress here :
http://www.laszlosystems.com/developers/community/forums/showthread.php?s=&postid=23726#post23726
please participate if interested :-)
3 - legals : in the dhtml runtime managing iframes should be much easier than with flash (i tested, it definively easier ! )
4 - waiting for appolo : the futur flash/pdf/html plugin of adobe should bring all we need. But I am not patient enought...
If you find any other solution, your ideas are welcome :-)
benjamin
09-10-2006, 09:22 PM
Originally posted by Benibur
1 - laszlo : it seems very difficult to developp such a component, if it was easy the laszlo mail would have found a solution... In my case what can be seen in the incubator should be enought for me, at least for a start.
The source for the rich text editor as displayed in http://sbshine.net/proj/richtext/ is 100% available in the open-source platform. If the performance and feature set there is acceptable, then, poof, there's your solution. The rich text editor in Laszlo Mail is an extension of the incubator rich text editor.
The Flash player (as of swf7) is not a friendly platform for either building a text editor, or for fine-grained control of rich text through the TextFormat api. One of the fundamental problems comes down to this... users expect very rapid response on keypresses, especially sustained high-frequency keypresses. Microsoft Word is the de facto standard for how rich text formatting toolbars should work. Acting like the Word toolbar requires updating the display of the current text formatting each time the cursor moves. This in turn means we have to query flash for the text format at the current cursor position then update the state of a handful of formatting palette widgets without introducing *any* lag. On a low-end machine (say, an 867 Mhz PowerPC mac 512 mb of ram and flash player 7) it's just too much to get into the event loop between each keystroke. Lag accumulates. Type a long sentence fast, and you're waiting a couple hundred milliseconds to see the last letters appear on screen. This can really mess with the hand-eye coordination used by fast but error-prone typists.
All of this can be improved with clever optimizations, and could probably be improved a bit more by someone who knows the Open Laszlo internals really well. You've still got that fundamental problem of trying to keep up with fast typists on slow machines, and that's a game I can't win within these constraints.
HOWEVER, if you've got a higher baseline machine and you can rely on flash player 8, performance will be acceptable. EXCEPT that paragraph-level formatting in flash is a whole 'nother world of pain. Indeed, we took out alignment in Laszlo Mail because it was too hard to work around flash's idiosyncratic paragraph formatting behavior.
I don't have experience with the other options you list, so I can't comment on them.
-benjamin shine
software engineer
laszlo systems
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.