branch: externals/ivy-hydra
commit d2052bab4eecebab84e75b8a10b66f66a8574425
Author: Oleh Krehel <[email protected]>
Commit: Oleh Krehel <[email protected]>
counsel.el (counsel--company-display-transformer): Add
Fixes #2233
---
counsel.el | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/counsel.el b/counsel.el
index d6a62b7..1a3f541 100644
--- a/counsel.el
+++ b/counsel.el
@@ -409,8 +409,14 @@ Update the minibuffer with the amount of lines collected
every
:caller 'counsel-company))))
(ivy-configure 'counsel-company
+ :display-transformer-fn #'counsel--company-display-transformer
:unwind-fn #'company-abort)
+(defun counsel--company-display-transformer (s)
+ (concat s (let ((annot (company-call-backend 'annotation s)))
+ (when annot
+ (company--clean-string annot)))))
+
;;** `counsel-irony'
(declare-function irony-completion-candidates-async "ext:irony-completion")
(declare-function irony-completion-symbol-bounds "ext:irony-completion")