X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=tm-setup.el;h=f34590c1833453c864ff10b990be9c7121405d2f;hb=d0e835431b16267ad1e0fa6760d483802db2693b;hp=151047feb1bed66d59bae699dae2320dc43ea84d;hpb=ce5017c15f724ff6eb7d906504d3a495dbe21f9a;p=elisp%2Ftm.git diff --git a/tm-setup.el b/tm-setup.el index 151047f..f34590c 100644 --- a/tm-setup.el +++ b/tm-setup.el @@ -1,30 +1,28 @@ -;;; ;;; tm-setup.el --- setup file for tm viewer. -;;; -;;; Copyright (C) 1995 Free Software Foundation, Inc. -;;; Copyright (C) 1994 .. 1996 MORIOKA Tomohiko -;;; -;;; Author: MORIOKA Tomohiko -;;; Version: -;;; $Id: tm-setup.el,v 7.4 1996/08/06 12:12:53 morioka Exp $ -;;; Keywords: mail, news, MIME, multimedia, multilingual, encoded-word -;;; -;;; This file is part of tm (Tools for MIME). -;;; -;;; 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 This program. If not, write to the Free Software -;;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. -;;; + +;; Copyright (C) 1994,1995,1996 Free Software Foundation, Inc. + +;; Author: MORIOKA Tomohiko +;; Version: $Id: tm-setup.el,v 7.7 1996/08/31 14:39:06 morioka Exp $ +;; Keywords: mail, news, MIME, multimedia, multilingual, encoded-word + +;; This file is part of tm (Tools for MIME). + +;; 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 This program; 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 'tl-misc) @@ -47,12 +45,7 @@ (method . mime/decode-message/external-ftp) )) (autoload 'mime/decode-message/external-ftp "tm-ftp") - - ;; for image/* - (if running-xemacs - (require 'tm-image) - ) - + ;; for LaTeX (set-atype 'mime/content-decoding-condition '((type . "text/x-latex") @@ -70,6 +63,24 @@ (autoload 'mime/decode-text/latex "tm-latex") ))) +;; for image/* and X-Face +(if running-xemacs + (call-after-loaded 'tm-view + (function + (lambda () + (require 'tm-image) + ))) + ) + +;; for PGP +(if (module-installed-p 'mailcrypt) + (call-after-loaded 'tm-view + (function + (lambda () + (require 'tm-pgp) + ))) + ) + ;;; @ for RMAIL ;;; @@ -96,40 +107,44 @@ )) -;;; @ for GNUS +;;; @ for GNUS and Gnus ;;; -(defvar tm-setup/use-gnusutil nil) - -(defun tm-setup/load-GNUS () - (require 'tm-gnus) - ) - -(if (and (boundp 'MULE) tm-setup/use-gnusutil) - (progn - (add-hook 'gnus-Group-mode-hook (function gnusutil-initialize)) - (add-hook 'gnus-group-mode-hook (function gnusutil-initialize)) - (autoload 'gnusutil-initialize "gnusutil") - (autoload 'gnusutil-add-group "gnusutil") - (add-hook 'gnusutil-initialize-hook 'tm-setup/load-GNUS) +(if (featurep 'gnus) + (if (boundp 'gnus-load-hook) + (require 'gnus-mime) + (require 'tm-gnus) ) - (add-hook 'gnus-Startup-hook 'tm-setup/load-GNUS 'append) - (add-hook 'gnus-startup-hook 'tm-setup/load-GNUS 'append) + ;; for GNUS + (defvar tm-setup/use-gnusutil nil) + + (defun tm-setup/load-GNUS () + (require 'tm-gnus) + ) + + (if (and (boundp 'MULE) tm-setup/use-gnusutil) + (progn + (add-hook 'gnus-Group-mode-hook (function gnusutil-initialize)) + (add-hook 'gnus-group-mode-hook (function gnusutil-initialize)) + (autoload 'gnusutil-initialize "gnusutil") + (autoload 'gnusutil-add-group "gnusutil") + (add-hook 'gnusutil-initialize-hook 'tm-setup/load-GNUS) + ) + (add-hook 'gnus-Startup-hook 'tm-setup/load-GNUS 'append) + (add-hook 'gnus-startup-hook 'tm-setup/load-GNUS 'append) + ) + + ;; for Gnus + (defun tm-setup/load-gnus () + (let (gnus-load-hook) + (remove-hook 'gnus-startup-hook 'tm-setup/load-GNUS) + (require 'gnus-mime) + )) + + (add-hook 'gnus-load-hook 'tm-setup/load-gnus) ) -;;; @ for Gnus -;;; - -(defun tm-setup/load-gnus () - (let (gnus-load-hook) - (remove-hook 'gnus-startup-hook 'tm-setup/load-GNUS) - (require 'gnus-mime) - )) - -(add-hook 'gnus-load-hook 'tm-setup/load-gnus) - - ;;; @ end ;;;