From d395f1429cee3bc264caa3cc6b936257dd632054 Mon Sep 17 00:00:00 2001 From: yamaoka Date: Mon, 9 Jun 2003 08:39:48 +0000 Subject: [PATCH] * message.el (message-fix-before-sending): Don't check for `illegible text' messages (see the comment). --- ChangeLog | 5 +++ lisp/message.el | 96 +++++++++++++++++++++++++++++-------------------------- 2 files changed, 55 insertions(+), 46 deletions(-) diff --git a/ChangeLog b/ChangeLog index f15393f..4e33638 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2003-06-09 Katsumi Yamaoka + + * lisp/message.el (message-fix-before-sending): Don't check for + `illegible text' messages (see the comment). + 2003-05-22 Katsumi Yamaoka * lisp/gnus-vers.el (gnus-revision-number): Increment to 01. diff --git a/lisp/message.el b/lisp/message.el index ff8da24..d8d8e15 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -3818,52 +3818,56 @@ used to distinguish whether the invisible text is a MIME part or not." (unless (yes-or-no-p "Invisible text found and made visible; continue sending? ") (error "Invisible text found and made visible"))))) - (message-check 'illegible-text - (let ((mm-7bit-chars "\x20-\x7f\r\n\t\x7\x8\xb\xc\x1f\x1b") - found choice) - (message-goto-body) - (skip-chars-forward mm-7bit-chars) - (while (not (eobp)) - (when (let ((char (char-after))) - (or (< (mm-char-int char) 128) - (and (mm-multibyte-p) - (> (length (mm-find-mime-charset-region - (point) (point-max))) - 1)))) - (message-overlay-put (message-make-overlay (point) (1+ (point))) - 'face 'highlight) - (setq found t)) - (forward-char) - (skip-chars-forward mm-7bit-chars)) - (when found - (setq choice - (gnus-multiple-choice - "Non-printable characters found. Continue sending?" - '((?d "Remove non-printable characters and send") - (?r "Replace non-printable characters with dots and send") - (?i "Ignore non-printable characters and send") - (?e "Continue editing")))) - (if (eq choice ?e) - (error "Non-printable characters")) - (message-goto-body) - (skip-chars-forward mm-7bit-chars) - (while (not (eobp)) - (when (let ((char (char-after))) - (or (< (mm-char-int char) 128) - (and (mm-multibyte-p) - ;; Fixme: Wrong for Emacs 22 and for things - ;; like undecable utf-8. Should at least - ;; use find-coding-systems-region. - (memq (char-charset char) - '(eight-bit-control eight-bit-graphic - control-1))))) - (if (eq choice ?i) - (message-kill-all-overlays) - (delete-char 1) - (when (eq choice ?r) - (insert ".")))) - (forward-char) - (skip-chars-forward mm-7bit-chars)))))) +;; The following check is needless to T-gnus since T-gnus determines +;; a MIME charset forcibly (even if it cannot be determined properly, +;; the value of the `default-mime-charset-for-write' variable is used). +;; (message-check 'illegible-text +;; (let ((mm-7bit-chars "\x20-\x7f\r\n\t\x7\x8\xb\xc\x1f\x1b") +;; found choice) +;; (message-goto-body) +;; (skip-chars-forward mm-7bit-chars) +;; (while (not (eobp)) +;; (when (let ((char (char-after))) +;; (or (< (mm-char-int char) 128) +;; (and (mm-multibyte-p) +;; (> (length (mm-find-mime-charset-region +;; (point) (point-max))) +;; 1)))) +;; (message-overlay-put (message-make-overlay (point) (1+ (point))) +;; 'face 'highlight) +;; (setq found t)) +;; (forward-char) +;; (skip-chars-forward mm-7bit-chars)) +;; (when found +;; (setq choice +;; (gnus-multiple-choice +;; "Non-printable characters found. Continue sending?" +;; '((?d "Remove non-printable characters and send") +;; (?r "Replace non-printable characters with dots and send") +;; (?i "Ignore non-printable characters and send") +;; (?e "Continue editing")))) +;; (if (eq choice ?e) +;; (error "Non-printable characters")) +;; (message-goto-body) +;; (skip-chars-forward mm-7bit-chars) +;; (while (not (eobp)) +;; (when (let ((char (char-after))) +;; (or (< (mm-char-int char) 128) +;; (and (mm-multibyte-p) +;; ;; Fixme: Wrong for Emacs 22 and for things +;; ;; like undecable utf-8. Should at least +;; ;; use find-coding-systems-region. +;; (memq (char-charset char) +;; '(eight-bit-control eight-bit-graphic +;; control-1))))) +;; (if (eq choice ?i) +;; (message-kill-all-overlays) +;; (delete-char 1) +;; (when (eq choice ?r) +;; (insert ".")))) +;; (forward-char) +;; (skip-chars-forward mm-7bit-chars))))) + ) (defun message-add-action (action &rest types) "Add ACTION to be performed when doing an exit of type TYPES." -- 1.7.10.4