From e8bdc13c002542c2902e8971656f48fb3b27e2ed Mon Sep 17 00:00:00 2001 From: Stefan Kangas Date: Sun, 9 Feb 2025 15:34:41 +0100 Subject: [PATCH] Improve filling with footnote-mode * lisp/mail/footnote.el (footnote-mode): Add regexp for footnotes to sentence-end-base to improve filling. (cherry picked from commit 64905eba2707f89c3befe99b36d14e24eeb9f8c0) --- lisp/mail/footnote.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/mail/footnote.el b/lisp/mail/footnote.el index c4d10b74856..1e6265c79bf 100644 --- a/lisp/mail/footnote.el +++ b/lisp/mail/footnote.el @@ -894,6 +894,10 @@ play around with the following keys: (make-local-variable 'footnote-start-tag) (make-local-variable 'footnote-end-tag) (make-local-variable 'adaptive-fill-function) + (setq-local sentence-end-base + (rx (or (regexp sentence-end-base) + (seq (regexp sentence-end-base) + "[" (+ digit) "]")))) ;; Filladapt is a GNU ELPA package. (when (boundp 'filladapt-token-table) -- 2.39.5