Fixed bugs. Correct cutting of text