From: yamaoka Date: Fri, 2 Feb 2001 10:43:09 +0000 (+0000) Subject: Synch with Oort Gnus. X-Git-Tag: t-gnus-6_15_0-05-quimby-last-~15 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=61643c4fd23d52b1d157d44d0a4f5a6155a22ec8;p=elisp%2Fgnus.git- Synch with Oort Gnus. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b1f6e2a..89b951f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,34 @@ +2001-01-31 Dave Love + + * mm-util.el (mm-mime-mule-charset-alist) + (mm-find-mime-charset-region): Consider mule-utf-8. + +2001-01-31 Dave Love + + * gnus-art.el (gnus-article-x-face-command) + (gnus-treat-display-xface, gnus-treat-display-smileys): Add + :version. + +2001-01-26 Dave Love + + * mm-util.el (mm-multibyte-string-p): New. + +;; * qp.el: Remove un-logged bogus changes from 2000-12-20. +;; (quoted-printable-encode-region): Doc fix. Don't call +;; string-as-multibyte on class. Clarify line-folding. + (quoted-printable-encode-string): Make temp buffer inherit + string's multibyteness. + +2001-01-23 Gerd Moellmann + + * nnheader.el (toplevel): Don't require `gnus-util' at + compile-time; this creates a circular dependency, and prevents + a bootstrap. + +2001-01-22 Andreas Schwab + + * nnheader.el (gnus-delete-line): Autoload it as a macro. + 2001-01-31 18:00:00 ShengHuo ZHU * nnmail.el (nnmail-remove-list-identifiers): Use consp. diff --git a/lisp/gnus-art.el b/lisp/gnus-art.el index fddef97..2cd1726 100644 --- a/lisp/gnus-art.el +++ b/lisp/gnus-art.el @@ -247,6 +247,7 @@ asynchronously. The compressed face will be piped to this command." (function-item gnus-article-display-xface) (function-item x-face-mule-gnus-article-display-x-face) function) + ;;:version "21.1" :group 'gnus-article-washing) (defcustom gnus-article-x-face-too-ugly nil @@ -1036,6 +1037,7 @@ See the manual for details." Valid values are nil, t, `head', `last', an integer or a predicate. See the manual for details." :group 'gnus-article-treat + ;;:version "21.1" :type gnus-article-treat-head-custom) (put 'gnus-treat-display-xface 'highlight t) @@ -1053,6 +1055,7 @@ See the manual for details." Valid values are nil, t, `head', `last', an integer or a predicate. See the manual for details." :group 'gnus-article-treat + ;;:version "21.1" :type gnus-article-treat-custom) (put 'gnus-treat-display-smileys 'highlight t) diff --git a/lisp/mm-util.el b/lisp/mm-util.el index c3d237a..6d1e2fd 100644 --- a/lisp/mm-util.el +++ b/lisp/mm-util.el @@ -30,7 +30,7 @@ (require 'mail-prsvr) (defvar mm-mime-mule-charset-alist - '((us-ascii ascii) + `((us-ascii ascii) (iso-8859-1 latin-iso8859-1) (iso-8859-2 latin-iso8859-2) (iso-8859-3 latin-iso8859-3) @@ -73,7 +73,11 @@ chinese-cns11643-3 chinese-cns11643-4 chinese-cns11643-5 chinese-cns11643-6 chinese-cns11643-7) - (utf-8 unicode-a unicode-b unicode-c unicode-d unicode-e)) + ,(if (or (charsetp 'unicode-a) + (not (coding-system-p 'mule-utf-8))) + '(utf-8 unicode-a unicode-b unicode-c unicode-d unicode-e) + ;; If we have utf-8 we're in Mule 5+. + (delete 'ascii (coding-system-get 'mule-utf-8 'safe-charsets)))) "Alist of MIME-charset/MULE-charsets.") (eval-and-compile @@ -124,7 +128,8 @@ (setq idx (1+ idx))) string))) (string-as-unibyte . identity) - ))) + (multibyte-string-p . ignore) + ))) (eval-and-compile (defalias 'mm-char-or-char-int-p @@ -301,6 +306,7 @@ If the charset is `composition', return the actual one." (setq mail-parse-mule-charset (or (car (last (assq mail-parse-charset mm-mime-mule-charset-alist))) + ;; Fixme: don't fix that! 'latin-iso8859-1))) mail-parse-mule-charset))))))) @@ -340,7 +346,8 @@ If the charset is `composition', return the actual one." (setq charsets (mm-delete-duplicates charsets)) (if (and (> (length charsets) 1) (fboundp 'find-coding-systems-region) - (memq 'utf-8 (find-coding-systems-region b e))) + (let ((cs (find-coding-systems-region b e))) + (or (memq 'utf-8 cs) (memq 'mule-utf-8 cs)))) '(utf-8) charsets))) diff --git a/lisp/nnheader.el b/lisp/nnheader.el index 4354a9b..f8b84f5 100644 --- a/lisp/nnheader.el +++ b/lisp/nnheader.el @@ -1,7 +1,7 @@ ;;; nnheader.el --- header access macros for Semi-gnus and its backends ;; Copyright (C) 1987, 1988, 1989, 1990, 1993, 1994, 1995, 1996, -;; 1997, 1998, 2000 +;; 1997, 1998, 2000, 2001 ;; Free Software Foundation, Inc. ;; Author: Masanobu UMEDA @@ -34,6 +34,10 @@ (eval-when-compile (require 'cl)) (eval-when-compile (require 'static)) +;; Requiring `gnus-util' at compile time creates a circular +;; dependency between nnheader.el and gnus-util.el. +;(eval-when-compile (require 'gnus-util)) + (require 'mail-utils) ;; Reduce the required value of `recursive-load-depth-limit' for Emacs 21. @@ -76,7 +80,7 @@ This variable is a substitute for `mm-text-coding-system-for-write'.") (autoload 'mail-position-on-field "sendmail") (autoload 'message-remove-header "message") (autoload 'gnus-point-at-eol "gnus-util") - (autoload 'gnus-delete-line "gnus-util") + (autoload 'gnus-delete-line "gnus-util" nil nil 'macro) (autoload 'gnus-buffer-live-p "gnus-util")) ;;; Header access macros. diff --git a/lisp/qp.el b/lisp/qp.el index 2f63abf..0e0f960 100644 --- a/lisp/qp.el +++ b/lisp/qp.el @@ -1,6 +1,6 @@ ;;; qp.el --- Quoted-Printable functions -;; Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail, extensions @@ -85,8 +85,9 @@ If CODING-SYSTEM is non-nil, decode the region with coding-system." "Quoted-printable encode the region between FROM and TO per RFC 2045. If FOLD, fold long lines at 76 characters (as required by the RFC). -If CLASS is non-nil, translate the characters matched by that class in -the form expected by `skip-chars-forward'. +If CLASS is non-nil, translate the characters not matched by that +regexp class, which is in the form expected by `skip-chars-forward'. +You should probably avoid non-ASCII characters in this arg. If `mm-use-ultra-safe-encoding' is set, fold lines unconditionally and encode lines starting with \"From\"." @@ -95,8 +96,6 @@ encode lines starting with \"From\"." ;; Avoid using 8bit characters. = is \075. ;; Equivalent to "^\000-\007\013\015-\037\200-\377=" (setq class "\010-\012\014\040-\074\076-\177")) - (if (fboundp 'string-as-multibyte) - (setq class (string-as-multibyte class))) (save-excursion (save-restriction (narrow-to-region from to) @@ -130,34 +129,33 @@ encode lines starting with \"From\"." (and (boundp 'mm-use-ultra-safe-encoding) mm-use-ultra-safe-encoding))) (when (or fold mm-use-ultra-safe-encoding) - ;; Fold long lines. - (let ((tab-width 1)) ; HTAB is one character. + (let ((tab-width 1)) ; HTAB is one character. (goto-char (point-min)) (while (not (eobp)) ;; In ultra-safe mode, encode "From " at the beginning ;; of a line. (when mm-use-ultra-safe-encoding - (beginning-of-line) (if (looking-at "From ") (replace-match "From=20" nil t) (if (looking-at "-") (replace-match "=2D" nil t)))) (end-of-line) - (while (> (current-column) 76) ; tab-width must be 1. - (beginning-of-line) - (forward-char 75) ; 75 chars plus an "=" - (search-backward "=" (- (point) 2) t) - (insert "=\n") - (end-of-line)) - (unless (eobp) - (forward-line)))))))))) + ;; Fold long lines. + (while (> (current-column) 76) ; tab-width must be 1. + (beginning-of-line) + (forward-char 75) ; 75 chars plus an "=" + (search-backward "=" (- (point) 2) t) + (insert "=\n") + (end-of-line)) + (forward-line))))))))) (defun quoted-printable-encode-string (string) "Encode the STRING as quoted-printable and return the result." - (with-temp-buffer - (insert string) - (quoted-printable-encode-region (point-min) (point-max)) - (buffer-string))) + (let ((default-enable-multibyte-characters (mm-multibyte-string-p string))) + (with-temp-buffer + (insert string) + (quoted-printable-encode-region (point-min) (point-max)) + (buffer-string)))) (provide 'qp)