EvView: Fix cursor movement when logical and visual line order differs
Make sure not to move the caret in the wrong direction when restoring the visual line X offset, in case the visual and logical order is slightly different.
Due to how restoring the X caret position is implemented (looking up the caret offset at the expected visual position), it can be restored on another line than the one it was on when visual and logical lines don't really match. So, make sure never to go back in the document trying to restore the X position.
Closes #889 (closed).