[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: |
Sun, 23 Sep 2018 01:15:06 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) |
>> (add-hook 'change-major-mode-hook 'image-toggle-display-text nil t)
>> (add-hook 'after-revert-hook 'image-after-revert-hook nil t)
>> + (add-hook 'window-size-change-functions (debounce
>> 'image-size-window-change 1) nil t)
>> + (add-hook 'buffer-list-update-hook 'image-size-buffer-change nil t)
>
> Shouldn't you debounce the call to 'image-size-buffer-change' as well?
> After all, the buffer list seems to change more often than the size of
> windows.
When I tried debounce for buffer-list-update-hook, it used the last call
in sequence:
1 ... current: *scratch* ... window-buffer: *scratch*
2 ... current: *scratch* ... window-buffer: *info*
that was unsuitable for the logic of 'image-size-buffer-change'.
So maybe instead of 'debounce', we need to implement and use 'throttle'
or at least implement the 'immediate' option that uses the first call:
https://css-tricks.com/debouncing-throttling-explained-examples/
> In either case you probably want me to install the
> 'buffer-list-update-hook' changes. Correct?
Yes, please install it, if you see no more regressions.
- bug#32672: 27.0.50; image resize on window resizing, (continued)
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/15
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/16
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/16
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/17
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/17
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/19
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/19
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/20
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/20
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/21
- bug#32672: 27.0.50; image resize on window resizing,
Juri Linkov <=
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/23
- bug#32672: 27.0.50; image resize on window resizing, Juri Linkov, 2018/09/23
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, Eli Zaretskii, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, Eli Zaretskii, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, Eli Zaretskii, 2018/09/24
- bug#32672: 27.0.50; image resize on window resizing, martin rudalics, 2018/09/25
- bug#32672: 27.0.50; image resize on window resizing, Eli Zaretskii, 2018/09/25