Initial Commit
[packages] / xemacs-packages / tm / message-mime.el
1 ;;; message-mime.el --- MIME extensions for message.el
2
3 ;; Copyright (C) 1995,1996 Free Software Foundation, Inc.
4
5 ;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
6 ;; Created: 1996/8/6
7 ;; Version:
8 ;;      $Id: message-mime.el,v 1.2 2000-07-09 11:59:31 adrian Exp $
9 ;; Keywords: news, MIME, multimedia, multilingual, encoded-word
10
11 ;; This file is not part of GNU Emacs yet.
12
13 ;; This program is free software; you can redistribute it and/or
14 ;; modify it under the terms of the GNU General Public License as
15 ;; published by the Free Software Foundation; either version 2, or (at
16 ;; your option) any later version.
17
18 ;; This program is distributed in the hope that it will be useful, but
19 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
21 ;; General Public License for more details.
22
23 ;; You should have received a copy of the GNU General Public License
24 ;; along with This program.  If not, write to the Free Software
25 ;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
26
27 ;;; Code:
28
29 (require 'tm-edit)
30
31 (setq message-forward-start-separator
32       (concat (mime-make-tag "message" "rfc822") "\n"))
33
34 (setq message-forward-end-separator "")
35
36 (when (boundp 'message-included-forward-headers)
37   (or (string-match message-included-forward-headers "Mime-Version:")
38       (setq message-included-forward-headers
39             (concat message-included-forward-headers "\\|^Mime-Version:"))
40       )
41
42   (or (string-match message-included-forward-headers "Content-Type:")
43       (setq message-included-forward-headers
44             (concat message-included-forward-headers "\\|^Content-Type:"))
45       )
46
47   (or (string-match message-included-forward-headers
48                     "Content-Transfer-Encoding:")
49       (setq message-included-forward-headers
50             (concat message-included-forward-headers
51                     "\\|^Content-Transfer-Encoding:"))
52       ))
53
54 ;;; @ for tm-edit
55 ;;;
56
57 ;; suggested by OKABE Yasuo <okabe@kudpc.kyoto-u.ac.jp>
58 ;;      1995/11/08 (c.f. [tm ML:1067])
59 (defun message-mime-insert-article (&optional message)
60   (interactive)
61   (let ((message-cite-function 'mime-editor/inserted-message-filter)
62         (message-reply-buffer gnus-original-article-buffer)
63         )
64     (message-yank-original nil)
65     ))
66
67 (set-alist 'mime-editor/message-inserter-alist
68            'message-mode (function message-mime-insert-article))
69 (set-alist 'mime-editor/split-message-sender-alist
70            'message-mode
71            (lambda ()
72              (interactive)
73              (let (message-send-hook
74                    message-sent-message-via)
75                (message-send)
76                )))
77
78
79 ;;; @ end
80 ;;;
81
82 (provide 'message-mime)
83
84 ;;; message-mime.el ends here