projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
af92c52
)
* lisp/textmodes/paragraphs.el (repunctuate-sentences): Region for NO-QUERY.
author
Juri Linkov
<juri@linkov.net>
Tue, 28 Dec 2021 19:51:54 +0000
(21:51 +0200)
committer
Juri Linkov
<juri@linkov.net>
Tue, 28 Dec 2021 19:51:54 +0000
(21:51 +0200)
Use region boundaries also for the case when NO-QUERY arg is non-nil
(bug#52769).
lisp/textmodes/paragraphs.el
patch
|
blob
|
history
diff --git
a/lisp/textmodes/paragraphs.el
b/lisp/textmodes/paragraphs.el
index 98362b857945c0a806006cd13fa3532b89fa1e49..acb26fd1c1233b21b40bd8ac23880710462b63a0 100644
(file)
--- a/
lisp/textmodes/paragraphs.el
+++ b/
lisp/textmodes/paragraphs.el
@@
-492,8
+492,10
@@
asking for confirmation."
(let ((regexp "\\([]\"')]?\\)\\([.?!]\\)\\([]\"')]?\\) +")
(to-string "\\1\\2\\3 "))
(if no-query
- (while (re-search-forward regexp nil t)
- (replace-match to-string))
+ (progn
+ (when start (goto-char start))
+ (while (re-search-forward regexp end t)
+ (replace-match to-string)))
(query-replace-regexp regexp to-string nil start end))))