dgutov pushed a commit to branch master
in repository elpa.
commit a221c4b86ac05ed3a4da27aa4660243eb6b922eb
Author: Ingo Lohmar <[email protected]>
Date: Sun Mar 23 11:25:59 2014 +0100
New option company-etags-ignore-case
When t, find tags candidates case-insensitively
---
company-etags.el | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/company-etags.el b/company-etags.el
index 270e3a2..437faad 100644
--- a/company-etags.el
+++ b/company-etags.el
@@ -40,6 +40,12 @@ buffer automatically."
:type '(choice (const :tag "off" nil)
(const :tag "on" t)))
+(defcustom company-etags-ignore-case nil
+ "Ignore case for `company-etags'. This implies that candidates are
+searched case-insensitively."
+ :type '(choice (const :tag "off" nil)
+ (const :tag "on" t)))
+
(defvar company-etags-modes '(prog-mode c-mode objc-mode c++-mode java-mode
jde-mode pascal-mode perl-mode python-mode))
@@ -61,7 +67,7 @@ buffer automatically."
(defun company-etags--candidates (prefix)
(let ((tags-table-list (company-etags-buffer-table))
- (completion-ignore-case nil))
+ (completion-ignore-case company-etags-ignore-case))
(and (or tags-file-name tags-table-list)
(fboundp 'tags-completion-table)
(save-excursion
@@ -83,7 +89,8 @@ buffer automatically."
(when (fboundp 'find-tag-noselect)
(save-excursion
(let ((buffer (find-tag-noselect arg)))
- (cons buffer (with-current-buffer buffer (point))))))))))
+ (cons buffer (with-current-buffer buffer (point))))))))
+ (ignore-case company-etags-ignore-case)))
(provide 'company-etags)
;;; company-etags.el ends here