emacs-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debbugs-tracker] bug#34038: closed (26.1; set-window-start sometimes fa


From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#34038: closed (26.1; set-window-start sometimes fails to set window start)
Date: Sat, 06 Apr 2019 08:24:02 +0000

Your message dated Sat, 06 Apr 2019 11:23:24 +0300
with message-id <address@hidden>
and subject line Re: bug#34038: 26.1; set-window-start sometimes fails to set 
window start
has caused the debbugs.gnu.org bug report #34038,
regarding 26.1; set-window-start sometimes fails to set window start
to be marked as done.

(If you believe you have received this mail in error, please contact
address@hidden)


-- 
34038: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=34038
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: 26.1; set-window-start sometimes fails to set window start Date: Thu, 10 Jan 2019 20:57:28 +0100
To reproduce this issue, please start Emacs with "$ emacs -Q" and paste
at the end of the *scratch* buffer the following form:

    (progn
      (goto-char (point-max))
      (insert "\n")
      (dotimes (x (window-height))
        (insert (format "%s\n" x)))
      (redisplay)
      (let ((b (buffer-string))
            (p (point)))
        (set-window-start nil p t)
        (read-key "Please press a key to continue.")
        (erase-buffer)
        (insert b)
        (set-window-start nil p t)))

Then, put point at the end of the form, and evaluate it with C-x C-e.

Conceptually, this program:

     1) inserts several (i.e, window-height) lines into the buffer
     2) sets window point to p, which is point after (1)
     3) WAITS FOR A KEY PRESS (please press a key at this point)
     4) erases and restores the buffer contents
     5) sets window point to p, the same point as in (2)

However, in many invocations (please try it repeatedly if necessary),
the visible portion of the buffer unexpectedly differs between (3) and
after the whole procedure.

In other words, when Emacs waits for a key press, a different portion of
the buffer is visible compared to after you press a key, even though
window-start is set to the same position in both cases.

Is there a way to reliably set the window-start in such situations?

Thank you very much!
Markus

In GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, X toolkit, Xaw scroll bars)
 of 2018-11-18 built on debian
Repository revision: 07f8f9bc5a51f5aa94eb099f3e15fbe0c20ea1ea
Windowing system distributor 'The X.Org Foundation', version 11.0.11902000
System Description:     Debian GNU/Linux 9.6 (stretch)



--- End Message ---
--- Begin Message --- Subject: Re: bug#34038: 26.1; set-window-start sometimes fails to set window start Date: Sat, 06 Apr 2019 11:23:24 +0300
> Date: Fri, 29 Mar 2019 11:29:43 +0300
> From: Eli Zaretskii <address@hidden>
> Cc: address@hidden, address@hidden
> 
> > Personally, I would appreciate some comment regarding such a guarantee,
> > or the assumptions, in the documentation of set-window-start.
> 
> OK, I will add something to that effect, thanks for pointing this out.

Now done on the emacs-26 branch.


--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]