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

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

bug#32672: 27.0.50; image resize on window resizing


From: Juri Linkov
Subject: bug#32672: 27.0.50; image resize on window resizing
Date: Sat, 27 Oct 2018 22:38:37 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu)

>> Your proposed window-state-change-functions would match window-state-get
>> very well, e.g. it could call the hook with an argument containing alist
>> of values that really changed, where elements of the alist could have
>> the same keys as in alist returned from window-state-get,
>
> Retaining the nomenclature of 'window-state-get' is part of the plan.
> But I'm not sure whether we want to retain all of what is recorded in
> a window state.
>
>> for example:
>>
>>    (add-hook 'window-state-change-functions (lambda (window alist) ...) nil 
>> t)
>>
>> where 'alist' could have such keys and values of changes:
>>
>>    (buffer "*scratch*") - means the buffer was switched in the window
>
> (buffer . #<buffer *scratch*>) rather

Here is a complete implementation that works well when tested
on display-buffer-directionally in bug#32790 (it doesn't handle
window-point because then the hook is called too often):

Attachment: window-state-change-functions.1.el
Description: application/emacs-lisp


reply via email to

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