plonk all the editor code (much of it hidden) into Editor.lhs so we
can test it properly