all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Fabrice Popineau <fabrice.popineau@gmail.com>
Cc: 39188-done@debbugs.gnu.org
Subject: bug#39188: 28.0.50; w32 cursor redisplay problem
Date: Tue, 21 Jan 2020 18:32:54 +0200	[thread overview]
Message-ID: <838sm0wz0p.fsf@gnu.org> (raw)
In-Reply-To: <CAFgFV9PfFk102ieP5Gi9W1gSo+YDL9=H9ipk9ush5LTLUOiGfw@mail.gmail.com> (message from Fabrice Popineau on Mon, 20 Jan 2020 19:41:48 +0100)

> From: Fabrice Popineau <fabrice.popineau@gmail.com>
> Date: Mon, 20 Jan 2020 19:41:48 +0100
> Cc: 39188@debbugs.gnu.org
> 
> Maybe it is not the most important bug (except if Windows start to tell
> emacs that there are screen readers everywhere)

I found the problem.  As part of redisplay, we sometimes scroll
rectangular portions of the window, as pixels, up and down.  When we
do so, we first turn off the cursor, but when the system caret is used
instead of the cursor, we hide and unhide the caret in a separate UI
thread.  So there's a race between the main thread which scrolls the
pixels and the UI thread that draws the caret, and that race causes
the pixels of the caret to sometimes be copied with the rectangular
area that is scrolled.

The solution is to disable the scrolling in w32_scroll_run when the
system caret is in use.  This slows down redisplay to some extent
(because w32_scroll_run is a redisplay optimization), but I don't see
any easy way around that.

Should be fixed now on the emacs-27 branch.





  reply	other threads:[~2020-01-21 16:32 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-19  9:17 bug#39188: 28.0.50; w32 cursor redisplay problem Fabrice Popineau
2020-01-19 15:22 ` Eli Zaretskii
2020-01-19 15:39   ` Fabrice Popineau
2020-01-19 16:11     ` Eli Zaretskii
2020-01-19 16:32       ` Fabrice Popineau
2020-01-19 16:47         ` Eli Zaretskii
2020-01-19 17:29           ` Fabrice Popineau
2020-01-20 17:19           ` Eli Zaretskii
2020-01-20 18:41             ` Fabrice Popineau
2020-01-21 16:32               ` Eli Zaretskii [this message]
2020-01-21 16:36                 ` Fabrice Popineau
2020-01-21 16:59                   ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=838sm0wz0p.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=39188-done@debbugs.gnu.org \
    --cc=fabrice.popineau@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.