;;; rmailsum.el --- make summary buffers for the mail reader
-;; Copyright (C) 1985, 1993-1996, 2000-2011 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 1993-1996, 2000-2013 Free Software Foundation,
+;; Inc.
;; Maintainer: FSF
;; Keywords: mail
(define-key map "<" 'rmail-summary-first-message)
(define-key map ">" 'rmail-summary-last-message)
(define-key map " " 'rmail-summary-scroll-msg-up)
+ (define-key map [?\S-\ ] 'rmail-summary-scroll-msg-down)
(define-key map "\177" 'rmail-summary-scroll-msg-down)
(define-key map "?" 'describe-mode)
(define-key map "\C-c\C-n" 'rmail-summary-next-same-subject)
(defun rmail-message-regexp-p-1 (msg regexp)
;; Search functions can expect to start from the beginning.
(narrow-to-region (point) (save-excursion (search-forward "\n\n") (point)))
- (if rmail-enable-mime
- (if rmail-search-mime-header-function
- (funcall rmail-search-mime-header-function msg regexp (point))
- (error "You must set `rmail-search-mime-header-function'"))
+ (if (and rmail-enable-mime
+ rmail-search-mime-header-function)
+ (funcall rmail-search-mime-header-function msg regexp (point))
(re-search-forward regexp nil t)))
;;;###autoload
;; This is how rmail makes the summary buffer reappear.
;; We do this here to make the window the proper size.
(rmail-select-summary nil)
- (set-buffer rmail-summary-buffer))
+ (set-buffer sumbuf))
(rmail-summary-goto-msg mesg t t)
(rmail-summary-construct-io-menu)
(message "Computing summary lines...done")))
(point)))))))))
(if (null from)
" "
+ ;; We are going to return only 25 characters of the
+ ;; address, so make sure it is RFC2047 decoded before
+ ;; taking its substring. This is important when the address is not on the same line as the name, e.g.:
+ ;; To: =?UTF-8?Q?=C5=A0t=C4=9Bp=C3=A1n_?= =?UTF-8?Q?N=C4=9Bmec?=
+ ;; <stepnem@gmail.com>
+ (setq from (rfc2047-decode-string from))
(setq len (length from))
(setq mch (string-match "[@%]" from))
(format "%25s"
(setq pos (point))
(forward-line 1)
(setq str (buffer-substring pos (1- (point))))
- (while (looking-at "\\s ")
+ (while (looking-at "[ \t]")
(setq str (concat str " "
(buffer-substring (match-end 0)
(line-end-position))))