repl_restart - initial implementation
see #191
replace cursor lock functions with on_text_command listener on ST3
fixes #182