From 32e56704023faac59499546fc563c1429eb23702 Mon Sep 17 00:00:00 2001 From: Alex Schroeder Date: Mon, 16 Jan 2006 23:09:44 +0000 Subject: [PATCH] (rmail-summary-font-lock-keywords): Fix typo for labels. (rmail-summary-get-summary): Add labels again. --- lisp/mail/ChangeLog | 6 ++++++ lisp/mail/rmailsum.el | 24 ++++++++++++++---------- 2 files changed, 20 insertions(+), 10 deletions(-) diff --git a/lisp/mail/ChangeLog b/lisp/mail/ChangeLog index 642630d2911..999f34a9a35 100644 --- a/lisp/mail/ChangeLog +++ b/lisp/mail/ChangeLog @@ -1,3 +1,9 @@ +2006-01-17 Alex Schroeder + + * rmailsum.el (rmail-summary-font-lock-keywords): Fix typo for + labels. + (rmail-summary-get-summary): Add labels again. + 2006-01-16 Alex Schroeder * rmail.el (rmail-nuke-pinhead-header, rmail-reformat-message) diff --git a/lisp/mail/rmailsum.el b/lisp/mail/rmailsum.el index 1338708e7e1..9b0b07c0dad 100644 --- a/lisp/mail/rmailsum.el +++ b/lisp/mail/rmailsum.el @@ -62,7 +62,7 @@ ("^....-.*" . font-lock-type-face) ; Unread. ;; Neither of the below will be highlighted if either of the above are: ("^.....[^D-]....\\(......\\)" 1 font-lock-keyword-face) ; Date. - ("{ \\([^\n}]+\\),}" 1 font-lock-comment-face)) ; Labels. + ("{ \\([^\n}]+\\) }" 1 font-lock-comment-face)) ; Labels. "Additional expressions to highlight in Rmail Summary mode.") (defvar rmail-summary-redo nil @@ -1670,15 +1670,19 @@ KEYWORDS is a comma-separated list of labels." (defun rmail-summary-get-summary (n) "Return a summary line for message N." - (funcall rmail-summary-line-decoder - (format "%5s%s%6s %25s%s %s\n" - n - (rmail-summary-get-summary-attributes n) - (concat (rmail-desc-get-day-number n) "-" - (rmail-desc-get-month n)) - (rmail-desc-get-sender n) - (rmail-summary-get-line-count n) - (rmail-desc-get-subject n)))) + (let* ((keywords (rmail-desc-get-keywords n)) + (str (if keywords + (concat "{ " (mapconcat 'identity keywords " ") " } ") + ""))) + (funcall rmail-summary-line-decoder + (format "%5s%s%6s %25s%s %s\n" + n + (rmail-summary-get-summary-attributes n) + (concat (rmail-desc-get-day-number n) "-" + (rmail-desc-get-month n)) + (rmail-desc-get-sender n) + (rmail-summary-get-line-count n) + (concat str (rmail-desc-get-subject n)))))) (defun rmail-summary-update-attribute (attr-index n) "Update the attribute denoted by ATTR-INDEX in message N." -- 2.39.5