detect correct position for text when special chars present
Merge pull request #3 from codio/codio-4782-text-operation-fix

detect correct position for text when special chars present