Click the Line button on the Search toolbar to turn on the “line by line” search option to search through each line separately, and to treat the entire line as the search match if part of it matches. This means that when this option is on, a search match can never span across multiple lines. Commands like Replace All and Copy Matches will replace or copy entire lines, even when the search term matches only part of the line.
Search|Prepare to Search
Search Option: Inverted Line by Line (Invert)