There are several (very good) rich text web editors written in Javascript (eg FCKeditor, YUI Texteditor and many many others).
However I couldn't find any tutorial on how to build such a component. Something that would explain both high-level considerations (architecture) and/or more details in low-level "critical" points (ie why do most of the editors out there use iFrame, how do you handle keyboard input like Ctrl-B, Ctrl-C when the text is selected and when it is not etc)
My main motivation is curiosity; if I had to develop such an editor today I wouldn't know where to start from.
Does anyone know of any tutorial that covers the above issues (ideally, something that explains how to build a wysiwyg editor from scratch)?