emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Patch] rmail-get-new-mail: say if all messages are spam


From: Diane Murray
Subject: [Patch] rmail-get-new-mail: say if all messages are spam
Date: Mon, 04 Sep 2006 04:20:50 +0200

Included is a patch to rmail.el which changes the message that shows
how many new messages were read, making it state clearly if all
messages were found to be spam when using the rmail-spam-filter.  The
way it works now, it is possible to miss seeing both numbers before
the message goes away and then wonder how many messages *weren't*
spam.


        * mail/rmail.el (rmail-get-new-mail): If all the messages are
        found to be spam say "all" instead of showing the number.


Index: rmail.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/mail/rmail.el,v
retrieving revision 1.426
diff -c -r1.426 rmail.el
*** rmail.el    20 May 2006 17:36:07 -0000      1.426
--- rmail.el    4 Sep 2006 00:06:19 -0000
***************
*** 1677,1688 ****
                         (if (and (featurep 'rmail-spam-filter)
                                  rmail-use-spam-filter
                                  (> rsf-number-of-spam 0))
!                            (if (= 1 new-messages)
!                                ", and found to be a spam message"
!                              (if (> rsf-number-of-spam 1)
!                                  (format ", %d of which found to be spam 
messages"
!                                          rsf-number-of-spam)
!                                ", one of which found to be a spam message"))
                           ""))
                (if (and (featurep 'rmail-spam-filter)
                         rmail-use-spam-filter
--- 1677,1691 ----
                         (if (and (featurep 'rmail-spam-filter)
                                  rmail-use-spam-filter
                                  (> rsf-number-of-spam 0))
!                            (cond ((= 1 new-messages)
!                                   ", and found to be a spam message")
!                                  ((= 1 rsf-number-of-spam)
!                                   ", one of which found to be a spam message")
!                                  ((= new-messages rsf-number-of-spam)
!                                   ", all found to be spam messages")
!                                  (t
!                                   (format ", %d of which found to be spam 
messages"
!                                           rsf-number-of-spam)))
                           ""))
                (if (and (featurep 'rmail-spam-filter)
                         rmail-use-spam-filter




reply via email to

[Prev in Thread] Current Thread [Next in Thread]