[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/jinx 06d801f595 3/8: Simplify jinx--recheck-overlays
From: |
ELPA Syncer |
Subject: |
[elpa] externals/jinx 06d801f595 3/8: Simplify jinx--recheck-overlays |
Date: |
Wed, 29 Mar 2023 22:58:45 -0400 (EDT) |
branch: externals/jinx
commit 06d801f5954f33c7e746f7a6dd1109dc4c6e3c2c
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Simplify jinx--recheck-overlays
---
jinx.el | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/jinx.el b/jinx.el
index 9fec165919..a9ed2fe773 100644
--- a/jinx.el
+++ b/jinx.el
@@ -571,12 +571,14 @@ If VISIBLE is non-nil, only include visible overlays."
(defun jinx--recheck-overlays ()
"Recheck all overlays in buffer after a dictionary update."
- (save-restriction
- (widen)
- (dolist (ov (jinx--get-overlays (point-min) (point-max)))
- (goto-char (overlay-end ov))
- (when (jinx--word-valid-p (overlay-start ov))
- (delete-overlay ov)))))
+ (save-excursion
+ (save-restriction
+ (widen)
+ (dolist (ov (overlays-in (point-min) (point-max)))
+ (when (eq (overlay-get ov 'category) 'jinx)
+ (goto-char (overlay-end ov))
+ (when (jinx--word-valid-p (overlay-start ov))
+ (delete-overlay ov)))))))
(defun jinx--correct (overlay &optional recenter info)
"Correct word at OVERLAY with optional RECENTER and prompt INFO."
- [elpa] externals/jinx updated (72d7a1ad9d -> 397112434c), ELPA Syncer, 2023/03/29
- [elpa] externals/jinx aa0a82e9fe 1/8: Refactoring of internals, ELPA Syncer, 2023/03/29
- [elpa] externals/jinx 6ea7a861c4 6/8: editorial changes to readme (#26), ELPA Syncer, 2023/03/29
- [elpa] externals/jinx 27177e33d9 5/8: Fix compilation warning, ELPA Syncer, 2023/03/29
- [elpa] externals/jinx 397112434c 8/8: Improve readme and commentary, ELPA Syncer, 2023/03/29
- [elpa] externals/jinx f966592133 2/8: Reset syntax table correctly, ELPA Syncer, 2023/03/29
- [elpa] externals/jinx 06d801f595 3/8: Simplify jinx--recheck-overlays,
ELPA Syncer <=
- [elpa] externals/jinx 983ffa2862 4/8: Simplify overlay reordering, ELPA Syncer, 2023/03/29
- [elpa] externals/jinx 524711ef85 7/8: Improve readme, ELPA Syncer, 2023/03/29