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

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

[elpa] master b8b951b 59/63: Allow ivy-count-format to be set as nil


From: Oleh Krehel
Subject: [elpa] master b8b951b 59/63: Allow ivy-count-format to be set as nil
Date: Fri, 21 Aug 2015 12:08:48 +0000

branch: master
commit b8b951b205cd7def439bc6a37bba6f3abf24291d
Author: Chunyang Xu <address@hidden>
Commit: Chunyang Xu <address@hidden>

    Allow ivy-count-format to be set as nil
---
 ivy.el |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/ivy.el b/ivy.el
index 55005de..faa469b 100644
--- a/ivy.el
+++ b/ivy.el
@@ -72,7 +72,7 @@
 Set this to nil if you don't want the count.  You can also set it
 to e.g. \"(%d/%d) \" if you want to see both the candidate index
 and the candidate count."
-  :type 'string)
+  :type '(choice (const :tag "Count disabled" nil) string))
 
 (defcustom ivy-wrap nil
   "Whether to wrap around after the first and last candidate."
@@ -993,6 +993,8 @@ This is useful for recursive `ivy-read'."
     (setq ivy--prompt
           (cond ((string-match "%.*d" prompt)
                  prompt)
+                ((null ivy-count-format)
+                 nil)
                 ((string-match "%d.*%d" ivy-count-format)
                  (let ((w (length (number-to-string
                                    (length ivy--all-candidates))))



reply via email to

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