diff options
| author | Dave Love | 2000-10-27 15:50:24 +0000 |
|---|---|---|
| committer | Dave Love | 2000-10-27 15:50:24 +0000 |
| commit | 10ee3d79459b56f8b61863592407a15b8f8eeeb4 (patch) | |
| tree | 0cef3c02736de0161c7c66776b9a960496759312 | |
| parent | e1483c383115cc874a07ce2353567125ec36941f (diff) | |
| download | emacs-10ee3d79459b56f8b61863592407a15b8f8eeeb4.tar.gz emacs-10ee3d79459b56f8b61863592407a15b8f8eeeb4.zip | |
(refill-late-fill-paragraph-function): New
variable.
(refill-mode): Use it.
| -rw-r--r-- | lisp/textmodes/refill.el | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lisp/textmodes/refill.el b/lisp/textmodes/refill.el index 78518a9bc96..4e9039c87d4 100644 --- a/lisp/textmodes/refill.el +++ b/lisp/textmodes/refill.el | |||
| @@ -119,6 +119,8 @@ complex processing.") | |||
| 119 | (t (refill-fill-paragraph nil))) | 119 | (t (refill-fill-paragraph nil))) |
| 120 | (setq refill-doit nil))) | 120 | (setq refill-doit nil))) |
| 121 | 121 | ||
| 122 | (defvar refill-late-fill-paragraph-function nil) | ||
| 123 | |||
| 122 | ;;;###autoload | 124 | ;;;###autoload |
| 123 | (define-minor-mode refill-mode | 125 | (define-minor-mode refill-mode |
| 124 | "Toggle Refill minor mode. | 126 | "Toggle Refill minor mode. |
| @@ -134,12 +136,14 @@ refilling if they would cause auto-filling." | |||
| 134 | (progn | 136 | (progn |
| 135 | (add-hook 'after-change-functions 'refill-after-change-function nil t) | 137 | (add-hook 'after-change-functions 'refill-after-change-function nil t) |
| 136 | (add-hook 'post-command-hook 'refill-post-command-function nil t) | 138 | (add-hook 'post-command-hook 'refill-post-command-function nil t) |
| 139 | (set (make-local-variable 'refill-late-fill-paragraph-function) | ||
| 140 | fill-paragraph-function) | ||
| 137 | (set (make-local-variable 'fill-paragraph-function) | 141 | (set (make-local-variable 'fill-paragraph-function) |
| 138 | 'refill-fill-paragraph) | 142 | 'refill-fill-paragraph) |
| 139 | (auto-fill-mode 0)) | 143 | (auto-fill-mode 0)) |
| 140 | (remove-hook 'after-change-functions 'refill-after-change-function t) | 144 | (remove-hook 'after-change-functions 'refill-after-change-function t) |
| 141 | (remove-hook 'post-command-hook 'refill-post-command-function t) | 145 | (remove-hook 'post-command-hook 'refill-post-command-function t) |
| 142 | (setq fill-paragraph-function nil))) | 146 | (setq fill-paragraph-function refill-late-fill-paragraph-function))) |
| 143 | 147 | ||
| 144 | (provide 'refill) | 148 | (provide 'refill) |
| 145 | 149 | ||