retain selection when scrolling

Fixed overwriting the text when scrolling while in the middle of a
selection