GNU bug report logs - #21080
Scrolling bug

Previous Next

Package: emacs;

Reported by: Bru Rom <sortir <at> gmail.com>

Date: Fri, 17 Jul 2015 17:29:02 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 21080 in the body.
You can then email your comments to 21080 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#21080; Package emacs. (Fri, 17 Jul 2015 17:29:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Bru Rom <sortir <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Fri, 17 Jul 2015 17:29:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Bru Rom <sortir <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Scrolling bug
Date: Fri, 17 Jul 2015 19:51:12 +0300
[Message part 1 (text/plain, inline)]
Hi!

I work in terminal on Ubuntu 15.04 (xterm, GNOME terminal) with very big
text files, very long lines and warping (via global-visual-line). I want to
scroll by one line, so i set scroll-conservatively to
most-positive-fixnum. When i read text and scroll down everything is fine,
but when i want to return back and scroll up *over warped lines*, cursor
jumps on the second line from the top of window. According to manual, faq,
wiki and google i try to play with other scroll-related settings, such as
margin, aggressiveness, step, but with no result. Cursor still jump by two
lines when moving up. Looks like a bug. In GUI version everything is good
and scrolls by one line. This bug is only in terminals. Confirm with 24.4.1
and 24.5.
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#21080; Package emacs. (Fri, 17 Jul 2015 18:07:02 GMT) Full text and rfc822 format available.

Message #8 received at 21080 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Bru Rom <sortir <at> gmail.com>
Cc: 21080 <at> debbugs.gnu.org
Subject: Re: bug#21080: Scrolling bug
Date: Fri, 17 Jul 2015 21:06:46 +0300
> Date: Fri, 17 Jul 2015 19:51:12 +0300
> From: Bru Rom <sortir <at> gmail.com>
> 
> I work in terminal on Ubuntu 15.04 (xterm, GNOME terminal) with very big text
> files, very long lines and warping (via global-visual-line). I want to scroll
> by one line, so i set scroll-conservatively to
> most-positive-fixnum. When i read text and scroll down everything is fine, but
> when i want to return back and scroll up *over warped lines*, cursor jumps on
> the second line from the top of window. According to manual, faq, wiki and
> google i try to play with other scroll-related settings, such as margin,
> aggressiveness, step, but with no result. Cursor still jump by two lines when
> moving up. Looks like a bug. In GUI version everything is good and scrolls by
> one line. This bug is only in terminals. Confirm with 24.4.1 and 24.5.

Please show a sample file and the exact sequence of commands, starting
from "emacs -Q", for reproducing this problem.

Thanks.




Reply sent to Eli Zaretskii <eliz <at> gnu.org>:
You have taken responsibility. (Sat, 18 Jul 2015 10:08:01 GMT) Full text and rfc822 format available.

Notification sent to Bru Rom <sortir <at> gmail.com>:
bug acknowledged by developer. (Sat, 18 Jul 2015 10:08:02 GMT) Full text and rfc822 format available.

Message #13 received at 21080-done <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Bru Rom <sortir <at> gmail.com>
Cc: 21080-done <at> debbugs.gnu.org
Subject: Re: bug#21080: Scrolling bug
Date: Sat, 18 Jul 2015 13:07:20 +0300
> Date: Sat, 18 Jul 2015 00:58:14 +0300
> From: Bru Rom <sortir <at> gmail.com>
> 
> It can be any file with long enough lines.
> 
> For standard terminal 80x24, let the part of wikipedia article on Emacs be our
> "sample file". Emacs history from it:
> [...]

> Copy text to file, open it in Emacs with emacs -nw -Q
> 
> Next, exact sequence of commands:
> 
> alt-x customize-option
> scroll-conservatively
> Set there 10000, tab into state, enter state, press 0 = Set for Current Session
> Press 'q' to exit
> 
> Then alt-x visual-line-mode
> 
> Then C-End to go to end of buffer. Then scroll up line-by-line with Up. It
> scrolls by 2 over warped lines, but if you go down from start of buffer -
> everything will be ok.

Thanks.  This bug is now fixed in the development sources with the
simple change below (which you could probably easily apply to 24.5 or
previous versions, as that code was in Emacs since Mar 2002).

commit d3816bf8ad1fcfed2a32d23216a55850ee4325b5
Author: Eli Zaretskii <eliz <at> gnu.org>
Date:   Sat Jul 18 13:02:06 2015 +0300

    Fix scrolling backwards on TTY frames under scroll-conservatively
    
    * src/xdisp.c (move_it_vertically_backward): Fix off-by-one error
    in moving backwards on TTY frames.  (Bug#21080)

diff --git a/src/xdisp.c b/src/xdisp.c
index 5bef44c..16a7a64 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -9428,7 +9428,7 @@ struct overlay_entry
 	     treating terminal frames specially here.  */
 
 	  if (!FRAME_WINDOW_P (it->f))
-	    move_it_vertically (it, target_y - (it->current_y + line_height));
+	    move_it_vertically (it, target_y - it->current_y);
 	  else
 	    {
 	      do




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 15 Aug 2015 11:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 312 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.