diff --git a/mu4e/mu4e-compose.el b/mu4e/mu4e-compose.el index ab79113a..12442033 100644 --- a/mu4e/mu4e-compose.el +++ b/mu4e/mu4e-compose.el @@ -397,9 +397,11 @@ set, this simply executes `fill-paragraph'." (if mu4e-compose-format-flowed (let ((fill-column (point-max)) (use-hard-newlines nil)); rfill "across" hard newlines - (delete-trailing-whitespace) + (when (use-region-p) + (delete-trailing-whitespace (region-beginning) (region-end))) (fill-paragraph nil region)) - (delete-trailing-whitespace) + (when (use-region-p) + (delete-trailing-whitespace (region-beginning) (region-end))) (fill-paragraph nil region))) (defun mu4e-toggle-use-hard-newlines ()