Modal text editing engine