> So you are saying that query-replace already does the job? Fine by
> me; if no one else supports this bug report in a week or two, I will
> close.
Actually there is another problem: whereas it's easy to rely on the
variable sentence-end-double-space as was asked by this request:
diff --git a/lisp/textmodes/paragraphs.el b/lisp/textmodes/paragraphs.el
index af99a96e045..974a83efdea 100644
--- a/lisp/textmodes/paragraphs.el
+++ b/lisp/textmodes/paragraphs.el
@@ -532,7 +532,10 @@ repunctuate-sentences
(end (use-region-end))))
(interactive (list nil (use-region-beginning) (use-region-end)))
(let ((regexp "\\([]\"')]?\\)\\([.?!]\\)\\([]\"')]?\\) +")
- (to-string "\\1\\2\\3 "))
+ (to-string (concat "\\1\\2\\3 "
+ (if sentence-end-double-space
+ " "
+ ""))))
(if no-query
(progn
(when start (goto-char start))
But the problem is that when a user customized
sentence-end-double-space to nil, the user still
might want to put two spaces since the docstring says:
"Put two spaces at the end of sentences"
So using one space will contradict the docstring.
I was actually aware about the docstring when I raised the bug, but I assumed that changing that docstring would be part of the fix. If I get to the essence of the issue: two spaces at the end of a sentence is no longer considered correct in most prose-authoring contexts. In that sense what I really wanted is the ability to automatically remove any such instances from an Org or Markdown file, for example. When I went looking for that in emacs this seemed like the correct tool for the job, and it is a little bit glaring that there's such a variable that one can set, but this function, defined in the same file, doesn't respect it.
That said, yes of course one could easily use query-replace as suggested above.
--