A simple solution to work with manipulating text selection