(mime-editor/define-charset): Argument `charset' was changed to
authormorioka <morioka>
Wed, 10 Jul 1996 11:41:57 +0000 (11:41 +0000)
committermorioka <morioka>
Wed, 10 Jul 1996 11:41:57 +0000 (11:41 +0000)
symbol.
(mime-editor/choose-charset): Changed to return symbol.
(mime-editor/normalize-body): charset was changed to symbol.

mime-edit.el

index c2c5783..c8fb068 100644 (file)
@@ -9,7 +9,7 @@
 ;;; Maintainer: MORIOKA Tomohiko <morioka@jaist.ac.jp>
 ;;; Created: 1994/08/21 renamed from mime.el by UMEDA Masanobu;
 ;;;          1996/05/24 renamed from tm-edit.el
-;;; Version: $Revision: 0.32 $
+;;; Version: $Revision: 0.33 $
 ;;; Keywords: mail, news, MIME, multimedia, multilingual
 ;;;
 ;;; This file is part of SEMI (September, Emacs MIME Interface)
 ;;;
 
 (defconst mime-editor/RCS-ID
-  "$Id: mime-edit.el,v 0.32 1996-07-10 11:22:55 morioka Exp $")
+  "$Id: mime-edit.el,v 0.33 1996-07-10 11:41:57 morioka Exp $")
 
 (defconst mime-editor/version (get-version-string mime-editor/RCS-ID))
 
@@ -1170,7 +1170,8 @@ Optional argument ENCODING specifies an encoding method such as base64."
          (insert
           (mime-create-tag
            (mime-editor/set-parameter
-            (mime-editor/get-contype tag) "charset" charset)
+            (mime-editor/get-contype tag)
+            "charset" (upcase (symbol-name charset)))
            (mime-editor/get-encoding tag)))
          ))))
 
@@ -1185,9 +1186,7 @@ Optional argument ENCODING specifies an encoding method such as base64."
 
 (defun mime-editor/choose-charset ()
   "Choose charset of a text following current point."
-  (upcase
-   (symbol-name
-    (detect-mime-charset-region (point) (mime-editor/content-end))))
+  (detect-mime-charset-region (point) (mime-editor/content-end))
   )
 
 (defun mime-make-text-tag (&optional subtype)
@@ -1950,7 +1949,7 @@ Content-Transfer-Encoding: 7bit
   (while (re-search-forward mime-editor/single-part-tag-regexp nil t)
     (let* ((tag (buffer-substring (match-beginning 0) (match-end 0)))
           (contype (mime-editor/get-contype tag))
-          (charset (mime-get-parameter contype "charset"))
+          (charset (intern (downcase (mime-get-parameter contype "charset"))))
           (encoding (mime-editor/get-encoding tag)))
       ;; Remove extra whitespaces after the tag.
       (if (looking-at "[ \t]+$")
@@ -2000,13 +1999,13 @@ Content-Transfer-Encoding: 7bit
        (or encoding    ;Encoding is not specified.
            (let* ((encoding
                    (cdr
-                    (assoc charset
-                           mime-editor/charset-default-encoding-alist)
+                    (assq charset
+                          mime-editor/charset-default-encoding-alist)
                     ))
                   (beg (mime-editor/content-beginning))
                   )
              (mime-charset-encode-region beg (mime-editor/content-end)
-                                         charset)
+                                         (upcase (symbol-name charset)))
              (mime-encode-region beg (mime-editor/content-end) encoding)
              (mime-editor/define-encoding encoding)
              ))