From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Ehud Karni" Newsgroups: gmane.emacs.devel Subject: Suggestion: go to bottom of mail message Date: Sat, 6 Aug 2005 16:59:04 +0300 Organization: Mivtach-Simon Insurance agencies Message-ID: <200508061359.j76Dx4xY015381@beta.mvs.co.il> Reply-To: ehud@unix.mvs.co.il NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-8-i Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1123337204 10157 80.91.229.2 (6 Aug 2005 14:06:44 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 6 Aug 2005 14:06:44 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Aug 06 16:06:42 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1E1PJH-0006F4-Fh for ged-emacs-devel@m.gmane.org; Sat, 06 Aug 2005 16:05:59 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1E1PI2-0001fL-Dt for ged-emacs-devel@m.gmane.org; Sat, 06 Aug 2005 10:04:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1E1PHC-0001cA-HU for emacs-devel@gnu.org; Sat, 06 Aug 2005 10:03:51 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1E1PH8-0001YW-5D for emacs-devel@gnu.org; Sat, 06 Aug 2005 10:03:47 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1E1PH7-0001VZ-Un for emacs-devel@gnu.org; Sat, 06 Aug 2005 10:03:45 -0400 Original-Received: from [193.16.147.12] (helo=unix.mvs.co.il) by monty-python.gnu.org with esmtp (Exim 4.34) id 1E1PPr-0007Qz-1U for emacs-devel@gnu.org; Sat, 06 Aug 2005 10:12:48 -0400 Original-Received: from beta.mvs.co.il (beta [10.253.0.3]) by unix.mvs.co.il (8.13.0/8.13.0) with ESMTP id j76Dx4cI027828 for ; Sat, 6 Aug 2005 16:59:04 +0300 Original-Received: from beta.mvs.co.il (localhost [127.0.0.1]) by beta.mvs.co.il (8.13.4/8.13.4) with ESMTP id j76Dx4lM015384 for ; Sat, 6 Aug 2005 16:59:04 +0300 Original-Received: (from root@localhost) by beta.mvs.co.il (8.13.4/8.13.4/Submit) id j76Dx4xY015381; Sat, 6 Aug 2005 16:59:04 +0300 Original-To: emacs-devel@gnu.org X-Mailer: Emacs 21.3.1 rmail (send-msg 1.108) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:41599 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:41599 [this is resend because the attached patch had the files reversed] On 2003-11-19 I suggested some change to mail/rmailsum.el (see - http://lists.gnu.org/archive/html/emacs-devel/2003-11/msg00279.html ) that got a supporting opinion from Kenichi Handa (see - http://lists.gnu.org/archive/html/emacs-devel/2003-11/msg00270.html ). I don't have write permission to CVS and nobody else added it. Here it is again (diff against the latest CVS versions), in the hope that it will included in Emacs 22.1. Ehud. 2003-11-19 Ehud Karni * mail/rmailsum.el (rmail-summary-end-of-message): New command to go to the bottom of the mail message. Added to `rmail-summary-mode-map' with key "/". (rmail-summary-show-message) New (internal) function for use by both `rmail-summary-beginning/end-of-message'. (rmail-summary-beginning-of-message) Changed to use the new function. * mail/rmail.el (rmail-end-of-message): New command to go to the end of the current message. Added to `rmail-mode-map' with key "/". (rmail-beginning-of-message): Fixed to work as documented. (rmail-mode): change documentation. diff -c rmailsum.el.~1.135.~ rmailsum-new.el *** rmailsum.el.~1.135.~ Mon Jul 11 19:05:43 2005 --- rmailsum-new.el Sat Aug 6 12:30:10 2005 *************** *** 898,903 **** --- 898,904 ---- (define-key rmail-summary-mode-map "x" 'rmail-summary-expunge) (define-key rmail-summary-mode-map "w" 'rmail-summary-output-body) (define-key rmail-summary-mode-map "." 'rmail-summary-beginning-of-message) + (define-key rmail-summary-mode-map "/" 'rmail-summary-end-of-message) (define-key rmail-summary-mode-map "<" 'rmail-summary-first-message) (define-key rmail-summary-mode-map ">" 'rmail-summary-last-message) (define-key rmail-summary-mode-map " " 'rmail-summary-scroll-msg-up) *************** *** 1185,1190 **** --- 1186,1201 ---- (defun rmail-summary-beginning-of-message () "Show current message from the beginning." (interactive) + (rmail-summary-show-message 'BEG)) + + (defun rmail-summary-end-of-message () + "Show bottom of current message." + (interactive) + (rmail-summary-show-message 'END)) + + (defun rmail-summary-show-message (where) + "Show current mail message. + Position it according to WHERE which can be BEG or END" (if (and (one-window-p) (not pop-up-frames)) ;; If there is just one window, put the summary on the top. (let ((buffer rmail-view-buffer)) *************** *** 1196,1203 **** (or (eq buffer (window-buffer (next-window (frame-first-window)))) (delete-other-windows))) (pop-to-buffer rmail-view-buffer)) ! (with-no-warnings ! (beginning-of-buffer)) (pop-to-buffer rmail-summary-buffer)) (defun rmail-summary-bury () --- 1207,1220 ---- (or (eq buffer (window-buffer (next-window (frame-first-window)))) (delete-other-windows))) (pop-to-buffer rmail-view-buffer)) ! (cond ! ((eq where 'BEG) ! (goto-char (point-min)) ! (search-forward "\n\n")) ! ((eq where 'END) ! (goto-char (point-max)) ! (recenter (1- (window-height)))) ! ) (pop-to-buffer rmail-summary-buffer)) (defun rmail-summary-bury () diff -c rmail.el.~1.406.~ rmail-new.el *** rmail.el.~1.406.~ Mon Jul 11 19:05:42 2005 --- rmail-new.el Sat Aug 6 13:41:01 2005 *************** *** 952,957 **** --- 952,958 ---- (define-key rmail-mode-map "w" 'rmail-output-body-to-file) (define-key rmail-mode-map "x" 'rmail-expunge) (define-key rmail-mode-map "." 'rmail-beginning-of-message) + (define-key rmail-mode-map "/" 'rmail-end-of-message) (define-key rmail-mode-map "<" 'rmail-first-message) (define-key rmail-mode-map ">" 'rmail-last-message) (define-key rmail-mode-map " " 'scroll-up) *************** *** 1096,1102 **** All normal editing commands are turned off. Instead, these commands are available: ! \\[rmail-beginning-of-message] Move point to front of this message (same as \\[beginning-of-buffer]). \\[scroll-up] Scroll to next screen of this message. \\[scroll-down] Scroll to previous screen of this message. \\[rmail-next-undeleted-message] Move to Next non-deleted message. --- 1097,1104 ---- All normal editing commands are turned off. Instead, these commands are available: ! \\[rmail-beginning-of-message] Move point to front of this message. ! \\[rmail-end-of-message] Move point to bottom of this message. \\[scroll-up] Scroll to next screen of this message. \\[scroll-down] Scroll to previous screen of this message. \\[rmail-next-undeleted-message] Move to Next non-deleted message. *************** *** 2604,2610 **** (defun rmail-beginning-of-message () "Show current message starting from the beginning." (interactive) ! (rmail-show-message rmail-current-message)) (defun rmail-unknown-mail-followup-to () "Handle a \"Mail-Followup-To\" header field with an unknown mailing list. --- 2606,2624 ---- (defun rmail-beginning-of-message () "Show current message starting from the beginning." (interactive) ! (let ((rmail-show-message-hook ! (list (function (lambda () ! (goto-char (point-min))))))) ! (rmail-show-message rmail-current-message))) ! ! (defun rmail-end-of-message () ! "Show bottom of current message." ! (interactive) ! (let ((rmail-show-message-hook ! (list (function (lambda () ! (goto-char (point-max)) ! (recenter (1- (window-height)))))))) ! (rmail-show-message rmail-current-message))) (defun rmail-unknown-mail-followup-to () "Handle a \"Mail-Followup-To\" header field with an unknown mailing list. -- Ehud Karni Tel: +972-3-7966-561 /"\ Mivtach - Simon Fax: +972-3-7966-667 \ / ASCII Ribbon Campaign Insurance agencies (USA) voice mail and X Against HTML Mail http://www.mvs.co.il FAX: 1-815-5509341 / \ GnuPG: 98EA398D Better Safe Than Sorry