GNU bug report logs - #59943
30.0.50; ERC 5.5+: Add visual indicator to ERC keep-place

Previous Next

Package: emacs;

Reported by: "J.P." <jp <at> neverwas.me>

Date: Sat, 10 Dec 2022 15:53:02 UTC

Severity: normal

Tags: patch

Found in version 30.0.50

Fixed in version 30.1

Done: "J.P." <jp <at> neverwas.me>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: "J.P." <jp <at> neverwas.me>
To: 59943 <at> debbugs.gnu.org
Cc: emacs-erc <at> gnu.org
Subject: bug#59943: 30.0.50; ERC 5.5+: Add visual indicator to ERC keep-place
Date: Tue, 02 Jan 2024 06:47:39 -0800
[Message part 1 (text/plain, inline)]
From emacs -Q

  1. M-: (setopt erc-keep-place-indicator-follow t) RET
     M-x erc RET ... RET

  2. In the server buffer, do M-x erc-keep-place-indicator-mode RET

  3. Scroll "up" to hide the indicator but not so far that point moves
     beyond `erc-insert-marker'

  4. Switch away to another buffer and then back

  5. Notice the indicator fails to update

This happens because `keep-place-indicator' is a local module, and it
adds `erc--keep-place-indicator-on-window-buffer-change' to the hook
`window-buffer-change-functions' locally. But that function needs to run
in the buffer that's being switched to, which may not have the mode
enabled (and thus not have the hook member available). Subscribing to
the hook globally should fix the problem. There are also at least two
bugs affecting the integration between `keep-place-indicator' and
`keep-place'. The attached patch attempts to address these as well.

[0001-5.6-Make-erc-send-input-lines-a-normal-function.patch (text/x-patch, attachment)]
[0002-5.6-Use-global-window-hook-for-erc-keep-place-indica.patch (text/x-patch, attachment)]

This bug report was last modified 1 year and 137 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.