branch: master
commit 746062683444348a4e7e0edd2a42581cbe66dcb1
Author: Oleh Krehel <[email protected]>
Commit: Oleh Krehel <[email protected]>

    ivy.el (ivy-completing-read): Set completion-in-region-function
    
    Use the default one for items on `ivy-completing-read-handlers-alist'.
    
    It's a bit unfortunate that this isn't customizable on
    `ivy-completing-read-handlers-alist' (e.g. use `cadr' and `caddr' to
    customize both), but doing it so would be a breaking change.
---
 ivy.el | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/ivy.el b/ivy.el
index 9cb862f..ea306dd 100644
--- a/ivy.el
+++ b/ivy.el
@@ -1841,11 +1841,12 @@ DEF is the default value.
 INHERIT-INPUT-METHOD is currently ignored."
   (let ((handler (assoc this-command ivy-completing-read-handlers-alist)))
     (if handler
-        (funcall (cdr handler)
-                 prompt collection
-                 predicate require-match
-                 initial-input history
-                 def inherit-input-method)
+        (let ((completion-in-region-function #'completion--in-region))
+          (funcall (cdr handler)
+                   prompt collection
+                   predicate require-match
+                   initial-input history
+                   def inherit-input-method))
       ;; See the doc of `completing-read'.
       (when (consp history)
         (when (numberp (cdr history))

Reply via email to