From 64bf21cf0eb09bca9f0b7c1c567060b221ec7a00 Mon Sep 17 00:00:00 2001 From: morioka Date: Fri, 14 Mar 1997 08:48:46 +0000 Subject: [PATCH] *** empty log message *** --- emh-setup.el | 73 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 73 insertions(+) create mode 100644 emh-setup.el diff --git a/emh-setup.el b/emh-setup.el new file mode 100644 index 0000000..8f25f46 --- /dev/null +++ b/emh-setup.el @@ -0,0 +1,73 @@ +;;; emh-setup.el --- setup file for emh. + +;; Copyright (C) 1994,1995,1996,1997 Free Software Foundation, Inc. + +;; Author: MORIOKA Tomohiko +;; Version: $Id: emh-setup.el,v 0.0 1997-03-14 08:48:46 morioka Exp $ +;; Keywords: mail, news, MIME, multimedia, multilingual, encoded-word + +;; This file is part of SEMI (SEMI is Emacs MIME Interfaces). + +;; This program is free software; you can redistribute it and/or +;; modify it under the terms of the GNU General Public License as +;; published by the Free Software Foundation; either version 2, or (at +;; your option) any later version. + +;; This program is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + +;;; Code: + +(require 'semi-setup) + + +;;; @ for emh +;;; + +(defun emh-setup () + (require 'emh) + ) + +(call-after-loaded 'mh-e 'emh-setup 'mh-folder-mode-hook) +(or (featurep 'mh-e) + (add-hook 'mh-letter-mode-hook 'emh-setup) + ) + + +;;; @ for mime-edit +;;; + +(autoload 'turn-on-mime-edit "mime-edit" + "Unconditionally turn on MIME-Edit minor mode." t) + +(defun emh-setup-mh-draft-setting () + (turn-on-mime-edit) + (make-local-variable 'mail-header-separator) + (setq mail-header-separator "--------") + (save-excursion + (goto-char (point-min)) + (setq buffer-read-only nil) + (if (re-search-forward "^-*$" nil t) + (progn + (replace-match mail-header-separator) + (set-buffer-modified-p (buffer-modified-p)) + )) + )) + +(add-hook 'mh-letter-mode-hook 'emh-setup-mh-draft-setting t) +(add-hook 'mh-before-send-letter-hook 'mime-edit-maybe-translate) + + +;;; @ end +;;; + +(provide 'emh-setup) + +;;; emh-setup.el ends here -- 1.7.10.4