Word selection enhancements

1. optimised for select/delete a word(symbol)
2. bug fixes