That’s caused by the spell checking (Checking > Display Spelling). There is an issue when there are a lot of spelling errors in the text, it causes the text to wrap strangely. Basically, if there is a bunch of misspelled words with no correctly-spelled words in between, the words will not break on the spaces.
The easiest way to fix the problem is to correct the spelling of the words or turn off spell checking.