# HG changeset patch # User Katsumi Yamaoka # Date 1285427275 0 # Node ID fd5269f6af5a1a53018e8ed35f6344e652b51443 # Parent 5e158658b471cfa00a43555cbd34b3707e1ef773 nndraft.el (nndraft-retrieve-headers): Insert Lines and Chars headers for prettier summary display. diff -r 5e158658b471 -r fd5269f6af5a lisp/gnus/ChangeLog --- a/lisp/gnus/ChangeLog Sat Sep 25 14:24:54 2010 +0000 +++ b/lisp/gnus/ChangeLog Sat Sep 25 15:07:55 2010 +0000 @@ -1,3 +1,8 @@ +2010-09-25 Lars Magne Ingebrigtsen + + * nndraft.el (nndraft-retrieve-headers): Insert Lines and Chars headers + for prettier summary display. + 2010-09-25 Andrew Cohen (tiny change) * nnir.el (nnir-run-imap): Allow sending IMAP search patterns diff -r 5e158658b471 -r fd5269f6af5a lisp/gnus/nndraft.el --- a/lisp/gnus/nndraft.el Sat Sep 25 14:24:54 2010 +0000 +++ b/lisp/gnus/nndraft.el Sat Sep 25 15:07:55 2010 +0000 @@ -79,7 +79,7 @@ (nndraft-possibly-change-group group) (with-current-buffer nntp-server-buffer (erase-buffer) - (let* (article) + (let (article lines chars) ;; We don't support fetching by Message-ID. (if (stringp (car articles)) 'headers @@ -91,9 +91,12 @@ (if (search-forward "\n\n" nil t) (forward-line -1) (goto-char (point-max))) + (setq lines (count-lines (point) (point-max)) + chars (- (point-max) (point))) (delete-region (point) (point-max)) (goto-char (point-min)) (insert (format "221 %d Article retrieved.\n" article)) + (insert (format "Lines: %d\nChars: %d\n" lines chars)) (widen) (goto-char (point-max)) (insert ".\n")))