From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Katsumi Yamaoka Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: Re: Top posting related changes in the cvs Date: Mon, 09 Apr 2007 15:40:40 +0900 Organization: Emacsen advocacy group Message-ID: References: <873b3hm942.fsf@ambire.localdomain> <87ps6ljc3q.fsf@ambire.localdomain> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1176100902 3503 80.91.229.12 (9 Apr 2007 06:41:42 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 9 Apr 2007 06:41:42 +0000 (UTC) Cc: "Gabor Z. Papp" , ding@gnus.org, emacs-devel@gnu.org To: Thien-Thi Nguyen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Apr 09 08:41:12 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HanYr-0006Ll-Ky for ged-emacs-devel@m.gmane.org; Mon, 09 Apr 2007 08:41:10 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Hancd-0002pd-Bs for ged-emacs-devel@m.gmane.org; Mon, 09 Apr 2007 02:45:03 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HancX-0002ag-Hw for emacs-devel@gnu.org; Mon, 09 Apr 2007 02:44:57 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HancU-0002Jx-88 for emacs-devel@gnu.org; Mon, 09 Apr 2007 02:44:56 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HancU-0002JT-4S for emacs-devel@gnu.org; Mon, 09 Apr 2007 02:44:54 -0400 Original-Received: from orlando.hostforweb.net ([216.246.45.90]) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1HanYe-0001Pv-JV for emacs-devel@gnu.org; Mon, 09 Apr 2007 02:40:57 -0400 Original-Received: from [66.225.201.151] (port=33068 helo=mail.jpl.org) by orlando.hostforweb.net with esmtpa (Exim 4.63) (envelope-from ) id 1HanYW-0007Gm-IV; Mon, 09 Apr 2007 01:40:48 -0500 X-Hashcash: 1:20:070409:ttn@gnuvola.org::xdn/RtAFRkvv7zzY:001/oa X-Hashcash: 1:20:070409:gzp@papp.hu::Wtj+XU84BFhueqby:0000001bHA X-Hashcash: 1:20:070409:ding@gnus.org::ORk6fDwhXtZDXmhg:00007ouJ X-Hashcash: 1:20:070409:emacs-devel@gnu.org::xQlITNtrJOJLaRbh:0000000000000000000000000000000000000000002lO0 X-Face: #kKnN,xUnmKia.'[pp`; Omh}odZK)?7wQSl"4o04=EixTF+V[""w~iNbM9ZL+.b*_CxUmFk B#Fu[*?MZZH@IkN:!"\w%I_zt>[$nm7nQosZ<3eu; B:$Q_:p!',P.c0-_Cy[dz4oIpw0ESA^D*1Lw= L&i*6&( User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.97 (gnu/linux) Cancel-Lock: sha1:FTzkOzvJuW3ytGP91wqbdMaqzyw= X-Antivirus-Scanner: Clean mail though you should still use an Antivirus X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - orlando.hostforweb.net X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - jpl.org X-Source: X-Source-Args: X-Source-Dir: X-detected-kernel: Linux 2.6, seldom 2.4 (older, 4) 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:69214 gmane.emacs.gnus.general:64503 Archived-At: --=-=-= Hi, I'm sorry for the late response (I was absent because of flu). >>>>> In <873b3hm942.fsf@ambire.localdomain> Thien-Thi Nguyen wrote: > 2005-08-01 Katsumi Yamaoka > * gnus-uu.el (gnus-uu-save-article): Use insert-buffer-substring > instead of insert-buffer. > * message.el (message-yank-original): Ditto; set the mark at the > end of the yanked message. I made those changes to obey the doc string of `insert-buffer': #v+ This function is meant for the user to run interactively. Don't call it from programs: use `insert-buffer-substring' instead! #v- > insert-buffer-substring inserts before point, while insert-buffer > inserts after point. Sure. Therefore, I've made it behave like `insert-buffer' as follows: #v+ (push-mark (save-excursion (insert-buffer-substring message-reply-buffer) (point))) #v- (This is just what `insert-buffer' defined in simple.el does.) > my analysis is that the exchange-point-and-mark relied on > insert-buffer's behavior, and thus became incorrect after the > 2005-08-01 change, since point and mark were already in the correct > order. Anyway, I verified that, before this change, there has already been the problem that happens when `message-yank-original' is called interactively. So, I'm not a culprit. ;-) >>>>> In <87ps6ljc3q.fsf@ambire.localdomain> Thien-Thi Nguyen wrote: > () Reiner Steib > () Wed, 04 Apr 2007 00:05:29 +0200 > I gather that you refer to an interactive call of > `message-yank-original' (C-c C-y) after doing a reply/followup > without citing the original (using `r'/`f'). > yes. > However, when using `R'/`F', I don't get this behavior anymore: > Point is _below_ the quote, which is wrong. > patch below seems to fix `R'/`F' w/ light testing. > here is a ChangeLog entry: > * gnus-msg.el (gnus-inews-yank-articles): > Fix bug: Make sure point is at eob after yanking. > probably all callers of `message-yank-original' should be checked. > does that give good results? I think the recent change in `message-yank-original' and this fix are the right solutions for Gnus v5.11. However, for No Gnus, it doesn't solve the problem in the case where `message-cite-reply-above' is non-nil and `message-yank-original' is called interactively. How about this one? * message.el (message-yank-original): Don't exchange point and mark. I also removed the `(unless (< (point) (mark-marker)) ...)' test since I think it will never return nil. --=-=-= Content-Disposition: attachment; filename=patch-for-Gnus-v5_11.txt Content-Description: patch for Gnus v5.11 *** message.el~ Tue Mar 27 21:43:24 2007 --- message.el Mon Apr 9 06:35:11 2007 *************** *** 3346,3358 **** (delete-windows-on message-reply-buffer t) (push-mark (save-excursion (insert-buffer-substring message-reply-buffer) (point))) (unless arg ! (funcall message-cite-function)) ! (unless (< (point) (mark-marker)) ! (message-exchange-point-and-mark)) ! (unless (bolp) ! (insert ?\n)) (unless modified (setq message-checksum (message-checksum)))))) --- 3346,3361 ---- (delete-windows-on message-reply-buffer t) (push-mark (save-excursion (insert-buffer-substring message-reply-buffer) + (unless (bolp) + (insert ?\n)) (point))) (unless arg ! (funcall message-cite-function) ! (unless (eq (char-before (mark t)) ?\n) ! (let ((pt (point))) ! (goto-char (mark t)) ! (insert-before-markers ?\n) ! (goto-char pt)))) (unless modified (setq message-checksum (message-checksum)))))) --=-=-= Content-Disposition: attachment; filename=patch-for-No-Gnus.txt Content-Description: patch for No Gnus *** gnus-msg.el~ Wed Mar 28 02:31:28 2007 --- gnus-msg.el Mon Apr 9 06:35:11 2007 *************** *** 789,794 **** --- 789,795 ---- (nnheader-narrow-to-headers) (nnheader-parse-naked-head))))) (message-yank-original) + (exchange-point-and-mark) (setq beg (or beg (mark t)))) (when articles (insert "\n"))) *** message.el~ Sun Apr 1 21:54:14 2007 --- message.el Mon Apr 9 06:35:11 2007 *************** *** 3550,3569 **** (delete-windows-on message-reply-buffer t) (push-mark (save-excursion (insert-buffer-substring message-reply-buffer) (point))) (unless arg ! (funcall message-cite-function)) ! (if message-cite-reply-above ! (progn ! (message-goto-body) ! (insert body-text) ! (newline) ! (message-goto-body) ! (message-exchange-point-and-mark)) ! (unless (< (point) (mark-marker)) ! (message-exchange-point-and-mark))) ! (unless (bolp) ! (insert ?\n)) ;; Add a `message-setup-very-last-hook' here? ;; Add `gnus-article-highlight-citation' here? (unless modified --- 3550,3572 ---- (delete-windows-on message-reply-buffer t) (push-mark (save-excursion (insert-buffer-substring message-reply-buffer) + (unless (bolp) + (insert ?\n)) (point))) (unless arg ! (funcall message-cite-function) ! (unless (eq (char-before (mark t)) ?\n) ! (let ((pt (point))) ! (goto-char (mark t)) ! (insert-before-markers ?\n) ! (goto-char pt)))) ! (when message-cite-reply-above ! (message-goto-body) ! (insert body-text) ! (unless (bolp) ! (insert ?\n)) ! (newline) ! (message-goto-body)) ;; Add a `message-setup-very-last-hook' here? ;; Add `gnus-article-highlight-citation' here? (unless modified --=-=-= Regards, --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --=-=-=--