"Automatically highlight changes in detail as the user visits hunks.
When transitioning from disabled to enabled,
try to refine the current hunk, as well."
- :group 'diff-mode :init-value t :lighter " Auto-Refine"
+ :group 'diff-mode :init-value t :lighter nil ;; " Auto-Refine"
(when diff-auto-refine-mode
(condition-case-no-debug nil (diff-refine-hunk) (error nil))))
;; When there's no more hunks, diff-hunk-next signals an error.
(error nil)))))
+(defun diff-show-trailing-whitespaces ()
+ "Show trailing whitespaces in modified lines for diff-mode."
+ (interactive)
+ (let ((whitespace-style '(trailing))
+ (whitespace-trailing-regexp "^[-\+!<>].*?\\([\t ]+\\)$"))
+ (whitespace-mode 1))) ; display trailing blanks in diff buffer
+
;; provide the package
(provide 'diff-mode)