[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/ivy-hydra 9b36d9c 186/395: swiper.el (swiper-isearch):
From: |
Basil L. Contovounesios |
Subject: |
[elpa] externals/ivy-hydra 9b36d9c 186/395: swiper.el (swiper-isearch): Use ivy-init-fns-alist |
Date: |
Thu, 25 Feb 2021 08:31:59 -0500 (EST) |
branch: externals/ivy-hydra
commit 9b36d9c13bb837bcafeaac78017f2fde26bf7124
Author: Oleh Krehel <ohwoeowho@gmail.com>
Commit: Oleh Krehel <ohwoeowho@gmail.com>
swiper.el (swiper-isearch): Use ivy-init-fns-alist
---
swiper.el | 40 ++++++++++++++++++++++------------------
1 file changed, 22 insertions(+), 18 deletions(-)
diff --git a/swiper.el b/swiper.el
index 4b60264..5cf5f3e 100644
--- a/swiper.el
+++ b/swiper.el
@@ -1659,33 +1659,36 @@ When not running `swiper-isearch' already, start it."
(cl-incf i))
(nreverse res))))
+(defun swiper--isearch-init ()
+ "Initialize `swiper-isearch'."
+ (swiper--init)
+ (setq swiper--isearch-start-point (point))
+ (swiper-font-lock-ensure))
+
;;;###autoload
(defun swiper-isearch (&optional initial-input)
"A `swiper' that's not line-based."
(interactive)
- (swiper--init)
- (setq swiper--isearch-start-point (point))
- (swiper-font-lock-ensure)
(let ((ivy-fixed-height-minibuffer t)
(cursor-in-non-selected-windows nil)
(swiper-min-highlight 1)
res)
(unwind-protect
- (and
- (setq res
- (ivy-read
- "Swiper: "
- #'swiper-isearch-function
- :initial-input initial-input
- :keymap swiper-isearch-map
- :dynamic-collection t
- :require-match t
- :action #'swiper-isearch-action
- :re-builder #'swiper--re-builder
- :history 'swiper-history
- :extra-props (list :fname (buffer-file-name))
- :caller 'swiper-isearch))
- (point))
+ (and
+ (setq res
+ (ivy-read
+ "Swiper: "
+ #'swiper-isearch-function
+ :initial-input initial-input
+ :keymap swiper-isearch-map
+ :dynamic-collection t
+ :require-match t
+ :action #'swiper-isearch-action
+ :re-builder #'swiper--re-builder
+ :history 'swiper-history
+ :extra-props (list :fname (buffer-file-name))
+ :caller 'swiper-isearch))
+ (point))
(unless (or res swiper-stay-on-quit)
(goto-char swiper--opoint))
(isearch-clean-overlays)
@@ -1695,6 +1698,7 @@ When not running `swiper-isearch' already, start it."
(ivy-configure 'swiper-isearch
:occur #'swiper-occur
+ :init-fn #'swiper--isearch-init
:update-fn 'auto
:unwind-fn #'swiper--cleanup
:format-fn #'swiper-isearch-format-function)
- [elpa] externals/ivy-hydra 0cff3e1 157/395: swiper.el (swiper): Add isearch-clean-overlays, (continued)
- [elpa] externals/ivy-hydra 0cff3e1 157/395: swiper.el (swiper): Add isearch-clean-overlays, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 35d015b 166/395: ivy.el (ivy-avy): Configure no-counsel-M-x, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 18d7ff9 168/395: ivy.el (ivy--set-candidates): Delete duplicates, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra b9eb3c1 162/395: swiper.el (swiper--line-number): Works with ivy-mark, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra ba73e45 156/395: ivy.el (ivy-read-action): Avoid ivy-read-action-ivy overwriting ivy--directory, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 328da1f 170/395: counsel.el (counsel-rg): Split command args in a more familiar way, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 1c1573e 167/395: ivy.el (ivy--update-prompt): Handle auto-insert.el, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 45a3609 176/395: counsel.el (counsel-rg-base-command): Add "-M 120" by default, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 0258725 175/395: counsel.el: Fix candidate splitting when eol is CR or CRLF, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 8fae568 184/395: counsel.el (counsel-org-link): Add, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 9b36d9c 186/395: swiper.el (swiper-isearch): Use ivy-init-fns-alist,
Basil L. Contovounesios <=
- [elpa] externals/ivy-hydra 9e1513f 195/395: ivy.el (ivy--split): Don't split consecutive group brackets, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 7b9b3cc 200/395: ivy.el (ivy--switch-buffer-matcher): Complete remote dirs via ":", Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 829cf8a 212/395: ivy.el (ivy--done): Set ivy-text, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 95896df 221/395: Honour sentence-end-double-space in recent change, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra c0a960b 216/395: ivy.el (ivy-read): Don't error on "Selecting deleted buffer", Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 8277a70 197/395: ivy.el (ivy-switch-buffer-transformer): Simplify, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra df41a6d 220/395: counsel.el (counsel-rg-base-command): Double the default max columns, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 51430ff 233/395: counsel.el: Fix candidate splitting when eol is CR or CRLF, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 04ca164 275/395: ivy-resume: resume buffer for counsel-grep, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 7dd6bfc 287/395: ivy.el (ivy-read): Document :extra-props as a plist, Basil L. Contovounesios, 2021/02/25