Add Ctrl+Del/Ctrl+Backspace logic.
Fix BreakTest to return valid cursor pos in any case.
Fix bug in InternalMoveCaret that causes cursorPos to be set to negative value.
Fix: End key didn't move cursor to end if there's selected text.
Add edit/insert mode switching.
Remove redundant code.