;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
;; Version:
-;; $Id: mime-text.el,v 0.16 1997-03-15 23:53:49 morioka Exp $
+;; $Id: mime-text.el,v 0.17 1997-03-15 23:58:06 morioka Exp $
;; Keywords: text, MIME, multimedia, mail, news
;; This file is part of SEMI (SEMI is Emacs MIME Interfaces).
;;; @ buffer local variables in raw-buffer
;;;
-(defvar mime-raw::text-decoder nil
+(defvar mime-text-decoder nil
"Function to decode text in current buffer.
Interface of the function is (CHARSET &optional ENCODING).
CHARSET is symbol of MIME charset and ENCODING is value of
-Content-Transfer-Encoding.")
-(make-variable-buffer-local 'mime-raw::text-decoder)
+Content-Transfer-Encoding.
+
+Notice that this variable is usually used as buffer local variable in
+raw-buffer.")
+
+(make-variable-buffer-local 'mime-text-decoder)
;;; @ code conversion
(defun mime-preview/decode-text-buffer (charset encoding)
(mime-decode-region (point-min) (point-max) encoding)
- (let ((m (save-excursion
- (set-buffer mime::preview/article-buffer)
- (or mime-raw::text-decoder
- (cdr (or (assq major-mode mime-text-decoder-alist)
- (assq t mime-text-decoder-alist)))
- ))))
- (and (functionp m)
- (funcall m charset encoding)
+ (let ((text-decoder
+ (save-excursion
+ (set-buffer mime::preview/article-buffer)
+ (or mime-text-decoder
+ (cdr (or (assq major-mode mime-text-decoder-alist)
+ (assq t mime-text-decoder-alist)))
+ ))))
+ (and (functionp text-decoder)
+ (funcall text-decoder charset encoding)
)))