Fixed a bug where cursor position would be incorrect when deleting text with delete and line wrapping changes