* bug#14780: Regression: C-n doesn't go to next line under simple circumstances @ 2013-07-03 16:03 Barry OReilly [not found] ` <handler.14780.B.13728674128397.ack@debbugs.gnu.org> 0 siblings, 1 reply; 11+ messages in thread From: Barry OReilly @ 2013-07-03 16:03 UTC (permalink / raw) To: 14780 [-- Attachment #1.1: Type: text/plain, Size: 2960 bytes --] Let cant-next-line.el have file contents: (tool-bar-mode 0) (global-whitespace-mode 1) (set-face-attribute 'default nil :height 80) (setq scroll-margin 4) (setq scroll-conservatively 101) Open up the attached cant-next-line.txt by: emacs -Q --load cant-next-line.el cant-next-line.txt Move point to be immediately before the 'h' of "here". Try to reach the '-' character at the end of the file using C-n. You can't. If I move point to the beginning of line containing "here", then I can. I checked emacs-24.3 and could not reproduce this, so it is a regression. I witnessed this with latest trunk 68068a328a854998a0071f4714cbacdfed36fcc1 and for commit 20899d085afe62520113b5acbfe3dbba57823dc9 (Jun 5) which I use day to day (because the commit immediately following broke Evil in a critical way). --- In GNU Emacs 24.3.50.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.10.4) of 2013-06-18 on psd15 Windowing system distributor `The X.Org Foundation', version 11.0.70101000 System Description: Red Hat Enterprise Linux Client release 5.4 (Tikanga) Configured using: `configure --prefix=/redacted/user/boreilly/sw/emacs-install-trunk-20899d085afe62520113b5acbfe3dbba57823dc9 --with-gif=no' Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=none locale-coding-system: utf-8-unix default enable-multibyte-characters: t Major mode: Text Minor modes in effect: global-whitespace-mode: t tooltip-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent input: M-x r e p o r t <tab> <return> Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Load-path shadows: None found. Features: (shadow sort nadvice gnus-util mail-extr emacsbug message format-spec rfc822 mml easymenu mml-sec mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils disp-table whitespace time-date tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment lisp-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote make-network-process dbusbind dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty emacs) [-- Attachment #1.2: Type: text/html, Size: 3291 bytes --] [-- Attachment #2: cant-next-line.txt --] [-- Type: text/plain, Size: 279 bytes --] ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- here - ^ permalink raw reply [flat|nested] 11+ messages in thread
[parent not found: <handler.14780.B.13728674128397.ack@debbugs.gnu.org>]
* bug#14780: Acknowledgement (Regression: C-n doesn't go to next line under simple circumstances) [not found] ` <handler.14780.B.13728674128397.ack@debbugs.gnu.org> @ 2013-07-19 18:37 ` Barry OReilly 2013-07-19 19:14 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Barry OReilly @ 2013-07-19 18:37 UTC (permalink / raw) To: 14780 Git bisected the repo at Savannah to: 15cdf9527f5a78a5ea9aa0ba3fee8d7b84c3acf9 is the first bad commit commit 15cdf9527f5a78a5ea9aa0ba3fee8d7b84c3acf9 Author: Eli Zaretskii <eliz@gnu.org> Date: Mon Dec 3 22:48:12 2012 +0200 Fix bug #13055 with cursor positioning inside scroll-margin. src/xdisp.c (redisplay_window): If the cursor is visible, but inside the scroll margin, move point outside the margin. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Acknowledgement (Regression: C-n doesn't go to next line under simple circumstances) 2013-07-19 18:37 ` bug#14780: Acknowledgement (Regression: C-n doesn't go to next line under simple circumstances) Barry OReilly @ 2013-07-19 19:14 ` Eli Zaretskii 2013-07-19 19:53 ` Barry OReilly 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2013-07-19 19:14 UTC (permalink / raw) To: Barry OReilly; +Cc: 14780 > Date: Fri, 19 Jul 2013 14:37:57 -0400 > From: Barry OReilly <gundaetiapo@gmail.com> > > Git bisected the repo at Savannah to: > > 15cdf9527f5a78a5ea9aa0ba3fee8d7b84c3acf9 is the first bad commit > commit 15cdf9527f5a78a5ea9aa0ba3fee8d7b84c3acf9 > Author: Eli Zaretskii <eliz@gnu.org> > Date: Mon Dec 3 22:48:12 2012 +0200 > > Fix bug #13055 with cursor positioning inside scroll-margin. > > src/xdisp.c (redisplay_window): If the cursor is visible, but inside > the scroll margin, move point outside the margin. I cannot reproduce the bug on my system. Unless I don't understand what you mean by "cannot reach the '-' character". I can reach every line in the buffer by using C-n, using your recipe (or what I understand of it). ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Acknowledgement (Regression: C-n doesn't go to next line under simple circumstances) 2013-07-19 19:14 ` Eli Zaretskii @ 2013-07-19 19:53 ` Barry OReilly 2013-07-19 20:30 ` bug#14780: Regression: C-n doesn't go to next line under simple circumstances Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Barry OReilly @ 2013-07-19 19:53 UTC (permalink / raw) To: 14780 Use this /tmp/cant-next-line.el to automate a little more. (tool-bar-mode 0) (global-whitespace-mode 1) (set-face-attribute 'default nil :height 80) (setq scroll-margin 4) (setq scroll-conservatively 101) (add-hook 'emacs-startup-hook (lambda () (re-search-forward "here") (trace-redisplay) ;; Doesn't reproduce it, have to C-n manually ;; (run-at-time "1 sec" 1 (lambda () ;; (call-interactively 'next-line))) )) Reproduction won't happen if you: - resize the window - use M-x next-line instead of C-n - press and hold C-n - navigate in ways other than prescribed I can see it everytime I follow the recipe. Here is the trace-redisplay resulting from: ./src/emacs -r -Q --load /tmp/cant-next-line.el /tmp/cant-next-line.txt Then C-n 5 times redisplay_internal 0 0x110d9a0 (cant-next-line.txt): same window start 0x110d9a0 (cant-next-line.txt): 1 0x110d9a0 (cant-next-line.txt): same window start 0x110d9a0 (cant-next-line.txt): 1 redisplay_preserve_echo_area (8) redisplay_internal 0 redisplay_internal 0 0x110d9a0 (cant-next-line.txt): cursor movement 0x110d9a0 (cant-next-line.txt): try_scrolling redisplay_internal 0 0x110d9a0 (cant-next-line.txt): forced window start redisplay_preserve_echo_area (7) redisplay_internal 0 redisplay_internal 0 0x110d9a0 (cant-next-line.txt): forced window start redisplay_preserve_echo_area (7) redisplay_internal 0 redisplay_internal 0 0x110d9a0 (cant-next-line.txt): forced window start redisplay_preserve_echo_area (7) redisplay_internal 0 redisplay_internal 0 0x110d9a0 (cant-next-line.txt): forced window start redisplay_preserve_echo_area (7) redisplay_internal 0 redisplay_preserve_echo_area (8) redisplay_internal 0 redisplay_preserve_echo_area (8) redisplay_internal 0 ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-19 19:53 ` Barry OReilly @ 2013-07-19 20:30 ` Eli Zaretskii 2013-07-19 20:37 ` Barry OReilly 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2013-07-19 20:30 UTC (permalink / raw) To: Barry OReilly; +Cc: 14780 > Date: Fri, 19 Jul 2013 15:53:35 -0400 > From: Barry OReilly <gundaetiapo@gmail.com> > > Use this /tmp/cant-next-line.el to automate a little more. > > (tool-bar-mode 0) > (global-whitespace-mode 1) > (set-face-attribute 'default nil :height 80) > (setq scroll-margin 4) > (setq scroll-conservatively 101) > (add-hook 'emacs-startup-hook (lambda () > (re-search-forward "here") > (trace-redisplay) > ;; Doesn't reproduce it, have to C-n manually > ;; (run-at-time "1 sec" 1 (lambda () > ;; > (call-interactively 'next-line))) > )) > > Reproduction won't happen if you: > - resize the window > - use M-x next-line instead of C-n > - press and hold C-n > - navigate in ways other than prescribed > > I can see it everytime I follow the recipe. > > Here is the trace-redisplay resulting from: > ./src/emacs -r -Q --load /tmp/cant-next-line.el /tmp/cant-next-line.txt I get 'Search failed: "here"'. Are you using a recent trunk? I'm using today's trunk. > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): same window start > 0x110d9a0 (cant-next-line.txt): 1 > 0x110d9a0 (cant-next-line.txt): same window start > 0x110d9a0 (cant-next-line.txt): 1 > redisplay_preserve_echo_area (8) > redisplay_internal 0 > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): cursor movement > 0x110d9a0 (cant-next-line.txt): try_scrolling > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): forced window start > redisplay_preserve_echo_area (7) > redisplay_internal 0 > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): forced window start > redisplay_preserve_echo_area (7) > redisplay_internal 0 > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): forced window start > redisplay_preserve_echo_area (7) > redisplay_internal 0 > redisplay_internal 0 > 0x110d9a0 (cant-next-line.txt): forced window start > redisplay_preserve_echo_area (7) > redisplay_internal 0 > redisplay_preserve_echo_area (8) > redisplay_internal 0 > redisplay_preserve_echo_area (8) > redisplay_internal 0 I see nothing extraordinary here. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-19 20:30 ` bug#14780: Regression: C-n doesn't go to next line under simple circumstances Eli Zaretskii @ 2013-07-19 20:37 ` Barry OReilly 2013-07-20 6:42 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Barry OReilly @ 2013-07-19 20:37 UTC (permalink / raw) To: 14780 > I get 'Search failed: "here"'. Are you using the cant-next-line.txt attached to the bug report? It clearly contains "here". > Are you using a recent trunk? I'm using today's trunk. I'm using: commit 3961bd5799169d6e24e151a8fc06d637c348eb93 Author: Paul Eggert <eggert@cs.ucla.edu> Date: Fri Jul 19 11:09:23 2013 -0700 ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-19 20:37 ` Barry OReilly @ 2013-07-20 6:42 ` Eli Zaretskii 2013-07-20 8:33 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2013-07-20 6:42 UTC (permalink / raw) To: Barry OReilly; +Cc: 14780 > Date: Fri, 19 Jul 2013 16:37:30 -0400 > From: Barry OReilly <gundaetiapo@gmail.com> > > > I get 'Search failed: "here"'. > > Are you using the cant-next-line.txt attached to the bug report? Yes. > It clearly contains "here". Maybe Emacs searches for it before it visits the file? > > Are you using a recent trunk? I'm using today's trunk. > > I'm using: > commit 3961bd5799169d6e24e151a8fc06d637c348eb93 > Author: Paul Eggert <eggert@cs.ucla.edu> > Date: Fri Jul 19 11:09:23 2013 -0700 Strange. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-20 6:42 ` Eli Zaretskii @ 2013-07-20 8:33 ` Eli Zaretskii 2013-07-20 9:09 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2013-07-20 8:33 UTC (permalink / raw) To: gundaetiapo; +Cc: 14780 Does the following fix the problem for you? === modified file 'src/xdisp.c' --- src/xdisp.c 2013-07-16 21:35:45 +0000 +++ src/xdisp.c 2013-07-20 08:21:36 +0000 @@ -15592,7 +15592,8 @@ redisplay_window (Lisp_Object window, in Move it back to a fully-visible line. */ new_vpos = window_box_height (w); } - else if (w->cursor.vpos >=0) + else if (w->cursor.vpos >=0 + && PT >= BEGV && PT < ZV) { /* Some people insist on not letting point enter the scroll margin, even though this part handles windows that didn't @@ -15619,7 +15620,16 @@ redisplay_window (Lisp_Object window, in if (header_line) window_height += CURRENT_HEADER_LINE_HEIGHT (w); if (w->cursor.y >= window_height - pixel_margin) - new_vpos = window_height - pixel_margin; + { + struct text_pos pos; + + SET_TEXT_POS (pos, PT, PT_BYTE); + start_display (&it, w, pos); + it.current_y = it.vpos = 0; + move_it_to (&it, ZV, -1, -1, -1, MOVE_TO_POS); + if (it.vpos > margin) + new_vpos = window_height - pixel_margin; + } } } ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-20 8:33 ` Eli Zaretskii @ 2013-07-20 9:09 ` Eli Zaretskii 2013-07-22 20:37 ` Barry OReilly 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2013-07-20 9:09 UTC (permalink / raw) To: gundaetiapo; +Cc: 14780 > Date: Sat, 20 Jul 2013 11:33:07 +0300 > From: Eli Zaretskii <eliz@gnu.org> > Cc: 14780@debbugs.gnu.org > > Does the following fix the problem for you? Sorry, that change had a bug. Please try this instead: === modified file 'src/xdisp.c' --- src/xdisp.c 2013-07-16 21:35:45 +0000 +++ src/xdisp.c 2013-07-20 09:05:11 +0000 @@ -15608,10 +15608,11 @@ redisplay_window (Lisp_Object window, in the Y coordinate of the _next_ row, see the definition of MATRIX_ROW_BOTTOM_Y. */ if (w->cursor.vpos < margin + header_line) - new_vpos - = pixel_margin + (header_line - ? CURRENT_HEADER_LINE_HEIGHT (w) - : 0) + frame_line_height; + { + w->cursor.vpos = -1; + clear_glyph_matrix (w->desired_matrix); + goto try_to_scroll; + } else { int window_height = window_box_height (w); @@ -15619,7 +15620,11 @@ redisplay_window (Lisp_Object window, in if (header_line) window_height += CURRENT_HEADER_LINE_HEIGHT (w); if (w->cursor.y >= window_height - pixel_margin) - new_vpos = window_height - pixel_margin; + { + w->cursor.vpos = -1; + clear_glyph_matrix (w->desired_matrix); + goto try_to_scroll; + } } } ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-20 9:09 ` Eli Zaretskii @ 2013-07-22 20:37 ` Barry OReilly 2013-07-24 17:38 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Barry OReilly @ 2013-07-22 20:37 UTC (permalink / raw) Cc: 14780 On Sat, Jul 20, 2013 at 5:09 AM, Eli Zaretskii <eliz@gnu.org> wrote: > Sorry, that change had a bug. Please try this instead: That fixes the issue. Thanks. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#14780: Regression: C-n doesn't go to next line under simple circumstances 2013-07-22 20:37 ` Barry OReilly @ 2013-07-24 17:38 ` Eli Zaretskii 0 siblings, 0 replies; 11+ messages in thread From: Eli Zaretskii @ 2013-07-24 17:38 UTC (permalink / raw) To: Barry OReilly; +Cc: 14780-done > Date: Mon, 22 Jul 2013 16:37:49 -0400 > From: Barry OReilly <gundaetiapo@gmail.com> > Cc: 14780@debbugs.gnu.org > > On Sat, Jul 20, 2013 at 5:09 AM, Eli Zaretskii <eliz@gnu.org> wrote: > > Sorry, that change had a bug. Please try this instead: > > That fixes the issue. Thanks. Thanks, committed as trunk revision 113532. ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2013-07-24 17:38 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2013-07-03 16:03 bug#14780: Regression: C-n doesn't go to next line under simple circumstances Barry OReilly [not found] ` <handler.14780.B.13728674128397.ack@debbugs.gnu.org> 2013-07-19 18:37 ` bug#14780: Acknowledgement (Regression: C-n doesn't go to next line under simple circumstances) Barry OReilly 2013-07-19 19:14 ` Eli Zaretskii 2013-07-19 19:53 ` Barry OReilly 2013-07-19 20:30 ` bug#14780: Regression: C-n doesn't go to next line under simple circumstances Eli Zaretskii 2013-07-19 20:37 ` Barry OReilly 2013-07-20 6:42 ` Eli Zaretskii 2013-07-20 8:33 ` Eli Zaretskii 2013-07-20 9:09 ` Eli Zaretskii 2013-07-22 20:37 ` Barry OReilly 2013-07-24 17:38 ` Eli Zaretskii
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/emacs.git https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.