[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the w
From: |
Eli Zaretskii |
Subject: |
bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window |
Date: |
Wed, 23 Mar 2016 21:18:10 +0200 |
> From: Jorgen Schaefer <jorgen.schaefer@gmail.com>
> Date: Wed, 23 Mar 2016 19:40:27 +0100
>
> Evaluating the following code in "emacs -Q" leaves point in the middle
> of the window, instead of at the end of the window as expected. Certain
> modes (IRC) want to keep the buffer flushed at the end of the window,
> this problem interferes with that behavior and causes very weird jumpy
> scrolling.
>
>
> (require 'cl)
> (let* ((b (get-buffer-create "*Bug Repro*"))
> (w (selected-window))
> (l (window-height w))
> o)
> (set-window-buffer w b)
> (select-window w)
> (set-buffer b)
> (erase-buffer)
> (cl-dotimes (i (* l 2))
> (insert "foo\n"))
> (goto-char (point-min))
> (forward-line (+ l 2))
> (setq o (make-overlay (point) (point)))
> (overlay-put o 'after-string "\n")
> (goto-char (point-max))
> (recenter -1))
>
>
> That is, if there is a multi-line overlay that would be shown only
> halfway.
I'm not sure I understand: are you trying to display a window whose
start point is in the middle of an overlay string? That's not
possible, AFAIK. The window-start point must be a buffer position.
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schaefer, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window,
Eli Zaretskii <=
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, John Wiegley, 2016/03/26
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Andreas Schwab, 2016/03/27
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Drew Adams, 2016/03/27
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/28