[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/company 484c99b: company-dot-icons-margin: Return nil w
From: |
ELPA Syncer |
Subject: |
[elpa] externals/company 484c99b: company-dot-icons-margin: Return nil when backend indicates no kind |
Date: |
Fri, 2 Apr 2021 19:57:05 -0400 (EDT) |
branch: externals/company
commit 484c99be29a5f71afba202fe0f8cbceea4509965
Author: Dmitry Gutov <dgutov@yandex.ru>
Commit: Dmitry Gutov <dgutov@yandex.ru>
company-dot-icons-margin: Return nil when backend indicates no kind
---
company.el | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/company.el b/company.el
index 235f36a..1acb46f 100644
--- a/company.el
+++ b/company.el
@@ -1539,10 +1539,11 @@ end of the match."
(defun company-dot-icons-margin (candidate _selected)
"Margin function that uses a colored dot to display completion kind."
- (propertize company-dot-icons-format 'face
- (or (assoc-default (company-call-backend 'kind candidate)
- company-dot-icons-face-mapping)
- (assoc-default t company-dot-icons-face-mapping))))
+ (when-let ((kind (company-call-backend 'kind candidate))
+ (face (or (assoc-default kind
+ company-dot-icons-face-mapping)
+ (assoc-default t company-dot-icons-face-mapping))))
+ (propertize company-dot-icons-format 'face face)))
(defun company-detect-icons-margin (candidate selected)
"Margin function which picks from vscodes icons or unicode icons
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [elpa] externals/company 484c99b: company-dot-icons-margin: Return nil when backend indicates no kind,
ELPA Syncer <=