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

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

[elpa] master 78e8d0a 3/7: company-ispell: Filter returned candidates lo


From: Dmitry Gutov
Subject: [elpa] master 78e8d0a 3/7: company-ispell: Filter returned candidates locally
Date: Thu, 22 Jan 2015 23:06:52 +0000

branch: master
commit 78e8d0a9616dc45ea8ac2bace32aeedba8c5f6d2
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>

    company-ispell: Filter returned candidates locally
    
    Resolves #284
---
 company-ispell.el |   11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/company-ispell.el b/company-ispell.el
index 1561bee..7334caa 100644
--- a/company-ispell.el
+++ b/company-ispell.el
@@ -60,8 +60,15 @@ If nil, use `ispell-complete-word-dict'."
     (interactive (company-begin-backend 'company-ispell))
     (prefix (when (company-ispell-available)
               (company-grab-word)))
-    (candidates (lookup-words arg (or company-ispell-dictionary
-                                      ispell-complete-word-dict)))
+    (candidates
+     (let ((words (lookup-words arg (or company-ispell-dictionary
+                                        ispell-complete-word-dict)))
+           (completion-ignore-case t))
+       (if (string= arg "")
+           ;; Small optimization.
+           words
+         ;; Work around issue #284.
+         (all-completions arg words))))
     (sorted t)
     (ignore-case 'keep-prefix)))
 



reply via email to

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