some refactorings; began with editor
Merge branch 'master' of https://github.com/tector/ngm