From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: YAMAMOTO Mitsuharu Newsgroups: gmane.emacs.devel Subject: Re: Truncating scroll runs that copy to where we copied to Date: Mon, 21 Nov 2011 09:19:29 +0900 Organization: Faculty of Science, Chiba University Message-ID: References: <8339dibqlc.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: dough.gmane.org 1321834784 32660 80.91.229.12 (21 Nov 2011 00:19:44 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 21 Nov 2011 00:19:44 +0000 (UTC) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Nov 21 01:19:40 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RSHbo-0007gx-3r for ged-emacs-devel@m.gmane.org; Mon, 21 Nov 2011 01:19:40 +0100 Original-Received: from localhost ([::1]:44492 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RSHbn-0003Uv-Jo for ged-emacs-devel@m.gmane.org; Sun, 20 Nov 2011 19:19:39 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:34022) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RSHbk-0003Uf-6c for emacs-devel@gnu.org; Sun, 20 Nov 2011 19:19:37 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RSHbj-0004Z3-CB for emacs-devel@gnu.org; Sun, 20 Nov 2011 19:19:36 -0500 Original-Received: from mathmail.math.s.chiba-u.ac.jp ([133.82.132.2]:60669) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RSHbh-0004YN-6k; Sun, 20 Nov 2011 19:19:33 -0500 Original-Received: from church.math.s.chiba-u.ac.jp (church [133.82.132.36]) by mathmail.math.s.chiba-u.ac.jp (Postfix) with ESMTP id 60858C055D; Mon, 21 Nov 2011 09:19:29 +0900 (JST) In-Reply-To: <8339dibqlc.fsf@gnu.org> User-Agent: Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.8 (=?ISO-8859-4?Q?Shij=F2?=) APEL/10.6 Emacs/22.3 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI) X-detected-operating-system: by eggs.gnu.org: NetBSD 3.0 (DF) X-Received-From: 133.82.132.2 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:146103 Archived-At: >>>>> On Sun, 20 Nov 2011 20:23:27 +0200, Eli Zaretskii said: >> Date: Sun, 20 Nov 2011 16:13:59 +0900 From: YAMAMOTO Mitsuharu >> >> >> I think that `scrolling_window' needs to truncate scroll runs that >> copy to where we copied to; otherwise, `assign_row (to, from)' >> assigns a previously disabled bogus row in the desired matrix when >> we have an overlap in the copy destination. Such truncation can >> also avoid unnecessary copy in the actual graphics operation. >> >> Could someone double-check the code below? > Could you please elaborate on the rationale? Like, give a specific > use case with a few rows in the current and desired matrix, and show > why the current code does not DTRT? > I'm not saying you are wrong (I have my doubts about portions of > that function), just that we should at least look into a specific > test case, even if simplified one, to make sure we are fixing a real > bug. 1. Create a file whose contents is as follows (not including blank lines): 1 2 b c d e 3 4 a b c d e 2. % emacs -Q 3. Resize the frame so the window occupies 10 rows. 4. Find the file created at Step 1. Then the first (last) displayed row becomes `1' (`b', respectively). 5. M-< 6. C-v 7. M-v Then, the second line is displayed as `b' instead of `2'. YAMAMOTO Mitsuharu mituharu@math.s.chiba-u.ac.jp