[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 2ee5618 085/348: ivy.el: Add face customizations to ivy-sw
From: |
Oleh Krehel |
Subject: |
[elpa] master 2ee5618 085/348: ivy.el: Add face customizations to ivy-switch-buffer |
Date: |
Sat, 8 Apr 2017 11:03:33 -0400 (EDT) |
branch: master
commit 2ee56189e977093268fcc9a9e5159a0141c33af8
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>
ivy.el: Add face customizations to ivy-switch-buffer
Fixes #568
---
ivy.el | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/ivy.el b/ivy.el
index c67e987..2da7e0a 100644
--- a/ivy.el
+++ b/ivy.el
@@ -2718,6 +2718,11 @@ CANDS is a list of strings."
"List of regexps or functions matching buffer names to ignore."
:type '(repeat (choice regexp function)))
+(defvar ivy-switch-buffer-faces-alist '((dired-mode . ivy-subdir)
+ (org-mode . org-level-4))
+ "Store face customizations for `ivy-switch-buffer'.
+Each KEY is `major-mode', each VALUE is a face name.")
+
(defun ivy--buffer-list (str &optional virtual predicate)
"Return the buffers that match STR.
When VIRTUAL is non-nil, add virtual buffers."
@@ -2729,7 +2734,12 @@ When VIRTUAL is non-nil, add virtual buffers."
(file-remote-p
(abbreviate-file-name default-directory)))
(propertize x 'face 'ivy-remote)
- x))
+ (let ((face (with-current-buffer x
+ (cdr (assoc major-mode
+ ivy-switch-buffer-faces-alist)))))
+ (if face
+ (propertize x 'face face)
+ x))))
(all-completions str 'internal-complete-buffer predicate))
(and virtual
(ivy--virtual-buffers)))))
- [elpa] master baf89c0 054/348: ivy-test.el (colir-color-parse): Add test, (continued)
- [elpa] master baf89c0 054/348: ivy-test.el (colir-color-parse): Add test, Oleh Krehel, 2017/04/08
- [elpa] master be24b57 049/348: Revert "ivy.el (ivy-completion-in-region): Fix double insert bug", Oleh Krehel, 2017/04/08
- [elpa] master 77fb030 052/348: ivy.el (ivy-completion-in-region): Fix common length longer than str, Oleh Krehel, 2017/04/08
- [elpa] master 7280e19 050/348: ivy.el (ivy-completion-common-length): Fix double insert bug, Oleh Krehel, 2017/04/08
- [elpa] master 288723e 065/348: counsel.el (counsel-set-variable): Allow new symbols, Oleh Krehel, 2017/04/08
- [elpa] master fe32959 066/348: ivy.el (ivy--actionp): Fix lambda being considered a list of actions, Oleh Krehel, 2017/04/08
- [elpa] master b3cca57 057/348: Make ivy prompt face overriding modular, Oleh Krehel, 2017/04/08
- [elpa] master 6067454 068/348: Improve readability of imenu candidates, Oleh Krehel, 2017/04/08
- [elpa] master a300514 071/348: counsel.el (hydra-keyboard-quit): Declare function, Oleh Krehel, 2017/04/08
- [elpa] master e54aa18 067/348: Add prefix arg for action functions, Oleh Krehel, 2017/04/08
- [elpa] master 2ee5618 085/348: ivy.el: Add face customizations to ivy-switch-buffer,
Oleh Krehel <=
- [elpa] master fe93cc6 084/348: counsel.el (counsel-M-x): Fix interaction with repeat, Oleh Krehel, 2017/04/08
- [elpa] master aaad354 088/348: counsel.el (counsel-find-file): Switch directory with "M-o b", Oleh Krehel, 2017/04/08
- [elpa] master e38b23c 091/348: Make counsel-ag extensible, Oleh Krehel, 2017/04/08
- [elpa] master 4dbd8c3 090/348: counsel.el (counsel-semantic): Fix let paren, Oleh Krehel, 2017/04/08
- [elpa] master 2e3cd39 099/348: Support custom command for counsel-git, Oleh Krehel, 2017/04/08
- [elpa] master 94e22bf 096/348: counsel.el (counsel-describe-face): New command, Oleh Krehel, 2017/04/08
- [elpa] master a627164 092/348: Mention that ivy-format-function is the variable described, Oleh Krehel, 2017/04/08
- [elpa] master 0d77775 103/348: README.md: Add a FAQ section, Oleh Krehel, 2017/04/08
- [elpa] master 17b59b2 105/348: Documenting how to generate texinfo, Oleh Krehel, 2017/04/08
- [elpa] master ed61b04 016/348: Fix problems introduced by "(ivy--filter): Recompute index after sort", Oleh Krehel, 2017/04/08