[fx][tb] editor: prevent inconsistency of text content by removing possible carriage return