Preserve caret position

Good for looong files :)