some refactoring to enable managing different types of content
undo/redo and save bug fixes
Merge pull request #12 from cymantic/master

Preparation for allowing editing of links and html content