]> git.eshelyaron.com Git - emacs.git/commit
hl-line.el: Fix flickering of highlighted line (bug#23510)
authorStephen Berman <stephen.berman@gmx.net>
Thu, 26 May 2016 09:30:29 +0000 (11:30 +0200)
committerStephen Berman <stephen.berman@gmx.net>
Thu, 26 May 2016 09:30:29 +0000 (11:30 +0200)
commit16be3e90545972dec16014253a843229d5bdf388
tree862abd927225b9f9d1a1f68af8d9dfe0f41e2b72
parente971ce6de27f982720ef312637e1d40da80e8d1f
hl-line.el: Fix flickering of highlighted line (bug#23510)

* lisp/hl-line.el (hl-line-maybe-unhighlight)
(global-hl-line-highlight-all)
(global-hl-line-maybe-unhighlight): New functions.
(hl-line-overlay-buffer): New variable.
(hl-line-mode): Use it.  Replace hl-line-unhighlight on
pre-command-hook by hl-line-maybe-unhighlight on
post-command-hook, to prevent hl-line from flickering.
Adjust document string.
(global-hl-line-mode): Use global-hl-line-highlight-all to
simultaneously highlight the current line in all live windows.
Replace global-hl-line-unhighlight on pre-command-hook by
global-hl-line-maybe-unhighlight on post-command-hook, to
prevent global-hl-line from flickering.  Remove
global-hl-line-unhighlight from change-major-mode-hook on
disabling the mode.  Adjust document string.
lisp/hl-line.el