diff options
| author | Chong Yidong | 2005-11-20 03:31:11 +0000 |
|---|---|---|
| committer | Chong Yidong | 2005-11-20 03:31:11 +0000 |
| commit | f129a4dfe3ec1402c9b0634afd9d7b6baf247bce (patch) | |
| tree | acd0175de1dd95715cb316dada8b1903bd6b775b | |
| parent | c003141f4c934c5437e2a6313782add05da82694 (diff) | |
| download | emacs-f129a4dfe3ec1402c9b0634afd9d7b6baf247bce.tar.gz emacs-f129a4dfe3ec1402c9b0634afd9d7b6baf247bce.zip | |
message.el: Revert last changes.
| -rw-r--r-- | lisp/gnus/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/gnus/message.el | 175 |
2 files changed, 78 insertions, 101 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 10e5ba0dc88..fcffe7dce49 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2005-11-19 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * message.el: Revert last changes. | ||
| 4 | |||
| 1 | 2005-11-17 Chong Yidong <cyd@stupidchicken.com> | 5 | 2005-11-17 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 6 | ||
| 3 | * message.el (message-courtesy-message) | 7 | * message.el (message-courtesy-message) |
diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 9a5f910290a..019b5bd4f07 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el | |||
| @@ -141,11 +141,7 @@ mailbox format." | |||
| 141 | :group 'message-sending) | 141 | :group 'message-sending) |
| 142 | 142 | ||
| 143 | (defcustom message-courtesy-message | 143 | (defcustom message-courtesy-message |
| 144 | (concat | 144 | "The following message is a courtesy copy of an article\nthat has been posted to %s as well.\n\n" |
| 145 | "The following message is a courtesy copy of an article" | ||
| 146 | hard-newline | ||
| 147 | "that has been posted to %s as well." | ||
| 148 | hard-newline hard-newline) | ||
| 149 | "*This is inserted at the start of a mailed copy of a posted message. | 145 | "*This is inserted at the start of a mailed copy of a posted message. |
| 150 | If the string contains the format spec \"%s\", the Newsgroups | 146 | If the string contains the format spec \"%s\", the Newsgroups |
| 151 | the article has been posted to will be inserted there. | 147 | the article has been posted to will be inserted there. |
| @@ -343,9 +339,7 @@ few false positives here." | |||
| 343 | ;;; marking inserted text | 339 | ;;; marking inserted text |
| 344 | 340 | ||
| 345 | (defcustom message-mark-insert-begin | 341 | (defcustom message-mark-insert-begin |
| 346 | (concat | 342 | "--8<---------------cut here---------------start------------->8---\n" |
| 347 | "--8<---------------cut here---------------start------------->8---" | ||
| 348 | hard-newline) | ||
| 349 | "How to mark the beginning of some inserted text." | 343 | "How to mark the beginning of some inserted text." |
| 350 | :version "22.1" | 344 | :version "22.1" |
| 351 | :type 'string | 345 | :type 'string |
| @@ -353,16 +347,14 @@ few false positives here." | |||
| 353 | :group 'message-various) | 347 | :group 'message-various) |
| 354 | 348 | ||
| 355 | (defcustom message-mark-insert-end | 349 | (defcustom message-mark-insert-end |
| 356 | (concat | 350 | "--8<---------------cut here---------------end--------------->8---\n" |
| 357 | "--8<---------------cut here---------------end--------------->8---" | ||
| 358 | hard-newline) | ||
| 359 | "How to mark the end of some inserted text." | 351 | "How to mark the end of some inserted text." |
| 360 | :version "22.1" | 352 | :version "22.1" |
| 361 | :type 'string | 353 | :type 'string |
| 362 | :link '(custom-manual "(message)Insertion Variables") | 354 | :link '(custom-manual "(message)Insertion Variables") |
| 363 | :group 'message-various) | 355 | :group 'message-various) |
| 364 | 356 | ||
| 365 | (defcustom message-archive-header "X-No-Archive: Yes" | 357 | (defcustom message-archive-header "X-No-Archive: Yes\n" |
| 366 | "Header to insert when you don't want your article to be archived. | 358 | "Header to insert when you don't want your article to be archived. |
| 367 | Archives \(such as groups.google.com\) respect this header." | 359 | Archives \(such as groups.google.com\) respect this header." |
| 368 | :version "22.1" | 360 | :version "22.1" |
| @@ -426,8 +418,7 @@ for `message-cross-post-insert-note'." | |||
| 426 | :link '(custom-manual "(message)Various Message Variables") | 418 | :link '(custom-manual "(message)Various Message Variables") |
| 427 | :group 'message-various) | 419 | :group 'message-various) |
| 428 | 420 | ||
| 429 | (defcustom message-elide-ellipsis | 421 | (defcustom message-elide-ellipsis "\n[...]\n\n" |
| 430 | (concat hard-newline "[...]" hard-newline hard-newline) | ||
| 431 | "*The string which is inserted for elided text." | 422 | "*The string which is inserted for elided text." |
| 432 | :type 'string | 423 | :type 'string |
| 433 | :link '(custom-manual "(message)Various Commands") | 424 | :link '(custom-manual "(message)Various Commands") |
| @@ -587,8 +578,7 @@ Done before generating the new subject of a forward." | |||
| 587 | :link '(custom-manual "(message)Insertion Variables") | 578 | :link '(custom-manual "(message)Insertion Variables") |
| 588 | :type 'regexp) | 579 | :type 'regexp) |
| 589 | 580 | ||
| 590 | (defcustom message-cancel-message | 581 | (defcustom message-cancel-message "I am canceling my own article.\n" |
| 591 | (concat "I am canceling my own article." hard-newline) | ||
| 592 | "Message to be inserted in the cancel message." | 582 | "Message to be inserted in the cancel message." |
| 593 | :group 'message-interface | 583 | :group 'message-interface |
| 594 | :link '(custom-manual "(message)Canceling News") | 584 | :link '(custom-manual "(message)Canceling News") |
| @@ -1744,7 +1734,7 @@ see `message-narrow-to-headers-or-head'." | |||
| 1744 | (goto-char (point-max)) | 1734 | (goto-char (point-max)) |
| 1745 | (if (string-match "\n$" (car headers)) | 1735 | (if (string-match "\n$" (car headers)) |
| 1746 | (insert (car headers)) | 1736 | (insert (car headers)) |
| 1747 | (insert (car headers) hard-newline))))) | 1737 | (insert (car headers) ?\n))))) |
| 1748 | (setq headers (cdr headers)))) | 1738 | (setq headers (cdr headers)))) |
| 1749 | 1739 | ||
| 1750 | (defmacro message-with-reply-buffer (&rest forms) | 1740 | (defmacro message-with-reply-buffer (&rest forms) |
| @@ -1851,7 +1841,7 @@ Leading \"Re: \" is not stripped by this function. Use the function | |||
| 1851 | (insert (concat "Subject: " | 1841 | (insert (concat "Subject: " |
| 1852 | new-subject | 1842 | new-subject |
| 1853 | " (was: " | 1843 | " (was: " |
| 1854 | old-subject ")" hard-newline))))))))) | 1844 | old-subject ")\n"))))))))) |
| 1855 | 1845 | ||
| 1856 | (defun message-mark-inserted-region (beg end) | 1846 | (defun message-mark-inserted-region (beg end) |
| 1857 | "Mark some region in the current article with enclosing tags. | 1847 | "Mark some region in the current article with enclosing tags. |
| @@ -1935,7 +1925,7 @@ With prefix-argument just set Follow-Up, don't cross-post." | |||
| 1935 | target-group | 1925 | target-group |
| 1936 | "[ \t]*$") | 1926 | "[ \t]*$") |
| 1937 | (message-fetch-field "Newsgroups"))) | 1927 | (message-fetch-field "Newsgroups"))) |
| 1938 | (insert (concat hard-newline "Followup-To: " target-group))) | 1928 | (insert (concat "\nFollowup-To: " target-group))) |
| 1939 | (setq message-cross-post-old-target target-group)) | 1929 | (setq message-cross-post-old-target target-group)) |
| 1940 | 1930 | ||
| 1941 | (defun message-cross-post-insert-note (target-group cross-post in-old | 1931 | (defun message-cross-post-insert-note (target-group cross-post in-old |
| @@ -1967,8 +1957,8 @@ been made to before the user asked for a Crosspost." | |||
| 1967 | (if (or in-old | 1957 | (if (or in-old |
| 1968 | (not cross-post) | 1958 | (not cross-post) |
| 1969 | (string-match "^[ \t]*poster[ \t]*$" target-group)) | 1959 | (string-match "^[ \t]*poster[ \t]*$" target-group)) |
| 1970 | (insert message-followup-to-note target-group hard-newline) | 1960 | (insert (concat message-followup-to-note target-group "\n")) |
| 1971 | (insert message-cross-post-note target-group hard-newline)))) | 1961 | (insert (concat message-cross-post-note target-group "\n"))))) |
| 1972 | 1962 | ||
| 1973 | (defun message-cross-post-followup-to (target-group) | 1963 | (defun message-cross-post-followup-to (target-group) |
| 1974 | "Crossposts message and set Followup-To to TARGET-GROUP. | 1964 | "Crossposts message and set Followup-To to TARGET-GROUP. |
| @@ -2028,7 +2018,7 @@ With prefix-argument just set Follow-Up, don't cross-post." | |||
| 2028 | (save-excursion | 2018 | (save-excursion |
| 2029 | (message-goto-to) | 2019 | (message-goto-to) |
| 2030 | (message-delete-line) | 2020 | (message-delete-line) |
| 2031 | (insert (concat "To: " cc-content hard-newline)) | 2021 | (insert (concat "To: " cc-content "\n")) |
| 2032 | (save-restriction | 2022 | (save-restriction |
| 2033 | (message-narrow-to-headers) | 2023 | (message-narrow-to-headers) |
| 2034 | (message-remove-header (if bcc | 2024 | (message-remove-header (if bcc |
| @@ -2793,7 +2783,7 @@ or in the synonym headers, defined by `message-header-synonyms'." | |||
| 2793 | (message-remove-header (symbol-name (car elem))) | 2783 | (message-remove-header (symbol-name (car elem))) |
| 2794 | (goto-char (point-min)) | 2784 | (goto-char (point-min)) |
| 2795 | (insert (symbol-name (car elem)) ": " | 2785 | (insert (symbol-name (car elem)) ": " |
| 2796 | (cdr elem) hard-newline)))))) | 2786 | (cdr elem) "\n")))))) |
| 2797 | 2787 | ||
| 2798 | (defun message-insert-newsgroups () | 2788 | (defun message-insert-newsgroups () |
| 2799 | "Insert the Newsgroups header from the article being replied to." | 2789 | "Insert the Newsgroups header from the article being replied to." |
| @@ -2823,7 +2813,7 @@ or in the synonym headers, defined by `message-header-synonyms'." | |||
| 2823 | (point) | 2813 | (point) |
| 2824 | (forward-line -2) | 2814 | (forward-line -2) |
| 2825 | (point))) | 2815 | (point))) |
| 2826 | (insert hard-newline) | 2816 | (insert "\n") |
| 2827 | (goto-char beg) | 2817 | (goto-char beg) |
| 2828 | (delete-region beg (progn (message-goto-body) | 2818 | (delete-region beg (progn (message-goto-body) |
| 2829 | (forward-line 2) | 2819 | (forward-line 2) |
| @@ -2842,7 +2832,7 @@ or in the synonym headers, defined by `message-header-synonyms'." | |||
| 2842 | (end-of-line -1)) | 2832 | (end-of-line -1)) |
| 2843 | (kill-region point (point)) | 2833 | (kill-region point (point)) |
| 2844 | (unless (bolp) | 2834 | (unless (bolp) |
| 2845 | (insert hard-newline)))) | 2835 | (insert "\n")))) |
| 2846 | 2836 | ||
| 2847 | (defun message-newline-and-reformat (&optional arg not-break) | 2837 | (defun message-newline-and-reformat (&optional arg not-break) |
| 2848 | "Insert four newlines, and then reformat if inside quoted text. | 2838 | "Insert four newlines, and then reformat if inside quoted text. |
| @@ -2984,15 +2974,15 @@ Prefix arg means justify as well." | |||
| 2984 | (goto-char (point-max)) | 2974 | (goto-char (point-max)) |
| 2985 | ;; Insert the signature. | 2975 | ;; Insert the signature. |
| 2986 | (unless (bolp) | 2976 | (unless (bolp) |
| 2987 | (insert hard-newline)) | 2977 | (insert "\n")) |
| 2988 | (when message-signature-insert-empty-line | 2978 | (when message-signature-insert-empty-line |
| 2989 | (insert hard-newline)) | 2979 | (insert "\n")) |
| 2990 | (insert "-- " hard-newline) | 2980 | (insert "-- \n") |
| 2991 | (if (eq signature t) | 2981 | (if (eq signature t) |
| 2992 | (insert-file-contents message-signature-file) | 2982 | (insert-file-contents message-signature-file) |
| 2993 | (insert signature)) | 2983 | (insert signature)) |
| 2994 | (goto-char (point-max)) | 2984 | (goto-char (point-max)) |
| 2995 | (or (bolp) (insert hard-newline))))) | 2985 | (or (bolp) (insert "\n"))))) |
| 2996 | 2986 | ||
| 2997 | (defun message-insert-importance-high () | 2987 | (defun message-insert-importance-high () |
| 2998 | "Insert header to mark message as important." | 2988 | "Insert header to mark message as important." |
| @@ -3002,7 +2992,7 @@ Prefix arg means justify as well." | |||
| 3002 | (message-narrow-to-headers) | 2992 | (message-narrow-to-headers) |
| 3003 | (message-remove-header "Importance")) | 2993 | (message-remove-header "Importance")) |
| 3004 | (message-goto-eoh) | 2994 | (message-goto-eoh) |
| 3005 | (insert "Importance: high" hard-newline))) | 2995 | (insert "Importance: high\n"))) |
| 3006 | 2996 | ||
| 3007 | (defun message-insert-importance-low () | 2997 | (defun message-insert-importance-low () |
| 3008 | "Insert header to mark message as unimportant." | 2998 | "Insert header to mark message as unimportant." |
| @@ -3012,7 +3002,7 @@ Prefix arg means justify as well." | |||
| 3012 | (message-narrow-to-headers) | 3002 | (message-narrow-to-headers) |
| 3013 | (message-remove-header "Importance")) | 3003 | (message-remove-header "Importance")) |
| 3014 | (message-goto-eoh) | 3004 | (message-goto-eoh) |
| 3015 | (insert "Importance: low" hard-newline))) | 3005 | (insert "Importance: low\n"))) |
| 3016 | 3006 | ||
| 3017 | (defun message-insert-or-toggle-importance () | 3007 | (defun message-insert-or-toggle-importance () |
| 3018 | "Insert a \"Importance: high\" header, or cycle through the header values. | 3008 | "Insert a \"Importance: high\" header, or cycle through the header values. |
| @@ -3034,7 +3024,7 @@ and `low'." | |||
| 3034 | (t | 3024 | (t |
| 3035 | "high"))))) | 3025 | "high"))))) |
| 3036 | (message-goto-eoh) | 3026 | (message-goto-eoh) |
| 3037 | (insert (format "Importance: %s" new) hard-newline)))) | 3027 | (insert (format "Importance: %s\n" new))))) |
| 3038 | 3028 | ||
| 3039 | (defun message-insert-disposition-notification-to () | 3029 | (defun message-insert-disposition-notification-to () |
| 3040 | "Request a disposition notification (return receipt) to this message. | 3030 | "Request a disposition notification (return receipt) to this message. |
| @@ -3045,11 +3035,10 @@ Note that this should not be used in newsgroups." | |||
| 3045 | (message-narrow-to-headers) | 3035 | (message-narrow-to-headers) |
| 3046 | (message-remove-header "Disposition-Notification-To")) | 3036 | (message-remove-header "Disposition-Notification-To")) |
| 3047 | (message-goto-eoh) | 3037 | (message-goto-eoh) |
| 3048 | (insert (format "Disposition-Notification-To: %s" | 3038 | (insert (format "Disposition-Notification-To: %s\n" |
| 3049 | (or (message-field-value "Reply-to") | 3039 | (or (message-field-value "Reply-to") |
| 3050 | (message-field-value "From") | 3040 | (message-field-value "From") |
| 3051 | (message-make-from))) | 3041 | (message-make-from)))))) |
| 3052 | hard-newline))) | ||
| 3053 | 3042 | ||
| 3054 | (defun message-elide-region (b e) | 3043 | (defun message-elide-region (b e) |
| 3055 | "Elide the text in the region. | 3044 | "Elide the text in the region. |
| @@ -3184,7 +3173,7 @@ However, if `message-yank-prefix' is non-nil, insert that prefix on each line." | |||
| 3184 | ;; Delete blank lines at the end of the buffer. | 3173 | ;; Delete blank lines at the end of the buffer. |
| 3185 | (goto-char (point-max)) | 3174 | (goto-char (point-max)) |
| 3186 | (unless (eolp) | 3175 | (unless (eolp) |
| 3187 | (insert hard-newline)) | 3176 | (insert "\n")) |
| 3188 | (while (and (zerop (forward-line -1)) | 3177 | (while (and (zerop (forward-line -1)) |
| 3189 | (looking-at "$")) | 3178 | (looking-at "$")) |
| 3190 | (message-delete-line)) | 3179 | (message-delete-line)) |
| @@ -3222,7 +3211,7 @@ prefix, and don't delete any headers." | |||
| 3222 | (funcall message-cite-function)) | 3211 | (funcall message-cite-function)) |
| 3223 | (message-exchange-point-and-mark) | 3212 | (message-exchange-point-and-mark) |
| 3224 | (unless (bolp) | 3213 | (unless (bolp) |
| 3225 | (insert hard-newline)) | 3214 | (insert ?\n)) |
| 3226 | (unless modified | 3215 | (unless modified |
| 3227 | (setq message-checksum (message-checksum)))))) | 3216 | (setq message-checksum (message-checksum)))))) |
| 3228 | 3217 | ||
| @@ -3280,13 +3269,13 @@ prefix, and don't delete any headers." | |||
| 3280 | (delete-region (point) end) | 3269 | (delete-region (point) end) |
| 3281 | (unless (search-backward "\n\n" start t) | 3270 | (unless (search-backward "\n\n" start t) |
| 3282 | ;; Insert a blank line if it is peeled off. | 3271 | ;; Insert a blank line if it is peeled off. |
| 3283 | (insert hard-newline))) | 3272 | (insert "\n"))) |
| 3284 | (goto-char start) | 3273 | (goto-char start) |
| 3285 | (while functions | 3274 | (while functions |
| 3286 | (funcall (pop functions))) | 3275 | (funcall (pop functions))) |
| 3287 | (when message-citation-line-function | 3276 | (when message-citation-line-function |
| 3288 | (unless (bolp) | 3277 | (unless (bolp) |
| 3289 | (insert hard-newline)) | 3278 | (insert "\n")) |
| 3290 | (funcall message-citation-line-function)))) | 3279 | (funcall message-citation-line-function)))) |
| 3291 | 3280 | ||
| 3292 | (eval-when-compile (defvar mail-citation-hook)) ;Compiler directive | 3281 | (eval-when-compile (defvar mail-citation-hook)) ;Compiler directive |
| @@ -3322,14 +3311,13 @@ prefix, and don't delete any headers." | |||
| 3322 | (funcall (pop functions))) | 3311 | (funcall (pop functions))) |
| 3323 | (when message-citation-line-function | 3312 | (when message-citation-line-function |
| 3324 | (unless (bolp) | 3313 | (unless (bolp) |
| 3325 | (insert hard-newline)) | 3314 | (insert "\n")) |
| 3326 | (funcall message-citation-line-function))))) | 3315 | (funcall message-citation-line-function))))) |
| 3327 | 3316 | ||
| 3328 | (defun message-insert-citation-line () | 3317 | (defun message-insert-citation-line () |
| 3329 | "Insert a simple citation line." | 3318 | "Insert a simple citation line." |
| 3330 | (when message-reply-headers | 3319 | (when message-reply-headers |
| 3331 | (insert (mail-header-from message-reply-headers) | 3320 | (insert (mail-header-from message-reply-headers) " writes:\n\n"))) |
| 3332 | " writes:" hard-newline hard-newline))) | ||
| 3333 | 3321 | ||
| 3334 | (defun message-position-on-field (header &rest afters) | 3322 | (defun message-position-on-field (header &rest afters) |
| 3335 | (let ((case-fold-search t)) | 3323 | (let ((case-fold-search t)) |
| @@ -3355,7 +3343,7 @@ prefix, and don't delete any headers." | |||
| 3355 | (when afters | 3343 | (when afters |
| 3356 | (re-search-forward "^[^ \t]" nil 'move) | 3344 | (re-search-forward "^[^ \t]" nil 'move) |
| 3357 | (beginning-of-line)) | 3345 | (beginning-of-line)) |
| 3358 | (insert header ": " hard-newline) | 3346 | (insert header ": \n") |
| 3359 | (forward-char -1) | 3347 | (forward-char -1) |
| 3360 | nil)))) | 3348 | nil)))) |
| 3361 | 3349 | ||
| @@ -3551,7 +3539,7 @@ It should typically alter the sending method in some way or other." | |||
| 3551 | ;; Make sure there's a newline at the end of the message. | 3539 | ;; Make sure there's a newline at the end of the message. |
| 3552 | (goto-char (point-max)) | 3540 | (goto-char (point-max)) |
| 3553 | (unless (bolp) | 3541 | (unless (bolp) |
| 3554 | (insert hard-newline)) | 3542 | (insert "\n")) |
| 3555 | ;; Make the hidden headers visible. | 3543 | ;; Make the hidden headers visible. |
| 3556 | (let ((points (message-text-with-property 'message-hidden))) | 3544 | (let ((points (message-text-with-property 'message-hidden))) |
| 3557 | (when points | 3545 | (when points |
| @@ -3656,7 +3644,7 @@ It should typically alter the sending method in some way or other." | |||
| 3656 | (goto-char (point-min)) | 3644 | (goto-char (point-min)) |
| 3657 | (re-search-forward | 3645 | (re-search-forward |
| 3658 | (concat "^" (regexp-quote mail-header-separator) "\n")) | 3646 | (concat "^" (regexp-quote mail-header-separator) "\n")) |
| 3659 | (replace-match hard-newline) | 3647 | (replace-match "\n") |
| 3660 | (run-hooks 'message-send-mail-hook) | 3648 | (run-hooks 'message-send-mail-hook) |
| 3661 | (let ((p (goto-char (point-min))) | 3649 | (let ((p (goto-char (point-min))) |
| 3662 | (tembuf (message-generate-new-buffer-clone-locals " message temp")) | 3650 | (tembuf (message-generate-new-buffer-clone-locals " message temp")) |
| @@ -3698,18 +3686,17 @@ It should typically alter the sending method in some way or other." | |||
| 3698 | (message-remove-header "Message-ID") | 3686 | (message-remove-header "Message-ID") |
| 3699 | (message-remove-header "Lines") | 3687 | (message-remove-header "Lines") |
| 3700 | (goto-char (point-max)) | 3688 | (goto-char (point-max)) |
| 3701 | (insert "Mime-Version: 1.0" hard-newline) | 3689 | (insert "Mime-Version: 1.0\n") |
| 3702 | (setq header (buffer-string))) | 3690 | (setq header (buffer-string))) |
| 3703 | (goto-char (point-max)) | 3691 | (goto-char (point-max)) |
| 3704 | (insert (format "Content-Type: message/partial; id=\"%s\"; number=%d; total=%d" | 3692 | (insert (format "Content-Type: message/partial; id=\"%s\"; number=%d; total=%d\n\n" |
| 3705 | id n total) | 3693 | id n total)) |
| 3706 | hard-newline hard-newline) | ||
| 3707 | (forward-char -1) | 3694 | (forward-char -1) |
| 3708 | (let ((mail-header-separator "")) | 3695 | (let ((mail-header-separator "")) |
| 3709 | (when (memq 'Message-ID message-required-mail-headers) | 3696 | (when (memq 'Message-ID message-required-mail-headers) |
| 3710 | (insert "Message-ID: " (message-make-message-id) hard-newline)) | 3697 | (insert "Message-ID: " (message-make-message-id) "\n")) |
| 3711 | (when (memq 'Lines message-required-mail-headers) | 3698 | (when (memq 'Lines message-required-mail-headers) |
| 3712 | (insert "Lines: " (message-make-lines) hard-newline)) | 3699 | (insert "Lines: " (message-make-lines) "\n")) |
| 3713 | (message-goto-subject) | 3700 | (message-goto-subject) |
| 3714 | (end-of-line) | 3701 | (end-of-line) |
| 3715 | (insert (format " (%d/%d)" n total)) | 3702 | (insert (format " (%d/%d)" n total)) |
| @@ -3774,7 +3761,7 @@ It should typically alter the sending method in some way or other." | |||
| 3774 | (goto-char (point-max)) | 3761 | (goto-char (point-max)) |
| 3775 | ;; require one newline at the end. | 3762 | ;; require one newline at the end. |
| 3776 | (or (= (preceding-char) ?\n) | 3763 | (or (= (preceding-char) ?\n) |
| 3777 | (insert hard-newline)) | 3764 | (insert ?\n)) |
| 3778 | (message-cleanup-headers) | 3765 | (message-cleanup-headers) |
| 3779 | ;; FIXME: we're inserting the courtesy copy after encoding. | 3766 | ;; FIXME: we're inserting the courtesy copy after encoding. |
| 3780 | ;; This is wrong if the courtesy copy string contains | 3767 | ;; This is wrong if the courtesy copy string contains |
| @@ -3850,7 +3837,7 @@ If you always want Gnus to send messages in one piece, set | |||
| 3850 | (goto-char (point-min)) | 3837 | (goto-char (point-min)) |
| 3851 | (re-search-forward | 3838 | (re-search-forward |
| 3852 | (concat "^" (regexp-quote mail-header-separator) "\n")) | 3839 | (concat "^" (regexp-quote mail-header-separator) "\n")) |
| 3853 | (replace-match hard-newline) | 3840 | (replace-match "\n") |
| 3854 | (backward-char 1) | 3841 | (backward-char 1) |
| 3855 | (setq delimline (point-marker)) | 3842 | (setq delimline (point-marker)) |
| 3856 | (run-hooks 'message-send-mail-hook) | 3843 | (run-hooks 'message-send-mail-hook) |
| @@ -3912,7 +3899,7 @@ to find out how to use this." | |||
| 3912 | (goto-char (point-min)) | 3899 | (goto-char (point-min)) |
| 3913 | (re-search-forward | 3900 | (re-search-forward |
| 3914 | (concat "^" (regexp-quote mail-header-separator) "\n")) | 3901 | (concat "^" (regexp-quote mail-header-separator) "\n")) |
| 3915 | (replace-match hard-newline) | 3902 | (replace-match "\n") |
| 3916 | (run-hooks 'message-send-mail-hook) | 3903 | (run-hooks 'message-send-mail-hook) |
| 3917 | ;; send the message | 3904 | ;; send the message |
| 3918 | (case | 3905 | (case |
| @@ -4080,13 +4067,13 @@ Otherwise, generate and save a value for `canlock-password' first." | |||
| 4080 | (goto-char (point-max)) | 4067 | (goto-char (point-max)) |
| 4081 | ;; require one newline at the end. | 4068 | ;; require one newline at the end. |
| 4082 | (or (= (preceding-char) ?\n) | 4069 | (or (= (preceding-char) ?\n) |
| 4083 | (insert hard-newline)) | 4070 | (insert ?\n)) |
| 4084 | (let ((case-fold-search t)) | 4071 | (let ((case-fold-search t)) |
| 4085 | ;; Remove the delimiter. | 4072 | ;; Remove the delimiter. |
| 4086 | (goto-char (point-min)) | 4073 | (goto-char (point-min)) |
| 4087 | (re-search-forward | 4074 | (re-search-forward |
| 4088 | (concat "^" (regexp-quote mail-header-separator) "\n")) | 4075 | (concat "^" (regexp-quote mail-header-separator) "\n")) |
| 4089 | (replace-match hard-newline) | 4076 | (replace-match "\n") |
| 4090 | (backward-char 1)) | 4077 | (backward-char 1)) |
| 4091 | (run-hooks 'message-send-news-hook) | 4078 | (run-hooks 'message-send-news-hook) |
| 4092 | (gnus-open-server method) | 4079 | (gnus-open-server method) |
| @@ -4213,7 +4200,7 @@ Otherwise, generate and save a value for `canlock-password' first." | |||
| 4213 | (message-tokenize-header | 4200 | (message-tokenize-header |
| 4214 | newsgroups))))))))) | 4201 | newsgroups))))))))) |
| 4215 | (goto-char (point-min)) | 4202 | (goto-char (point-min)) |
| 4216 | (insert "Followup-To: " to hard-newline)) | 4203 | (insert "Followup-To: " to "\n")) |
| 4217 | t)) | 4204 | t)) |
| 4218 | ;; Check "Shoot me". | 4205 | ;; Check "Shoot me". |
| 4219 | (message-check 'shoot | 4206 | (message-check 'shoot |
| @@ -5112,7 +5099,7 @@ Headers already prepared in the buffer are not modified." | |||
| 5112 | ;; We check whether the value was ended by a | 5099 | ;; We check whether the value was ended by a |
| 5113 | ;; newline. If now, we insert one. | 5100 | ;; newline. If now, we insert one. |
| 5114 | (unless (bolp) | 5101 | (unless (bolp) |
| 5115 | (insert hard-newline)) | 5102 | (insert "\n")) |
| 5116 | (forward-line -1))) | 5103 | (forward-line -1))) |
| 5117 | ;; The value of this header was empty, so we clear | 5104 | ;; The value of this header was empty, so we clear |
| 5118 | ;; totally and insert the new value. | 5105 | ;; totally and insert the new value. |
| @@ -5152,7 +5139,7 @@ Headers already prepared in the buffer are not modified." | |||
| 5152 | (beginning-of-line)) | 5139 | (beginning-of-line)) |
| 5153 | (when (or (message-news-p) | 5140 | (when (or (message-news-p) |
| 5154 | (string-match "@.+\\.." secure-sender)) | 5141 | (string-match "@.+\\.." secure-sender)) |
| 5155 | (insert "Sender: " secure-sender hard-newline)))) | 5142 | (insert "Sender: " secure-sender "\n")))) |
| 5156 | ;; Check for IDNA | 5143 | ;; Check for IDNA |
| 5157 | (message-idna-to-ascii-rhs)))) | 5144 | (message-idna-to-ascii-rhs)))) |
| 5158 | 5145 | ||
| @@ -5164,7 +5151,7 @@ Headers already prepared in the buffer are not modified." | |||
| 5164 | (message-narrow-to-headers) | 5151 | (message-narrow-to-headers) |
| 5165 | (when (setq newsgroups (message-fetch-field "newsgroups")) | 5152 | (when (setq newsgroups (message-fetch-field "newsgroups")) |
| 5166 | (goto-char (point-max)) | 5153 | (goto-char (point-max)) |
| 5167 | (insert "Posted-To: " newsgroups hard-newline))) | 5154 | (insert "Posted-To: " newsgroups "\n"))) |
| 5168 | (forward-line 1) | 5155 | (forward-line 1) |
| 5169 | (when message-courtesy-message | 5156 | (when message-courtesy-message |
| 5170 | (cond | 5157 | (cond |
| @@ -5183,7 +5170,7 @@ Headers already prepared in the buffer are not modified." | |||
| 5183 | (insert (capitalize (symbol-name header)) | 5170 | (insert (capitalize (symbol-name header)) |
| 5184 | ": " | 5171 | ": " |
| 5185 | (if (consp value) (car value) value) | 5172 | (if (consp value) (car value) value) |
| 5186 | hard-newline) | 5173 | "\n") |
| 5187 | (narrow-to-region (point-min) (1- (point-max))) | 5174 | (narrow-to-region (point-min) (1- (point-max))) |
| 5188 | (let (quoted last) | 5175 | (let (quoted last) |
| 5189 | (goto-char (point-min)) | 5176 | (goto-char (point-min)) |
| @@ -5197,7 +5184,7 @@ Headers already prepared in the buffer are not modified." | |||
| 5197 | (progn | 5184 | (progn |
| 5198 | (save-excursion | 5185 | (save-excursion |
| 5199 | (goto-char last) | 5186 | (goto-char last) |
| 5200 | (insert hard-newline "\t")) | 5187 | (insert "\n\t")) |
| 5201 | (setq last (1+ (point)))) | 5188 | (setq last (1+ (point)))) |
| 5202 | (setq last (1+ (point))))) | 5189 | (setq last (1+ (point))))) |
| 5203 | (setq quoted (not quoted))) | 5190 | (setq quoted (not quoted))) |
| @@ -5223,7 +5210,7 @@ If the current line has `message-yank-prefix', insert it on the new line." | |||
| 5223 | (insert (capitalize (symbol-name header)) | 5210 | (insert (capitalize (symbol-name header)) |
| 5224 | ": " | 5211 | ": " |
| 5225 | (if (consp value) (car value) value) | 5212 | (if (consp value) (car value) value) |
| 5226 | hard-newline) | 5213 | "\n") |
| 5227 | (save-restriction | 5214 | (save-restriction |
| 5228 | (narrow-to-region begin (point)) | 5215 | (narrow-to-region begin (point)) |
| 5229 | (fill-region-as-paragraph begin (point)) | 5216 | (fill-region-as-paragraph begin (point)) |
| @@ -5292,7 +5279,7 @@ than 988 characters long, and if they are not, trim them until they are." | |||
| 5292 | (let ((refstring (mapconcat #'identity refs " "))) | 5279 | (let ((refstring (mapconcat #'identity refs " "))) |
| 5293 | (if (and message-this-is-news message-cater-to-broken-inn) | 5280 | (if (and message-this-is-news message-cater-to-broken-inn) |
| 5294 | (insert (capitalize (symbol-name header)) ": " | 5281 | (insert (capitalize (symbol-name header)) ": " |
| 5295 | refstring hard-newline) | 5282 | refstring "\n") |
| 5296 | (message-fill-header header refstring))))) | 5283 | (message-fill-header header refstring))))) |
| 5297 | 5284 | ||
| 5298 | (defun message-position-point () | 5285 | (defun message-position-point () |
| @@ -5521,18 +5508,18 @@ are not included." | |||
| 5521 | (delete-region (point) (progn (forward-line -1) (point))) | 5508 | (delete-region (point) (progn (forward-line -1) (point))) |
| 5522 | (when message-default-headers | 5509 | (when message-default-headers |
| 5523 | (insert message-default-headers) | 5510 | (insert message-default-headers) |
| 5524 | (or (bolp) (insert hard-newline))) | 5511 | (or (bolp) (insert ?\n))) |
| 5525 | (put-text-property | 5512 | (put-text-property |
| 5526 | (point) | 5513 | (point) |
| 5527 | (progn | 5514 | (progn |
| 5528 | (insert mail-header-separator hard-newline) | 5515 | (insert mail-header-separator "\n") |
| 5529 | (1- (point))) | 5516 | (1- (point))) |
| 5530 | 'read-only nil) | 5517 | 'read-only nil) |
| 5531 | (forward-line -1) | 5518 | (forward-line -1) |
| 5532 | (when (message-news-p) | 5519 | (when (message-news-p) |
| 5533 | (when message-default-news-headers | 5520 | (when message-default-news-headers |
| 5534 | (insert message-default-news-headers) | 5521 | (insert message-default-news-headers) |
| 5535 | (or (bolp) (insert hard-newline))) | 5522 | (or (bolp) (insert ?\n))) |
| 5536 | (when message-generate-headers-first | 5523 | (when message-generate-headers-first |
| 5537 | (message-generate-headers | 5524 | (message-generate-headers |
| 5538 | (message-headers-to-generate | 5525 | (message-headers-to-generate |
| @@ -5543,7 +5530,7 @@ are not included." | |||
| 5543 | (when (message-mail-p) | 5530 | (when (message-mail-p) |
| 5544 | (when message-default-mail-headers | 5531 | (when message-default-mail-headers |
| 5545 | (insert message-default-mail-headers) | 5532 | (insert message-default-mail-headers) |
| 5546 | (or (bolp) (insert hard-newline))) | 5533 | (or (bolp) (insert ?\n))) |
| 5547 | (save-restriction | 5534 | (save-restriction |
| 5548 | (message-narrow-to-headers) | 5535 | (message-narrow-to-headers) |
| 5549 | (if message-alternative-emails | 5536 | (if message-alternative-emails |
| @@ -6025,14 +6012,14 @@ If ARG, allow editing of the cancellation message." | |||
| 6025 | (message-news) | 6012 | (message-news) |
| 6026 | (setq buf (set-buffer (get-buffer-create " *message cancel*")))) | 6013 | (setq buf (set-buffer (get-buffer-create " *message cancel*")))) |
| 6027 | (erase-buffer) | 6014 | (erase-buffer) |
| 6028 | (insert "Newsgroups: " newsgroups hard-newline | 6015 | (insert "Newsgroups: " newsgroups "\n" |
| 6029 | "From: " from hard-newline | 6016 | "From: " from "\n" |
| 6030 | "Subject: cmsg cancel " message-id hard-newline | 6017 | "Subject: cmsg cancel " message-id "\n" |
| 6031 | "Control: cancel " message-id hard-newline | 6018 | "Control: cancel " message-id "\n" |
| 6032 | (if distribution | 6019 | (if distribution |
| 6033 | (concat "Distribution: " distribution hard-newline) | 6020 | (concat "Distribution: " distribution "\n") |
| 6034 | "") | 6021 | "") |
| 6035 | mail-header-separator hard-newline | 6022 | mail-header-separator "\n" |
| 6036 | message-cancel-message) | 6023 | message-cancel-message) |
| 6037 | (run-hooks 'message-cancel-hook) | 6024 | (run-hooks 'message-cancel-hook) |
| 6038 | (unless arg | 6025 | (unless arg |
| @@ -6221,9 +6208,7 @@ Optional DIGEST will use digest to forward." | |||
| 6221 | 6208 | ||
| 6222 | (defun message-forward-make-body-plain (forward-buffer) | 6209 | (defun message-forward-make-body-plain (forward-buffer) |
| 6223 | (insert | 6210 | (insert |
| 6224 | hard-newline | 6211 | "\n-------------------- Start of forwarded message --------------------\n") |
| 6225 | "-------------------- Start of forwarded message --------------------" | ||
| 6226 | hard-newline) | ||
| 6227 | (let ((b (point)) e) | 6212 | (let ((b (point)) e) |
| 6228 | (insert | 6213 | (insert |
| 6229 | (with-temp-buffer | 6214 | (with-temp-buffer |
| @@ -6239,9 +6224,7 @@ Optional DIGEST will use digest to forward." | |||
| 6239 | (buffer-string))) | 6224 | (buffer-string))) |
| 6240 | (setq e (point)) | 6225 | (setq e (point)) |
| 6241 | (insert | 6226 | (insert |
| 6242 | hard-newline | 6227 | "\n-------------------- End of forwarded message --------------------\n") |
| 6243 | "-------------------- End of forwarded message --------------------" | ||
| 6244 | hard-newline) | ||
| 6245 | (when message-forward-ignored-headers | 6228 | (when message-forward-ignored-headers |
| 6246 | (save-restriction | 6229 | (save-restriction |
| 6247 | (narrow-to-region b e) | 6230 | (narrow-to-region b e) |
| @@ -6251,10 +6234,7 @@ Optional DIGEST will use digest to forward." | |||
| 6251 | (message-remove-header message-forward-ignored-headers t))))) | 6234 | (message-remove-header message-forward-ignored-headers t))))) |
| 6252 | 6235 | ||
| 6253 | (defun message-forward-make-body-mime (forward-buffer) | 6236 | (defun message-forward-make-body-mime (forward-buffer) |
| 6254 | (insert | 6237 | (insert "\n\n<#part type=message/rfc822 disposition=inline raw=t>\n") |
| 6255 | hard-newline hard-newline | ||
| 6256 | "<#part type=message/rfc822 disposition=inline raw=t>" | ||
| 6257 | hard-newline) | ||
| 6258 | (let ((b (point)) e) | 6238 | (let ((b (point)) e) |
| 6259 | (save-restriction | 6239 | (save-restriction |
| 6260 | (narrow-to-region (point) (point)) | 6240 | (narrow-to-region (point) (point)) |
| @@ -6264,13 +6244,10 @@ Optional DIGEST will use digest to forward." | |||
| 6264 | (replace-match "X-From-Line: ")) | 6244 | (replace-match "X-From-Line: ")) |
| 6265 | (goto-char (point-max))) | 6245 | (goto-char (point-max))) |
| 6266 | (setq e (point)) | 6246 | (setq e (point)) |
| 6267 | (insert "<#/part>" hard-newline))) | 6247 | (insert "<#/part>\n"))) |
| 6268 | 6248 | ||
| 6269 | (defun message-forward-make-body-mml (forward-buffer) | 6249 | (defun message-forward-make-body-mml (forward-buffer) |
| 6270 | (insert | 6250 | (insert "\n\n<#mml type=message/rfc822 disposition=inline>\n") |
| 6271 | hard-newline hard-newline | ||
| 6272 | "<#mml type=message/rfc822 disposition=inline>" | ||
| 6273 | hard-newline) | ||
| 6274 | (let ((b (point)) e) | 6251 | (let ((b (point)) e) |
| 6275 | (if (not message-forward-decoded-p) | 6252 | (if (not message-forward-decoded-p) |
| 6276 | (insert | 6253 | (insert |
| @@ -6293,7 +6270,7 @@ Optional DIGEST will use digest to forward." | |||
| 6293 | (replace-match "X-From-Line: ")) | 6270 | (replace-match "X-From-Line: ")) |
| 6294 | (goto-char (point-max)))) | 6271 | (goto-char (point-max)))) |
| 6295 | (setq e (point)) | 6272 | (setq e (point)) |
| 6296 | (insert "<#/mml>" hard-newline) | 6273 | (insert "<#/mml>\n") |
| 6297 | (when (and (not message-forward-decoded-p) | 6274 | (when (and (not message-forward-decoded-p) |
| 6298 | message-forward-ignored-headers) | 6275 | message-forward-ignored-headers) |
| 6299 | (save-restriction | 6276 | (save-restriction |
| @@ -6305,23 +6282,19 @@ Optional DIGEST will use digest to forward." | |||
| 6305 | 6282 | ||
| 6306 | (defun message-forward-make-body-digest-plain (forward-buffer) | 6283 | (defun message-forward-make-body-digest-plain (forward-buffer) |
| 6307 | (insert | 6284 | (insert |
| 6308 | hard-newline | 6285 | "\n-------------------- Start of forwarded message --------------------\n") |
| 6309 | "-------------------- Start of forwarded message --------------------" | ||
| 6310 | hard-newline) | ||
| 6311 | (let ((b (point)) e) | 6286 | (let ((b (point)) e) |
| 6312 | (mml-insert-buffer forward-buffer) | 6287 | (mml-insert-buffer forward-buffer) |
| 6313 | (setq e (point)) | 6288 | (setq e (point)) |
| 6314 | (insert | 6289 | (insert |
| 6315 | hard-newline | 6290 | "\n-------------------- End of forwarded message --------------------\n"))) |
| 6316 | "-------------------- End of forwarded message --------------------" | ||
| 6317 | hard-newline))) | ||
| 6318 | 6291 | ||
| 6319 | (defun message-forward-make-body-digest-mime (forward-buffer) | 6292 | (defun message-forward-make-body-digest-mime (forward-buffer) |
| 6320 | (insert hard-newline "<#multipart type=digest>" hard-newline) | 6293 | (insert "\n<#multipart type=digest>\n") |
| 6321 | (let ((b (point)) e) | 6294 | (let ((b (point)) e) |
| 6322 | (insert-buffer-substring forward-buffer) | 6295 | (insert-buffer-substring forward-buffer) |
| 6323 | (setq e (point)) | 6296 | (setq e (point)) |
| 6324 | (insert "<#/multipart>" hard-newline) | 6297 | (insert "<#/multipart>\n") |
| 6325 | (save-restriction | 6298 | (save-restriction |
| 6326 | (narrow-to-region b e) | 6299 | (narrow-to-region b e) |
| 6327 | (goto-char b) | 6300 | (goto-char b) |
| @@ -6826,7 +6799,7 @@ regexp VARSTR." | |||
| 6826 | (message-narrow-to-headers-or-head) | 6799 | (message-narrow-to-headers-or-head) |
| 6827 | (message-remove-header "Mime-Version") | 6800 | (message-remove-header "Mime-Version") |
| 6828 | (goto-char (point-max)) | 6801 | (goto-char (point-max)) |
| 6829 | (insert "MIME-Version: 1.0" hard-newline) | 6802 | (insert "MIME-Version: 1.0\n") |
| 6830 | (when lines | 6803 | (when lines |
| 6831 | (insert lines)) | 6804 | (insert lines)) |
| 6832 | (setq content-type-p | 6805 | (setq content-type-p |
| @@ -6846,7 +6819,7 @@ regexp VARSTR." | |||
| 6846 | ;; For unknown reason, MIME-Version doesn't exist. | 6819 | ;; For unknown reason, MIME-Version doesn't exist. |
| 6847 | (when (re-search-forward "^MIME-Version:" nil t) | 6820 | (when (re-search-forward "^MIME-Version:" nil t) |
| 6848 | (forward-line 1) | 6821 | (forward-line 1) |
| 6849 | (insert "Content-Type: text/plain; charset=us-ascii" hard-newline)))))) | 6822 | (insert "Content-Type: text/plain; charset=us-ascii\n")))))) |
| 6850 | 6823 | ||
| 6851 | (defun message-read-from-minibuffer (prompt &optional initial-contents) | 6824 | (defun message-read-from-minibuffer (prompt &optional initial-contents) |
| 6852 | "Read from the minibuffer while providing abbrev expansion." | 6825 | "Read from the minibuffer while providing abbrev expansion." |
| @@ -6875,7 +6848,7 @@ regexp VARSTR." | |||
| 6875 | (pop emails)) | 6848 | (pop emails)) |
| 6876 | (unless (or (not email) (equal email user-mail-address)) | 6849 | (unless (or (not email) (equal email user-mail-address)) |
| 6877 | (goto-char (point-max)) | 6850 | (goto-char (point-max)) |
| 6878 | (insert "From: " email hard-newline)))) | 6851 | (insert "From: " email "\n")))) |
| 6879 | 6852 | ||
| 6880 | (defun message-options-get (symbol) | 6853 | (defun message-options-get (symbol) |
| 6881 | (cdr (assq symbol message-options))) | 6854 | (cdr (assq symbol message-options))) |