Use `count-words-region` instead of `count-lines-region`.