Correctly delete first line i RichTextBox

closes #324
Merge pull request #404 from Xharze/respectMaxLines

Correctly delete first line i RichTextBox