emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 7bd6003 25/31: Update and improve faces


From: Oleh Krehel
Subject: [elpa] master 7bd6003 25/31: Update and improve faces
Date: Fri, 01 May 2015 14:29:02 +0000

branch: master
commit 7bd6003fd538c195230fbe3b89eef8ab3df4aee4
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>

    Update and improve faces
    
    * ivy.el (ivy-subdir): Inherit from dired-directory.
    
    * swiper.el (swiper-match-face-1): Update doc.
    (swiper-match-face-2): Update doc.
    (swiper-match-face-3): Update doc.
    (swiper-match-face-4): Inherit from isearch-fail.
    (swiper--add-overlays): Fix the faces order swapping on the second
    match.
    
    Now it finally works as planned: face-1 is the background (re group 0),
    next it cycles: face-2, face-3, face-4, face-2, face-3, face-4.
---
 ivy.el    |    2 +-
 swiper.el |   14 +++++++-------
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/ivy.el b/ivy.el
index 2030222..ffc1913 100644
--- a/ivy.el
+++ b/ivy.el
@@ -57,7 +57,7 @@
   "Face used by Ivy to issue a match required prompt.")
 
 (defface ivy-subdir
-  '((t (:weight bold)))
+  '((t (:inherit 'dired-directory)))
   "Face used by Ivy for highlighting subdirs in the alternatives.")
 
 (defface ivy-remote
diff --git a/swiper.el b/swiper.el
index 3d4d397..d15ed80 100644
--- a/swiper.el
+++ b/swiper.el
@@ -44,19 +44,19 @@
 
 (defface swiper-match-face-1
   '((t (:inherit isearch-lazy-highlight-face)))
-  "Face for `swiper' matches.")
+  "The background face for `swiper' matches.")
 
 (defface swiper-match-face-2
   '((t (:inherit isearch)))
-  "Face for `swiper' matches.")
+  "Face for `swiper' matches modulo 1.")
 
 (defface swiper-match-face-3
   '((t (:inherit match)))
-  "Face for `swiper' matches.")
+  "Face for `swiper' matches modulo 2.")
 
 (defface swiper-match-face-4
-  '((t (:inherit isearch)))
-  "Face for `swiper' matches.")
+  '((t (:inherit isearch-fail)))
+  "Face for `swiper' matches modulo 3.")
 
 (defface swiper-line-face
   '((t (:inherit highlight)))
@@ -271,11 +271,11 @@ BEG and END, when specified, are the point bounds."
                                              (match-end i)))
                       (face
                        (cond ((zerop ivy--subexps)
-                              (cl-caddr swiper-faces))
+                              (cadr swiper-faces))
                              ((zerop i)
                               (car swiper-faces))
                              (t
-                              (nth (1+ (mod (1- i) (1- (length swiper-faces))))
+                              (nth (1+ (mod (+ i 2) (1- (length 
swiper-faces))))
                                    swiper-faces)))))
                   (push overlay swiper--overlays)
                   (overlay-put overlay 'face face)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]