Edit > Find & Replace
Search for: ^[ ]+|[ ]+$Replace with:Options: Regular expressions: ONClick "Replace All".In English, that pattern matches:
Beginning of textA space, zero or more times(Any character, zero or more times)A space, zero or more timesEnd of textThe replacement represents the text that matched the part in parentheses, or everything except the spaces at the end.

