[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/anzu a52dca6f92 010/288: Support migemo(#2)
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/anzu a52dca6f92 010/288: Support migemo(#2) |
Date: |
Thu, 6 Jan 2022 03:58:34 -0500 (EST) |
branch: elpa/anzu
commit a52dca6f924c141fe0f7150bd83afe3dae30b3c8
Author: Syohei YOSHIDA <syohex@gmail.com>
Commit: Syohei YOSHIDA <syohex@gmail.com>
Support migemo(#2)
---
README.md | 5 +++++
anzu.el | 12 ++++++++++--
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 9edde55fd1..dda869b350 100644
--- a/README.md
+++ b/README.md
@@ -45,6 +45,11 @@ you propertize string by yourself.
(setq anzu-mode-line-update-function 'my/update-func)
```
+#### `anzu-use-migemo`(Default is `nil`)
+
+Set non-nil` if you use [migemo](https://github.com/emacs-jp/migemo).
+
+
## Sample Configuration
```lisp
diff --git a/anzu.el b/anzu.el
index 73f44dfa81..54f691eb80 100644
--- a/anzu.el
+++ b/anzu.el
@@ -35,6 +35,11 @@
:type 'string
:group 'anzu)
+(defcustom anzu-use-migemo nil
+ "Flag of using migemo"
+ :type 'boolean
+ :group 'anzu)
+
(defcustom anzu-mode-line-update-function nil
"Function which return mode-line string"
:type 'function
@@ -54,8 +59,11 @@
(save-excursion
(goto-char (point-min))
(let ((positions '())
- (count 0))
- (while (re-search-forward str nil t)
+ (count 0)
+ (search-func (if (and anzu-use-migemo migemo-isearch-enable-p)
+ 'migemo-forward
+ 're-search-forward)))
+ (while (funcall search-func str nil t)
(push (cons (match-beginning 0) (match-end 0)) positions)
(incf count))
(let ((result (cons count (reverse positions))))
- [nongnu] branch elpa/anzu created (now 5abb37455e), ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 51a39670af 005/288: update gif image, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 8c501d85cd 001/288: init repos, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu b61877bf18 006/288: fixed an error at when the variable has a string value, not a list., ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 450b4ddb4b 008/288: Fix byte compile warnings(#1), ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 69518308a0 009/288: Remove needless customization variable, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 9c56ab9875 014/288: Update document about anzu-cons-mode-line-p, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 241af32b99 002/288: Add update mode-line function, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu a52dca6f92 010/288: Support migemo(#2),
ELPA Syncer <=
- [nongnu] elpa/anzu 66807d27a7 012/288: Add Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu c2f8cbc234 016/288: Fix header, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu f570e01b4c 032/288: Merge pull request #8 from bbatsov/doc-improvement, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu f57d1e6ceb 033/288: bump up version and update Changes, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 1afa7d7b0f 013/288: Add flag whether anzu.el cons search info to mode-line(#4), ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu e9bb490b65 003/288: Update document, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 9de45b406c 004/288: add sample, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 9ab3cfa390 007/288: Merge pull request #3 from kiwanami/master, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu e39deb4aec 011/288: Add comment section, ELPA Syncer, 2022/01/06
- [nongnu] elpa/anzu 6fda98326a 024/288: input is regexp if isearch-regexp is non-nil, ELPA Syncer, 2022/01/06