GNU bug report logs -
#14604
24.3.50.1; Possibly incorrect behaviour of frame-selected-window
Previous Next
Reported by: E Sabof <esabof <at> gmail.com>
Date: Thu, 13 Jun 2013 11:47:02 UTC
Severity: normal
Found in version 24.3.50.1
Fixed in version 29.1
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Seemed to work during my brief test. Am I right in assuming that it's going
to become `pre-redisplay-functions' if it goes into production?
Evgeni
On Wed, Oct 30, 2013 at 7:23 PM, E Sabof <esabof <at> gmail.com> wrote:
> Thanks!
>
> Evgeni
>
>
> On Wed, Oct 30, 2013 at 5:50 PM, Stefan Monnier <monnier <at> iro.umontreal.ca>wrote:
>
>> > (defvar user-selected-window nil)
>> > (defun register-user-location ()
>> > (setq user-selected-window (selected-window)))
>> > (add-hook 'post-command-hook 'register-user-location)
>>
>> > (setq-default
>> > mode-line-format
>> > '(:eval (if (eq user-selected-window (selected-window))
>> > "selected"
>> > "not-selected")))
>>
>> That will usually work, except for corner-cases where redisplay happens
>> in the middle of a command, or when the selected window is modified
>> between commands (e.g. from a process sentinel).
>>
>> You can make it reliable with the use of the new
>> `pre-redisplay-function' hook (instead of post-command-hook), which
>> I just added yesterday.
>>
>> Of course, making it reliable doesn't mean it's not an omission.
>> I tend to agree that it would be good to provide access to that info
>> more directly.
>>
>>
>> Stefan
>>
>
>
[Message part 2 (text/html, inline)]
This bug report was last modified 3 years and 100 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.