From 790bd88990050c538b4fd2f0d49800f5604477f2 Mon Sep 17 00:00:00 2001 From: morioka Date: Mon, 9 Mar 1998 07:12:38 +0000 Subject: [PATCH] tm 6.76.1. --- Changes-6.76.1.en | 63 +++++++++++++++++ Changes-6.76.1.ja | 64 +++++++++++++++++ Makefile | 2 +- README.eng | 23 ++++-- gnus/Makefile | 5 +- gnus/g5-path | 17 +++++ gnus/mk-tgnus | 23 +++--- gnus/tm-dgnus.el | 188 +----------------------------------------------- gnus/tm-gnus.el | 14 +++- gnus/tm-gnus3.el | 31 +++++++- gnus/tm-gnus4.el | 29 +++++++- gnus/tm-gnus5.el | 204 +++++++++++++++++++++++++++++++++++++++++++++++++++++ gnus/tm-ognus.el | 21 +++--- 13 files changed, 464 insertions(+), 220 deletions(-) create mode 100644 Changes-6.76.1.en create mode 100644 Changes-6.76.1.ja create mode 100644 gnus/g5-path create mode 100644 gnus/tm-gnus5.el diff --git a/Changes-6.76.1.en b/Changes-6.76.1.en new file mode 100644 index 0000000..5a64d4a --- /dev/null +++ b/Changes-6.76.1.en @@ -0,0 +1,63 @@ +* tl + + Attached version 6.6. + +tl/tl-str.el +---------------------------- +revision 6.6 +date: 1995/08/31 20:11:08; author: morioka; state: Exp; lines: +5 -2 +Fixed a problem of function `get-version-string'. +---------------------------- + + +* tm/gnus + + Attached version 6.18. + + - Fixed mk-tgnus. + - Created load-path setting file for GNUS 5.*, `g5-path'. + +tm/gnus/tm-gnus3.el +---------------------------- +revision 6.1 +date: 1995/08/31 20:12:49; author: morioka; state: Exp; lines: +32 -4 +Defined constant `tm-gnus/RCS-ID' and constant `tm-gnus/version' in +this module. +---------------------------- + +tm/gnus/tm-gnus4.el +---------------------------- +revision 6.2 +date: 1995/08/31 20:14:33; author: morioka; state: Exp; lines: +28 -1 +Defined constant `tm-gnus/RCS-ID' and constant `tm-gnus/version' in +this module. +---------------------------- + +tm/gnus/tm-ognus.el +---------------------------- +revision 6.1 +date: 1995/08/31 20:13:47; author: morioka; state: Exp; lines: +8 -13 +Moved definition of version constants to tm-gnus3.el and tm-gnus4.el. +---------------------------- + +tm/gnus/tm-dgnus.el +---------------------------- +revision 6.18 +date: 1995/08/31 20:15:50; author: morioka; state: Exp; lines: +3 -185 +Moved major definition to tm-gnus5.el, and added (require 'tm-gnus5). +---------------------------- + +tm/gnus/tm-gnus5.el +---------------------------- +revision 6.18 +date: 1995/08/31 20:19:42; author: morioka; state: Exp; +Created as module for GNUS 5.*. Major definition is equal to +tm-dgnus.el. +---------------------------- + +tm/gnus/tm-gnus.el +---------------------------- +revision 6.2 +date: 1995/08/31 20:21:22; author: morioka; state: Exp; lines: +12 -2 +Separated setting for tm-gnus5 from setting for tm-dgnus. +---------------------------- diff --git a/Changes-6.76.1.ja b/Changes-6.76.1.ja new file mode 100644 index 0000000..6589b63 --- /dev/null +++ b/Changes-6.76.1.ja @@ -0,0 +1,64 @@ +* tl + + Version 6.6 を添付した。 + +tl/tl-str.el +---------------------------- +revision 6.6 +date: 1995/08/31 20:11:08; author: morioka; state: Exp; lines: +5 -2 +関数 get-version-string の不具合を修正した。 +---------------------------- + + +* tm/gnus + + Version 6.18 を添付した。 + + - mk-tgnus を修正した。 + - GNUS 5.* 用の loadpath 設定 file `g5-path' を新設した。 + +tm/gnus/tm-gnus3.el +---------------------------- +revision 6.1 +date: 1995/08/31 20:12:49; author: morioka; state: Exp; lines: +32 -4 +定数 tm-gnus/RCS-ID および、定数 tm-gnus/version をこの中で定義するよ +うにした。 +---------------------------- + +tm/gnus/tm-gnus4.el +---------------------------- +revision 6.2 +date: 1995/08/31 20:14:33; author: morioka; state: Exp; lines: +28 -1 +定数 tm-gnus/RCS-ID および、定数 tm-gnus/version をこの中で定義するよ +うにした。 +---------------------------- + +tm/gnus/tm-ognus.el +---------------------------- +revision 6.1 +date: 1995/08/31 20:13:47; author: morioka; state: Exp; lines: +8 -13 +version 定数の定義は tm-gnus3.el および tm-gnus4.el の中で行なうように +した。 +---------------------------- + +tm/gnus/tm-dgnus.el +---------------------------- +revision 6.18 +date: 1995/08/31 20:15:50; author: morioka; state: Exp; lines: +3 -185 +定義の大部分を tm-gnus5.el に移し、tm-gnus5 を require するようにした。 +---------------------------- + +tm/gnus/tm-gnus5.el +---------------------------- +revision 6.18 +date: 1995/08/31 20:19:42; author: morioka; state: Exp; +GNUS 5.* 用の module として新設した。設定の大部分は tm-dgnus.el と同じ +である。 +---------------------------- + +tm/gnus/tm-gnus.el +---------------------------- +revision 6.2 +date: 1995/08/31 20:21:22; author: morioka; state: Exp; lines: +12 -2 +tm-gnus5 用の設定を tm-dgnus 用の設定から分けた。 +---------------------------- diff --git a/Makefile b/Makefile index 3a26d36..68d9986 100644 --- a/Makefile +++ b/Makefile @@ -67,7 +67,7 @@ TL_FILES = tl/README.eng \ FILES = $(TM_FILES) $(TM_MUA_FILES) $(MEL_FILES) $(TL_FILES) -TARFILE = tm6.76.tar +TARFILE = tm6.76.1.tar nemacs: diff --git a/README.eng b/README.eng index b5dd5f2..6e6fca9 100644 --- a/README.eng +++ b/README.eng @@ -1,6 +1,6 @@ [README for tm (English Version)] by MORIOKA Tomohiko -$Id: README.eng,v 6.4 1995/08/31 14:22:04 morioka Exp $ +$Id: README.eng,v 6.7 1995/08/31 20:39:06 morioka Exp $ 1 What's tm? @@ -117,7 +117,15 @@ tl. Please read tl/README.eng. 5.1 tm-gnus -(1) Please edit gnus/Makefile +(1) Please edit gnus/Makefile. + + If you use GNUS 3.*, please edit gnus/g3-path. + + If you use GNUS 4.*, please edit gnus/g4-path. + + If you use (ding) GNUS, please edit gnus/d-path. + + If you use GNUS 5.*, please edit gnus/g5-path. (2) make @@ -127,6 +135,8 @@ tl. Please read tl/README.eng. Run `make dgnus', if you use (ding) GNUS. + Run `make gnus5', if you use GNUS 5.*. + (3) install Run `make install-18', if you use Emacs 18.*. @@ -134,12 +144,13 @@ tl. Please read tl/README.eng. Run `make install-19', if you use Emacs 19.*. -5.1.1 (ding) GNUS +5.1.1 (ding) GNUS or GNUS 5.* If you want to use automatic MIME preview support, please apply a -patch to (ding) GNUS. This patch is called `with tm patch'. It is -available from ftp.jaist.ac.jp:/pub/GNU/elisp/dgnus/. Current version -is dgnus-0.99.23-tm.diff. +patch to (ding) GNUS or GNUS 5.*. This patch is called `with tm +patch'. It is available from +ftp.jaist.ac.jp:/pub/GNU/elisp/dgnus/. Current version is +dgnus-0.99.23-tm.diff. 5.1 tm-mh-e diff --git a/gnus/Makefile b/gnus/Makefile index 8afd5a4..dceb902 100644 --- a/gnus/Makefile +++ b/gnus/Makefile @@ -17,7 +17,7 @@ TMDIR19 = $(HOME)/lib/emacs19/lisp FILES = tm/gnus/*.el -TARFILE = tm-gnus6.17.tar +TARFILE = tm-gnus6.18.tar gnus3: @@ -29,6 +29,9 @@ gnus4: dgnus: $(EMACS) -batch -l d-path -l mk-tgnus -f compile-tm-gnus +gnus5: + $(EMACS) -batch -l g5-path -l mk-tgnus -f compile-tm-gnus + install-18: $(EMACS) -batch -l g3-path -l mk-tgnus -f install-tm-gnus $(TMDIR18) diff --git a/gnus/g5-path b/gnus/g5-path new file mode 100644 index 0000000..6fd86b9 --- /dev/null +++ b/gnus/g5-path @@ -0,0 +1,17 @@ +;;; -*-Emacs-Lisp-*- + +(setq load-path + (append + (mapcar (function + (lambda (path) + (expand-file-name path (getenv "PWD")) + )) + '("." ".." "../../tl/" "../../mel/")) + ;; + ;; (ding) GNUS path + ;; + ;; please edit this + ;; + '("/usr/local/lib/emacs/site-lisp/gnus-5.1/lisp") + ;; + load-path)) diff --git a/gnus/mk-tgnus b/gnus/mk-tgnus index 7171b82..663d082 100644 --- a/gnus/mk-tgnus +++ b/gnus/mk-tgnus @@ -4,16 +4,19 @@ (require 'gnus) (require 'tm-view) (princ (format "%s\n" gnus-version)) - (cond ((string-match "(ding)" gnus-version) - (if (string-lessp "(ding) Gnus v0.99.27" gnus-version) - (byte-compile-file "tm-dgnus.el") - ) - ) - ((string-match "GNUS 3" gnus-version) + (cond ((string-match "GNUS 3" gnus-version) (byte-compile-file "tm-gnus3.el") ) - (t + ((string-match "GNUS 4" gnus-version) (byte-compile-file "tm-gnus4.el") + ) + ((string-match "(ding)" gnus-version) + (require 'tm-dgnus) + (byte-compile-file "tm-dgnus.el") + (byte-compile-file "tm-gnus5.el") + ) + ((string-match "Gnus v5" gnus-version) + (byte-compile-file "tm-gnus5.el") )) (byte-compile-file "tm-gnus.el") ) @@ -64,9 +67,11 @@ ) (progn (install-el-files path - "tm-gnus.el" "tm-dgnus.el" + "tm-gnus.el" "tm-gnus5.el" + "tm-dgnus.el" "tm-ognus.el" "tm-gnus4.el") (install-elc-files path - "tm-gnus.elc" "tm-dgnus.elc" + "tm-gnus.elc" "tm-gnus5.elc" + "tm-dgnus.elc" "tm-gnus4.elc") )))) diff --git a/gnus/tm-dgnus.el b/gnus/tm-dgnus.el index 1c69e6e..690a39c 100644 --- a/gnus/tm-dgnus.el +++ b/gnus/tm-dgnus.el @@ -2,33 +2,18 @@ ;;; tm-dgnus.el --- tm-gnus module for (ding) GNUS ;;; -(require 'tl-str) -(require 'tl-list) -(require 'gnus) +(require 'tm-gnus5) ;;; @ version ;;; + (defconst tm-gnus/RCS-ID - "$Id: tm-dgnus.el,v 6.17 1995/08/31 05:55:52 morioka Exp $") + "$Id: tm-dgnus.el,v 6.18 1995/08/31 20:15:50 morioka Exp $") (defconst tm-gnus/version (concat (get-version-string tm-gnus/RCS-ID) " (ding)")) -(defconst tm-gnus/automatic-MIME-preview-support - (cond ((boundp 'gnus-clean-article-buffer) - (defconst gnus-version (concat gnus-version " with tm patch")) - t) - (t - (defvar gnus-clean-article-buffer gnus-article-buffer) - nil) - )) - -(defvar tm-gnus/preview-buffer - (if tm-gnus/automatic-MIME-preview-support - (concat "*Preview-" gnus-clean-article-buffer "*")) - ) - (if (not (fboundp 'mail-header-from)) (progn (defalias 'mail-header-from 'header-from) @@ -38,173 +23,6 @@ )) -;;; @ autoload -;;; - -(autoload 'mime/viewer-mode "tm-view" "View MIME message." t) -(autoload 'mime/decode-message-header - "tiny-mime" "Decode MIME encoded-word." t) -(autoload 'mime/decode-string "tiny-mime" "Decode MIME encoded-word." t) - - -;;; @ variables -;;; - -(defvar tm-gnus/original-article-display-hook gnus-article-display-hook) - -(defvar tm-gnus/decode-all tm-gnus/automatic-MIME-preview-support - "If it is non-nil and -tm-gnus/automatic-MIME-preview-support is non-nil, -article is automatic MIME decoded.") - - -;;; @ command functions -;;; - -(defun tm-gnus/view-message (arg) - "MIME decode and play this message." - (interactive "P") - (let ((gnus-break-pages nil)) - (gnus-summary-select-article t t) - ) - (pop-to-buffer gnus-clean-article-buffer t) - (let (buffer-read-only) - (if (text-property-any (point-min) (point-max) 'invisible t) - (remove-text-properties (point-min) (point-max) - gnus-hidden-properties) - )) - (mime/viewer-mode) - ) - -(defun tm-gnus/summary-scroll-down () - "Scroll down one line current article." - (interactive) - (gnus-summary-scroll-up -1) - ) - -(define-key gnus-summary-mode-map "v" (function tm-gnus/view-message)) -(define-key gnus-summary-mode-map - "\e\r" (function tm-gnus/summary-scroll-down)) - - -;;; @ summary filter -;;; - -(defun tm-gnus/decode-summary-from-and-subjects () - (mapcar (function - (lambda (header) - (mail-header-set-from - header - (mime/decode-string (or (mail-header-from header) "")) - ) - (mail-header-set-subject - header - (mime/decode-string (or (mail-header-subject header) "")) - ) - )) - gnus-newsgroup-headers) - ) - -(add-hook 'gnus-select-group-hook - (function tm-gnus/decode-summary-from-and-subjects)) - - -;;; @ article filter -;;; - -(setq gnus-show-mime-method - (function - (lambda () - (let (buffer-read-only) - (mime/decode-message-header) - )))) - - -;;; @ automatic MIME preview support -;;; - -(defun tm-gnus/summary-toggle-header (&optional arg) - (interactive "P") - (if tm-gnus/decode-all - (let ((mime-viewer/ignored-field-list - (if (save-window-excursion - (switch-to-buffer tm-gnus/preview-buffer) - (goto-char (point-min)) - (message/get-field-body - (car mime-viewer/ignored-field-list) - )) - mime-viewer/ignored-field-list) - )) - (gnus-summary-select-article t t) - ) - (gnus-summary-toggle-header arg) - )) - -(defun tm-gnus/set-mime-method (mode) - (if mode - (progn - (setq gnus-show-mime nil) - (setq gnus-article-display-hook - (list (function (lambda () - (mime/viewer-mode) - (gnus-set-mode-line 'article) - )))) - (set-alist 'gnus-window-to-buffer 'article tm-gnus/preview-buffer) - (setq gnus-article-buffer tm-gnus/preview-buffer) - ) - (setq gnus-show-mime t) - (setq gnus-article-display-hook tm-gnus/original-article-display-hook) - (set-alist 'gnus-window-to-buffer 'article gnus-clean-article-buffer) - (setq gnus-article-buffer gnus-clean-article-buffer) - )) - -(defun tm-gnus/toggle-mime (arg) - "Toggle MIME processing mode. -With arg, turn MIME processing on if arg is positive." - (interactive "P") - (setq tm-gnus/decode-all - (if (null arg) - (not tm-gnus/decode-all) - arg)) - (gnus-set-global-variables) - (tm-gnus/set-mime-method tm-gnus/decode-all) - (gnus-summary-select-article gnus-show-all-headers 'force) - ) - -(if tm-gnus/automatic-MIME-preview-support - (progn - (define-key gnus-summary-mode-map - "t" (function tm-gnus/summary-toggle-header)) - (define-key gnus-summary-mode-map "\et" (function tm-gnus/toggle-mime)) - - (tm-gnus/set-mime-method tm-gnus/decode-all) - - (add-hook 'gnus-exit-gnus-hook - (function - (lambda () - (let ((buf (get-buffer tm-gnus/preview-buffer))) - (if buf - (kill-buffer buf) - ))))) - ) - (setq gnus-article-display-hook tm-gnus/original-article-display-hook) - (setq gnus-show-mime t) - ) - - -;;; @ for tm-comp -;;; - -(call-after-loaded - 'tm-comp - (function - (lambda () - (set-alist 'mime/message-sender-alist - 'news-reply-mode - (function gnus-inews-news)) - ))) - - ;;; @ end ;;; diff --git a/gnus/tm-gnus.el b/gnus/tm-gnus.el index 08f5762..d0836fc 100644 --- a/gnus/tm-gnus.el +++ b/gnus/tm-gnus.el @@ -3,18 +3,21 @@ ;;; ;;; by Morioka Tomohiko, 1993/11/20 ;;; -;;; $Id: tm-gnus.el,v 6.1 1995/05/31 04:38:12 morioka Exp $ +;;; $Id: tm-gnus.el,v 6.2 1995/08/31 20:21:22 morioka Exp $ ;;; (require 'gnus) + ;;; @ variables ;;; + (defvar tm-gnus/startup-hook nil) ;;; @ set up ;;; + (cond ((string-match "^GNUS [0-3]" gnus-version) (require 'tm-gnus3) ) @@ -23,8 +26,15 @@ ) ((string-match "(ding)" gnus-version) (require 'tm-dgnus) + ) + ((string-match "^Gnus v5" gnus-version) + (require 'tm-gnus5) )) -(run-hooks 'tm-gnus/startup-hook) + +;;; @ end +;;; (provide 'tm-gnus) + +(run-hooks 'tm-gnus/startup-hook) diff --git a/gnus/tm-gnus3.el b/gnus/tm-gnus3.el index ac33a2d..2fd500c 100644 --- a/gnus/tm-gnus3.el +++ b/gnus/tm-gnus3.el @@ -1,11 +1,26 @@ ;;; -;;; $Id: tm-gnus3.el,v 6.0 1995/03/11 22:51:37 morioka Exp morioka $ +;;; tm-gnus3.el --- tm-gnus module for GNUS 3.* ;;; -(require 'tm-view) (require 'tl-list) +(require 'tl-str) +(require 'tm-view) (require 'tm-ognus) + +;;; @ version +;;; + +(defconst tm-gnus/RCS-ID + "$Id: tm-gnus3.el,v 6.1 1995/08/31 20:12:49 morioka Exp $") + +(defconst tm-gnus/version + (concat (get-version-string tm-gnus/RCS-ID) " for GNUS 3")) + + +;;; @ for tm-view +;;; + (set-alist 'mime-viewer/quitting-method-alist 'gnus-Article-mode (if (string-match (regexp-quote "3.14.4") gnus-version) @@ -32,8 +47,16 @@ (mime/viewer-mode) ) + +;;; @ Summary decoding +;;; + (add-hook 'gnus-Select-group-hook (function tm-gnus/decode-summary-subjects)) + +;;; @ set up +;;; + (define-key gnus-Subject-mode-map "\et" 'tm-gnus/toggle-mime-header-decoding-mode) (define-key gnus-Subject-mode-map "v" 'tm-gnus/view-message) @@ -58,4 +81,8 @@ (function mime/add-header-decoding-mode-to-mode-line)) )) + +;;; @ end +;;; + (provide 'tm-gnus3) diff --git a/gnus/tm-gnus4.el b/gnus/tm-gnus4.el index 026a450..87e414b 100644 --- a/gnus/tm-gnus4.el +++ b/gnus/tm-gnus4.el @@ -1,9 +1,24 @@ ;;; -;;; $Id: tm-gnus4.el,v 6.1 1995/08/30 00:41:17 morioka Exp $ +;;; tm-gnus4.el --- tm-gnus module for GNUS 4.* ;;; +(require 'tl-str) (require 'tm-ognus) + +;;; @ version +;;; + +(defconst tm-gnus/RCS-ID + "$Id: tm-gnus4.el,v 6.2 1995/08/31 20:14:33 morioka Exp $") + +(defconst tm-gnus/version + (concat (get-version-string tm-gnus/RCS-ID) " for GNUS 4")) + + +;;; @ for tm-view +;;; + (autoload 'mime/viewer-mode "tm-view" "View MIME message." t) (defun tm-gnus/view-message (arg) @@ -22,8 +37,16 @@ (gnus-summary-scroll-up -1) ) + +;;; @ Summary decoding +;;; + (add-hook 'gnus-select-group-hook (function tm-gnus/decode-summary-subjects)) + +;;; @ set up +;;; + (define-key gnus-summary-mode-map "\et" (function tm-gnus/toggle-mime-header-decoding-mode)) (define-key gnus-summary-mode-map "v" (function tm-gnus/view-message)) @@ -134,4 +157,8 @@ (function tm-gnus4/message-after-send)) ))) + +;;; @ end +;;; + (provide 'tm-gnus4) diff --git a/gnus/tm-gnus5.el b/gnus/tm-gnus5.el new file mode 100644 index 0000000..69c39dd --- /dev/null +++ b/gnus/tm-gnus5.el @@ -0,0 +1,204 @@ +;;; +;;; tm-gnus5.el --- tm-gnus module for GNUS 5.* +;;; + +(require 'tl-str) +(require 'tl-list) +(require 'gnus) + + +;;; @ version +;;; + +(defconst tm-gnus/RCS-ID + "$Id: tm-gnus5.el,v 6.18 1995/08/31 20:19:42 morioka Exp $") + +(defconst tm-gnus/version + (concat (get-version-string tm-gnus/RCS-ID) " for GNUS 5")) + +(defconst tm-gnus/automatic-MIME-preview-support + (cond ((boundp 'gnus-clean-article-buffer) + (defconst gnus-version (concat gnus-version " with tm patch")) + t) + (t + (defvar gnus-clean-article-buffer gnus-article-buffer) + nil) + )) + +(defvar tm-gnus/preview-buffer + (if tm-gnus/automatic-MIME-preview-support + (concat "*Preview-" gnus-clean-article-buffer "*")) + ) + + +;;; @ autoload +;;; + +(autoload 'mime/viewer-mode "tm-view" "View MIME message." t) +(autoload 'mime/decode-message-header + "tiny-mime" "Decode MIME encoded-word." t) +(autoload 'mime/decode-string "tiny-mime" "Decode MIME encoded-word." t) + + +;;; @ variables +;;; + +(defvar tm-gnus/original-article-display-hook gnus-article-display-hook) + +(defvar tm-gnus/decode-all tm-gnus/automatic-MIME-preview-support + "If it is non-nil and +tm-gnus/automatic-MIME-preview-support is non-nil, +article is automatic MIME decoded.") + + +;;; @ command functions +;;; + +(defun tm-gnus/view-message (arg) + "MIME decode and play this message." + (interactive "P") + (let ((gnus-break-pages nil)) + (gnus-summary-select-article t t) + ) + (pop-to-buffer gnus-clean-article-buffer t) + (let (buffer-read-only) + (if (text-property-any (point-min) (point-max) 'invisible t) + (remove-text-properties (point-min) (point-max) + gnus-hidden-properties) + )) + (mime/viewer-mode) + ) + +(defun tm-gnus/summary-scroll-down () + "Scroll down one line current article." + (interactive) + (gnus-summary-scroll-up -1) + ) + +(define-key gnus-summary-mode-map "v" (function tm-gnus/view-message)) +(define-key gnus-summary-mode-map + "\e\r" (function tm-gnus/summary-scroll-down)) + + +;;; @ summary filter +;;; + +(defun tm-gnus/decode-summary-from-and-subjects () + (mapcar (function + (lambda (header) + (mail-header-set-from + header + (mime/decode-string (or (mail-header-from header) "")) + ) + (mail-header-set-subject + header + (mime/decode-string (or (mail-header-subject header) "")) + ) + )) + gnus-newsgroup-headers) + ) + +(add-hook 'gnus-select-group-hook + (function tm-gnus/decode-summary-from-and-subjects)) + + +;;; @ article filter +;;; + +(setq gnus-show-mime-method + (function + (lambda () + (let (buffer-read-only) + (mime/decode-message-header) + )))) + + +;;; @ automatic MIME preview support +;;; + +(defun tm-gnus/summary-toggle-header (&optional arg) + (interactive "P") + (if tm-gnus/decode-all + (let ((mime-viewer/ignored-field-list + (if (save-window-excursion + (switch-to-buffer tm-gnus/preview-buffer) + (goto-char (point-min)) + (message/get-field-body + (car mime-viewer/ignored-field-list) + )) + mime-viewer/ignored-field-list) + )) + (gnus-summary-select-article t t) + ) + (gnus-summary-toggle-header arg) + )) + +(defun tm-gnus/set-mime-method (mode) + (if mode + (progn + (setq gnus-show-mime nil) + (setq gnus-article-display-hook + (list (function (lambda () + (mime/viewer-mode) + (gnus-set-mode-line 'article) + )))) + (set-alist 'gnus-window-to-buffer 'article tm-gnus/preview-buffer) + (setq gnus-article-buffer tm-gnus/preview-buffer) + ) + (setq gnus-show-mime t) + (setq gnus-article-display-hook tm-gnus/original-article-display-hook) + (set-alist 'gnus-window-to-buffer 'article gnus-clean-article-buffer) + (setq gnus-article-buffer gnus-clean-article-buffer) + )) + +(defun tm-gnus/toggle-mime (arg) + "Toggle MIME processing mode. +With arg, turn MIME processing on if arg is positive." + (interactive "P") + (setq tm-gnus/decode-all + (if (null arg) + (not tm-gnus/decode-all) + arg)) + (gnus-set-global-variables) + (tm-gnus/set-mime-method tm-gnus/decode-all) + (gnus-summary-select-article gnus-show-all-headers 'force) + ) + +(if tm-gnus/automatic-MIME-preview-support + (progn + (define-key gnus-summary-mode-map + "t" (function tm-gnus/summary-toggle-header)) + (define-key gnus-summary-mode-map "\et" (function tm-gnus/toggle-mime)) + + (tm-gnus/set-mime-method tm-gnus/decode-all) + + (add-hook 'gnus-exit-gnus-hook + (function + (lambda () + (let ((buf (get-buffer tm-gnus/preview-buffer))) + (if buf + (kill-buffer buf) + ))))) + ) + (setq gnus-article-display-hook tm-gnus/original-article-display-hook) + (setq gnus-show-mime t) + ) + + +;;; @ for tm-comp +;;; + +(call-after-loaded + 'tm-comp + (function + (lambda () + (set-alist 'mime/message-sender-alist + 'news-reply-mode + (function gnus-inews-news)) + ))) + + +;;; @ end +;;; + +(provide 'tm-gnus5) diff --git a/gnus/tm-ognus.el b/gnus/tm-ognus.el index 46fdfa7..bba7111 100644 --- a/gnus/tm-ognus.el +++ b/gnus/tm-ognus.el @@ -1,23 +1,13 @@ ;;; -;;; tm-ognus.el --- tm-gnus module for Original GNUS +;;; tm-ognus.el --- tm-gnus module for GNUS 3.* and 4.* ;;; - -;;; @ require modules +;;; $Id: tm-ognus.el,v 6.1 1995/08/31 20:13:47 morioka Exp $ ;;; + (require 'tm-misc) -(require 'tl-str) (require 'gnus) -;;; @ version -;;; -(defconst tm-gnus/RCS-ID - "$Id: tm-ognus.el,v 6.0 1995/05/23 13:23:31 morioka Exp $") - -(defconst tm-gnus/version - (concat (get-version-string tm-gnus/RCS-ID) " (for ORIGINAL GNUS)")) - - ;;; @ change MIME header decoding mode, decoding or non decoding. ;;; @@ -43,6 +33,7 @@ With arg, turn MIME processing on iff arg is positive." ;; ;; New implementation in gnus 3.14.3 ;; + (defun tm-gnus/article-set-mode-line () "Set Article mode line string. If you don't like it, define your own gnus-article-set-mode-line." @@ -69,6 +60,7 @@ If you don't like it, define your own gnus-article-set-mode-line." ;;; @ to decode subjects in Summary buffer ;;; + (defun tm-gnus/decode-summary-subjects () (mapcar (function (lambda (header) @@ -79,4 +71,7 @@ If you don't like it, define your own gnus-article-set-mode-line." ) +;;; @ end +;;; + (provide 'tm-ognus) -- 1.7.10.4