diff options
| author | Dave Love | 2000-11-12 22:51:35 +0000 |
|---|---|---|
| committer | Dave Love | 2000-11-12 22:51:35 +0000 |
| commit | f8c0f31e17b41cd9b4d6a8da534e08ad352bced8 (patch) | |
| tree | 7795c07cb08ab9ab302c4b848a35c9db51e217c9 | |
| parent | edcfa2404b356506f637337e98de05a08a2b178e (diff) | |
| download | emacs-f8c0f31e17b41cd9b4d6a8da534e08ad352bced8.tar.gz emacs-f8c0f31e17b41cd9b4d6a8da534e08ad352bced8.zip | |
From Emerick Rogul <emerick@csa.bu.edu>.
* message.el (message-setup-fill-variables): New variable.
(message-mode): Use it.
| -rw-r--r-- | lisp/gnus/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/gnus/message.el | 59 |
2 files changed, 40 insertions, 25 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 9d1afa55f77..77757e6e911 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,9 @@ | |||
| 1 | 2000-11-12 Dave Love <fx@gnu.org> | ||
| 2 | |||
| 3 | From Emerick Rogul <emerick@csa.bu.edu>. | ||
| 4 | * message.el (message-setup-fill-variables): New variable. | ||
| 5 | (message-mode): Use it. | ||
| 6 | |||
| 1 | 2000-11-10 Alexandre Oliva <oliva@lsd.ic.unicamp.br> | 7 | 2000-11-10 Alexandre Oliva <oliva@lsd.ic.unicamp.br> |
| 2 | 8 | ||
| 3 | * gnus-mlspl.el: Documentation tweaks. | 9 | * gnus-mlspl.el: Documentation tweaks. |
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index e8f2de562e3..f0c4d34e3a9 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el | |||
| @@ -1488,20 +1488,6 @@ M-RET message-newline-and-reformat (break the line and reformat)." | |||
| 1488 | (error "Face %s not configured for %s mode" face mode-name))) | 1488 | (error "Face %s not configured for %s mode" face mode-name))) |
| 1489 | "") | 1489 | "") |
| 1490 | facemenu-remove-face-function t) | 1490 | facemenu-remove-face-function t) |
| 1491 | (make-local-variable 'paragraph-separate) | ||
| 1492 | (make-local-variable 'paragraph-start) | ||
| 1493 | ;; `-- ' precedes the signature. `-----' appears at the start of the | ||
| 1494 | ;; lines that delimit forwarded messages. | ||
| 1495 | ;; Lines containing just >= 3 dashes, perhaps after whitespace, | ||
| 1496 | ;; are also sometimes used and should be separators. | ||
| 1497 | (setq paragraph-start | ||
| 1498 | (concat (regexp-quote mail-header-separator) | ||
| 1499 | "$\\|[ \t]*[a-z0-9A-Z]*>+[ \t]*$\\|[ \t]*$\\|" | ||
| 1500 | "-- $\\|---+$\\|" | ||
| 1501 | page-delimiter | ||
| 1502 | ;;!!! Uhm... shurely this can't be right? | ||
| 1503 | "[> " (regexp-quote message-yank-prefix) "]+$")) | ||
| 1504 | (setq paragraph-separate paragraph-start) | ||
| 1505 | (make-local-variable 'message-reply-headers) | 1491 | (make-local-variable 'message-reply-headers) |
| 1506 | (setq message-reply-headers nil) | 1492 | (setq message-reply-headers nil) |
| 1507 | (make-local-variable 'message-newsreader) | 1493 | (make-local-variable 'message-newsreader) |
| @@ -1510,6 +1496,7 @@ M-RET message-newline-and-reformat (break the line and reformat)." | |||
| 1510 | (set (make-local-variable 'message-sent-message-via) nil) | 1496 | (set (make-local-variable 'message-sent-message-via) nil) |
| 1511 | (set (make-local-variable 'message-checksum) nil) | 1497 | (set (make-local-variable 'message-checksum) nil) |
| 1512 | (set (make-local-variable 'message-mime-part) 0) | 1498 | (set (make-local-variable 'message-mime-part) 0) |
| 1499 | (message-setup-fill-variables) | ||
| 1513 | ;;(when (fboundp 'mail-hist-define-keys) | 1500 | ;;(when (fboundp 'mail-hist-define-keys) |
| 1514 | ;; (mail-hist-define-keys)) | 1501 | ;; (mail-hist-define-keys)) |
| 1515 | (if (featurep 'xemacs) | 1502 | (if (featurep 'xemacs) |
| @@ -1526,23 +1513,45 @@ M-RET message-newline-and-reformat (break the line and reformat)." | |||
| 1526 | (mail-abbrevs-setup) | 1513 | (mail-abbrevs-setup) |
| 1527 | (mail-aliases-setup))) | 1514 | (mail-aliases-setup))) |
| 1528 | (message-set-auto-save-file-name) | 1515 | (message-set-auto-save-file-name) |
| 1529 | (make-local-variable 'adaptive-fill-regexp) | ||
| 1530 | (setq adaptive-fill-regexp | ||
| 1531 | (concat "[ \t]*[-[:alnum:]]*\\(>[ \t]*\\)+[ \t]*\\|" adaptive-fill-regexp)) | ||
| 1532 | (unless (boundp 'adaptive-fill-first-line-regexp) | ||
| 1533 | (setq adaptive-fill-first-line-regexp nil)) | ||
| 1534 | (make-local-variable 'adaptive-fill-first-line-regexp) | ||
| 1535 | (setq adaptive-fill-first-line-regexp | ||
| 1536 | (concat "[ \t]*[-[:alnum:]]*\\(>[ \t]*\\)+[ \t]*\\|" | ||
| 1537 | adaptive-fill-first-line-regexp)) | ||
| 1538 | (make-local-variable 'auto-fill-inhibit-regexp) | ||
| 1539 | (setq auto-fill-inhibit-regexp "^[A-Z][^: \n\t]+:") | ||
| 1540 | (mm-enable-multibyte) | 1516 | (mm-enable-multibyte) |
| 1541 | (make-local-variable 'indent-tabs-mode) ;Turn off tabs for indentation. | 1517 | (make-local-variable 'indent-tabs-mode) ;Turn off tabs for indentation. |
| 1542 | (setq indent-tabs-mode nil) | 1518 | (setq indent-tabs-mode nil) |
| 1543 | (mml-mode) | 1519 | (mml-mode) |
| 1544 | (run-hooks 'text-mode-hook 'message-mode-hook)) | 1520 | (run-hooks 'text-mode-hook 'message-mode-hook)) |
| 1545 | 1521 | ||
| 1522 | (defun message-setup-fill-variables () | ||
| 1523 | "Setup message fill variables." | ||
| 1524 | (make-local-variable 'paragraph-separate) | ||
| 1525 | (make-local-variable 'paragraph-start) | ||
| 1526 | (make-local-variable 'adaptive-fill-regexp) | ||
| 1527 | (unless (boundp 'adaptive-fill-first-line-regexp) | ||
| 1528 | (setq adaptive-fill-first-line-regexp nil)) | ||
| 1529 | (make-local-variable 'adaptive-fill-first-line-regexp) | ||
| 1530 | (make-local-variable 'auto-fill-inhibit-regexp) | ||
| 1531 | (let ((quote-prefix-regexp | ||
| 1532 | (concat | ||
| 1533 | "[ \t]*" ; possible initial space | ||
| 1534 | "\\(\\(" (regexp-quote message-yank-prefix) "\\|" ; user's prefix | ||
| 1535 | "\\w+>\\|" ; supercite-style prefix | ||
| 1536 | "[|:>]" ; standard prefix | ||
| 1537 | "\\)[ \t]*\\)+"))) ; possible space after each prefix | ||
| 1538 | (setq paragraph-start | ||
| 1539 | (concat | ||
| 1540 | (regexp-quote mail-header-separator) "$\\|" | ||
| 1541 | "[ \t]*$\\|" ; blank lines | ||
| 1542 | "-- $\\|" ; signature delimiter | ||
| 1543 | "---+$\\|" ; delimiters for forwarded messages | ||
| 1544 | page-delimiter "$\\|" ; spoiler warnings | ||
| 1545 | ".*wrote:$\\|" ; attribution lines | ||
| 1546 | quote-prefix-regexp "$")) ; empty lines in quoted text | ||
| 1547 | (setq paragraph-separate paragraph-start) | ||
| 1548 | (setq adaptive-fill-regexp | ||
| 1549 | (concat quote-prefix-regexp "\\|" adaptive-fill-regexp)) | ||
| 1550 | (setq adaptive-fill-first-line-regexp | ||
| 1551 | (concat quote-prefix-regexp "\\|" | ||
| 1552 | adaptive-fill-first-line-regexp)) | ||
| 1553 | (setq auto-fill-inhibit-regexp "^[A-Z][^: \n\t]+:"))) | ||
| 1554 | |||
| 1546 | 1555 | ||
| 1547 | 1556 | ||
| 1548 | ;;; | 1557 | ;;; |