Commit b1816a74 authored by Stefan Monnier's avatar Stefan Monnier
Browse files

* diff-mode.el (diff-refine-hunk): Make it work when the hunk contains

empty lines without a leading space.
parent 5dcb4c4e
2010-12-07 Stefan Monnier <monnier@iro.umontreal.ca>
* diff-mode.el (diff-refine-hunk): Make it work when the hunk contains
empty lines without a leading space.
2010-12-06 Leo <sdl.web@gmail.com>
* dired-aux.el (dired-do-redisplay): Postphone
......
......@@ -1827,10 +1827,13 @@ For use in `add-log-current-defun-function'."
(eval-and-compile (require 'smerge-mode))
(save-excursion
(diff-beginning-of-hunk 'try-harder)
(let* ((style (diff-hunk-style)) ;Skips the hunk header as well.
(let* ((start (point))
(style (diff-hunk-style)) ;Skips the hunk header as well.
(beg (point))
(props '((diff-mode . fine) (face diff-refine-change)))
(end (progn (diff-end-of-hunk) (point))))
;; Be careful to go back to `start' so diff-end-of-hunk gets
;; to read the hunk header's line info.
(end (progn (goto-char start) (diff-end-of-hunk) (point))))
(remove-overlays beg end 'diff-mode 'fine)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment