Added editor, and some small fixes