Improve the faces for the last change

* avy.el (avy--overlay-at-full): Update.
This commit is contained in:
Oleh Krehel 2015-10-26 08:59:27 +01:00
parent 9ae44133ca
commit 1b78fb0d89

14
avy.el
View File

@ -759,10 +759,16 @@ LEAF is normally ((BEG . END) . WND)."
(when (and (bound-and-true-p visual-line-mode) (when (and (bound-and-true-p visual-line-mode)
(> len (- end beg))) (> len (- end beg)))
(setq len (- end beg)) (setq len (- end beg))
(setq str (let ((old-str (apply #'string (reverse path))))
(substring (propertize (setq str
(apply #'string (reverse path)) (substring
'face 'avy-lead-face) 0 len)))))) (propertize
old-str
'face
(if (= (length old-str) 1)
'avy-lead-face
'avy-lead-face-0))
0 len)))))))
(avy--overlay (avy--overlay
str beg end wnd str beg end wnd
(lambda (str old-str) (lambda (str old-str)