The TrimRight command removes trailing whitespace from the selected text.
Note that:
is equivalent to:
The following expansion:
replaces the selected text with its version without trailing whitespace.