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

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

[elpa] externals/which-key 3c0c7c24ef 7/7: Merge pull request #329 from


From: ELPA Syncer
Subject: [elpa] externals/which-key 3c0c7c24ef 7/7: Merge pull request #329 from hans-d/feat-elipsis
Date: Sat, 1 Jan 2022 23:57:57 -0500 (EST)

branch: externals/which-key
commit 3c0c7c24ef457c1de0ba6f20e2baab02f6c6beaf
Merge: 4c82226083 8361479d78
Author: Justin Burkett <justin@burkett.cc>
Commit: GitHub <noreply@github.com>

    Merge pull request #329 from hans-d/feat-elipsis
    
    add which-key-elipsis
---
 which-key.el | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/which-key.el b/which-key.el
index 644d755c13..870894644d 100644
--- a/which-key.el
+++ b/which-key.el
@@ -133,6 +133,15 @@ the default is \" : \"."
   :group 'which-key
   :type 'string)
 
+(defcustom which-key-elipsis
+  (if which-key-dont-use-unicode ".." "…")
+  "Elipsis to use when truncating. Default is \"…\", unless
+`which-key-dont-use-unicode' is non nil, in which case
+the default is \"..\"."
+  :group 'which-key
+  :type 'string)
+
+
 (defcustom which-key-prefix-prefix "+"
   "String to insert in front of prefix commands (i.e., commands
 that represent a sub-map). Default is \"+\"."
@@ -1580,7 +1589,7 @@ If KEY contains any \"special keys\" defined in
 (defsubst which-key--truncate-description (desc)
   "Truncate DESC description to `which-key-max-description-length'."
   (let* ((last-face (get-text-property (1- (length desc)) 'face desc))
-         (dots (which-key--propertize ".." 'face last-face)))
+         (dots (which-key--propertize which-key-elipsis 'face last-face)))
     (if (and which-key-max-description-length
              (> (length desc) which-key-max-description-length))
         (concat (substring desc 0 which-key-max-description-length) dots)



reply via email to

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