Moved remaining text editor specific code from BaseEditor to TextEditor
If 'editor' property is a function (editor class) it is automatically registered, so that it can be a singleton.
First draft of customEditor tutorial.