fixed highlighting when highlight ends in last line