Prevent Enter key from adding new line character in String expert

refers to bug 63301