In the Find/Replace dialog, it is possible to enter newlines into the replacement text by hitting Ctrl+Return. Since the “Replace With” field shows only a single line, the user may not notice that the replacement text contains newlines (he might have hit Ctrl+Return accidentally or the newline could be left over from a previous replacement).
Possible solutions:
-
Prevent the user from entering newlines into the replacement text.
-
Adapt the height of the text field to the number of entered lines (but only up to a maximum number of lines).
-
Add a small icon to the text field when it contains multiple lines.