[Top][All Lists]

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

bug#17392: 24.3.90; cursor blinks faster and faster

From: Stefan Monnier
Subject: bug#17392: 24.3.90; cursor blinks faster and faster
Date: Mon, 05 May 2014 08:25:48 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux)

> I think I found the culprit.  When changing the selected window (or
> frame), I arrange to call something like this:

> --8<---------------cut here---------------start------------->8---
> (defun my-flash-window ()
>   (interactive)
>   "Flash the selected window."
>   (unless (minibufferp)
>     ...
>     (run-with-idle-timer
>      0.001 nil
>      (lambda (win make-fringe-string ovl1 ovl2)
>        (overlay-put ovl1 'window win)
>        (overlay-put ovl2 'window win)
>        (overlay-put ovl1 'before-string (funcall make-fringe-string nil))
>        (overlay-put ovl2 'before-string (funcall make-fringe-string t))
>        (unless (window-minibuffer-p) (my-display-frame-list))
>        (sit-for 1.5)
>        (delete-overlay ovl1)
>        (delete-overlay ovl2))
>      win make-fringe-string ovl1 ovl2)))
> --8<---------------cut here---------------end--------------->8---

> to get some visual feedback.  The sit-for inside the timer function
> seems to trigger the problem.  This code is not kosher, I wanted to
> rewrite it anyway.  Now that I've done that (by just using a second timer),
> this seems to fixed.
> If there are no objections, I'll just close this report.

It still seems to point to an underlying bug in timer.el, even if it is
only triggered by "not kosher" code.
Would it be possible for you to try and extract a reproducible recipe from
your (old) code?


reply via email to

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