[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 3716acb 01/10: Enable company-search-map in company-search
From: |
Dmitry Gutov |
Subject: |
[elpa] master 3716acb 01/10: Enable company-search-map in company-search-mode body |
Date: |
Mon, 02 Feb 2015 15:23:06 +0000 |
branch: master
commit 3716acbb5529092fe7697c18f3a02e3919b02bfb
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>
Enable company-search-map in company-search-mode body
Fixes #289
---
company.el | 22 ++++++++++------------
1 files changed, 10 insertions(+), 12 deletions(-)
diff --git a/company.el b/company.el
index 4c7e160..d620e38 100644
--- a/company.el
+++ b/company.el
@@ -5,7 +5,7 @@
;; Author: Nikolaj Schumacher
;; Maintainer: Dmitry Gutov <address@hidden>
;; URL: http://company-mode.github.io/
-;; Version: 0.8.9
+;; Version: 0.8.9-cvs
;; Keywords: abbrev, convenience, matching
;; Package-Requires: ((emacs "24.1") (cl-lib "0.5"))
@@ -1573,7 +1573,11 @@ from the rest of the back-ends in the group, if any,
will be left at the end."
(defvar-local company-search-string "")
-(defvar-local company-search-lighter " Search: \"\"")
+(defvar company-search-lighter '(" "
+ (company-search-filtering "Filter" "Search")
+ ": \""
+ company-search-string
+ "\""))
(defvar-local company-search-filtering nil
"Non-nil to filter the completion candidates by the search string")
@@ -1615,12 +1619,7 @@ from the rest of the back-ends in the group, if any,
will be left at the end."
(let* ((pos (company--search new (nthcdr company-selection
company-candidates))))
(if (null pos)
(ding)
- (setq company-search-string new
- company-search-lighter (format " %s: \"%s\""
- (if company-search-filtering
- "Filter"
- "Search")
- new))
+ (setq company-search-string new)
(company-set-selection (+ company-selection pos) t))))
(defun company--search-assert-input ()
@@ -1731,10 +1730,10 @@ Don't start this directly, use
`company-search-candidates' or
(if (company-manual-begin)
(progn
(setq company--search-old-selection company-selection)
- (company-call-frontends 'update))
+ (company-call-frontends 'update)
+ (company-enable-overriding-keymap company-search-map))
(setq company-search-mode nil))
(kill-local-variable 'company-search-string)
- (kill-local-variable 'company-search-lighter)
(kill-local-variable 'company-search-filtering)
(kill-local-variable 'company--search-old-selection)
(when company-backend
@@ -1762,8 +1761,7 @@ Regular characters are appended to the search string.
The command `company-search-toggle-filtering'
(\\[company-search-toggle-filtering])
uses the search string to filter the completion candidates."
(interactive)
- (company-search-mode 1)
- (company-enable-overriding-keymap company-search-map))
+ (company-search-mode 1))
(defvar company-filter-map
(let ((keymap (make-keymap)))
- [elpa] master updated (089d51a -> c5538df), Dmitry Gutov, 2015/02/02
- [elpa] master a015fb3 09/10: Bump the version, Dmitry Gutov, 2015/02/02
- [elpa] master 08ec4cd 03/10: Add a comment, Dmitry Gutov, 2015/02/02
- [elpa] master bb8aa8b 04/10: company-search-map: Include <up> and <down> bindings, Dmitry Gutov, 2015/02/02
- [elpa] master 1b0dc62 06/10: company-search-map: Add company-complete-number bindings, Dmitry Gutov, 2015/02/02
- [elpa] master 10a7750 05/10: Track the current selection better, Dmitry Gutov, 2015/02/02
- [elpa] master b2de6ad 02/10: Fix version, Dmitry Gutov, 2015/02/02
- [elpa] master 94f2459 07/10: Use mode-line format in company-lighter, Dmitry Gutov, 2015/02/02
- [elpa] master 6fcbcfa 08/10: Pass company-lighter-base to company--group-lighter explicitly, Dmitry Gutov, 2015/02/02
- [elpa] master 3716acb 01/10: Enable company-search-map in company-search-mode body,
Dmitry Gutov <=
- [elpa] master c5538df 10/10: Merge commit 'a015fb350abe50d250e3e7a9c3c762397326977f' from company, Dmitry Gutov, 2015/02/02