editor: remove new line characters from pasted text