tm 7.28.
[elisp/tm.git] / gnus / tm-gd5.el
1 ;;;
2 ;;; tm-gd5.el --- tm-gnus module for Gnus 5.*.
3 ;;;
4 ;;; Copyright (C) 1995 Free Software Foundation, Inc.
5 ;;; Copyright (C) 1995 MORIOKA Tomohiko
6 ;;;
7 ;;; Author: MORIOKA Tomohiko <morioka@jaist.ac.jp>
8 ;;; Maintainer: MORIOKA Tomohiko <morioka@jaist.ac.jp>
9 ;;; Created: 1995/11/19
10 ;;; Version:
11 ;;;     $Id: tm-gd5.el,v 2.0 1995/11/21 02:51:08 morioka Exp $
12 ;;; Keywords: news, MIME, multimedia, multilingual, encoded-word
13 ;;;
14 ;;; This file is part of tm (Tools for MIME).
15 ;;;
16 ;;; This program is free software; you can redistribute it and/or
17 ;;; modify it under the terms of the GNU General Public License as
18 ;;; published by the Free Software Foundation; either version 2, or
19 ;;; (at your option) any later version.
20 ;;;
21 ;;; This program is distributed in the hope that it will be useful,
22 ;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
23 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
24 ;;; General Public License for more details.
25 ;;;
26 ;;; You should have received a copy of the GNU General Public License
27 ;;; along with This program.  If not, write to the Free Software
28 ;;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
29
30 (cond ((not (boundp 'nnheader-encoded-words-decoding))
31        (require 'tm-ew-d)
32        
33        (defun tm-gnus/decode-summary-from-and-subjects ()
34          (mapcar (lambda (header)
35                    (let ((from (mail-header-from header))
36                          (subj (mail-header-subject header))
37                          )
38                      (mail-header-set-from
39                       header
40                       (if from
41                           (mime-eword/decode-string from)
42                         ""))
43                      (mail-header-set-subject
44                       header
45                       (if subj
46                           (mime-eword/decode-string subj)
47                         ""))
48                      ))
49                  gnus-newsgroup-headers)
50          )
51        
52        (add-hook 'gnus-select-group-hook
53                  (function tm-gnus/decode-summary-from-and-subjects))
54        ))
55
56
57 ;;; @ end
58 ;;;
59
60 (provide 'tm-gd5)