From: Stefan Monnier Date: Mon, 25 Jun 2001 19:20:15 +0000 (+0000) Subject: (fill-region-as-paragraph): Don't look further back than LINEBEG. X-Git-Tag: emacs-pretest-21.0.104~155 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=da197e75714dbaf12fc008adfab59644600359e6;p=emacs.git (fill-region-as-paragraph): Don't look further back than LINEBEG. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4591bcb463f..68b4411d459 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2001-06-25 Stefan Monnier + + * textmodes/fill.el (fill-region-as-paragraph): Don't look further + back than LINEBEG. + 2001-06-25 Eli Zaretskii * xt-mouse.el (xterm-mouse-event): If the buffer displayed in the @@ -6,8 +11,8 @@ 2001-06-25 Milan Zamazal - * progmodes/glasses.el (glasses-make-readable): Consider - underscores too when separating a parenthesis. + * progmodes/glasses.el (glasses-make-readable): Consider underscores + too when separating a parenthesis. 2001-06-24 Eli Zaretskii @@ -19,8 +24,8 @@ 2001-06-23 Eli Zaretskii - * files.el (auto-mode-alist): Add configure.ac (autoconf). From - Karl Eichwalder . + * files.el (auto-mode-alist): Add configure.ac (autoconf). + From Karl Eichwalder . 2001-06-23 Richard M. Stallman @@ -43,8 +48,7 @@ * indent.el (indent-relative-maybe, indent-relative): Doc fix. - * menu-bar.el (toggle-debug-on-quit, toggle-debug-on-error): Doc - fix. + * menu-bar.el (toggle-debug-on-quit, toggle-debug-on-error): Doc fix. 2001-06-21 Eli Zaretskii @@ -60,8 +64,7 @@ (dabbrev--find-expansion): Simplify code in various ways. Don't treat minibuffers specially. Call dabbrev--make-friend-buffer-list. - (dabbrev--select-buffers): Don't treat minibuffers specially. - Simplify. + (dabbrev--select-buffers): Don't treat minibuffers specially. Simplify. (dabbrev--scanning-message): Do nothing when minibuffer is current. 2001-06-19 John Wiegley @@ -72,9 +75,8 @@ 2001-06-19 John Wiegley - * eshell/esh-mode.el: Disabled a test that often yields false - failures. - + * eshell/esh-mode.el: Disabled a test that often yields false failures. + 2001-06-19 Eli Zaretskii * woman.el (WoMan-highlight-references): Add help-echo to diff --git a/lisp/textmodes/fill.el b/lisp/textmodes/fill.el index 984c945525a..033435f97bd 100644 --- a/lisp/textmodes/fill.el +++ b/lisp/textmodes/fill.el @@ -527,15 +527,16 @@ space does not end a sentence, so don't break a line there." ;; further fills will assume it ends a sentence. ;; If we now know it does not end a sentence, ;; avoid putting it at the end of the line. - (while (or (and sentence-end-double-space - (> (point) (+ linebeg 2)) - (eq (preceding-char) ?\ ) - (not (eq (following-char) ?\ )) - (eq (char-after (- (point) 2)) ?\.) - (progn (forward-char -2) t)) - (and fill-nobreak-predicate - (funcall fill-nobreak-predicate) - (skip-chars-backward " \t"))) + (while (and (> (point) linebeg) + (or (and sentence-end-double-space + (> (point) (+ linebeg 2)) + (eq (preceding-char) ?\ ) + (not (eq (following-char) ?\ )) + (eq (char-after (- (point) 2)) ?\.) + (progn (forward-char -2) t)) + (and fill-nobreak-predicate + (funcall fill-nobreak-predicate) + (skip-chars-backward " \t")))) (if (re-search-backward " \\|\\c|.\\|.\\c|" linebeg 0) (forward-char 1))) ;; If the left margin and fill prefix by themselves