GNU bug report logs - #44100
26.3; ERC: Make IBuffer custom display work again

Previous Next

Package: emacs;

Reported by: Olivier Certner <ocert.dev <at> free.fr>

Date: Tue, 20 Oct 2020 16:49:01 UTC

Severity: normal

Tags: patch

Found in version 26.3

Done: Amin Bandali <bandali <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #22 received at 44100 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Amin Bandali <bandali <at> gnu.org>
Cc: Corwin Brust <corwin <at> bru.st>, emacs-erc <at> gnu.org, 44100 <at> debbugs.gnu.org,
 Olivier Certner <ocert.dev <at> free.fr>
Subject: Re: bug#44100: Patch
Date: Sun, 01 Nov 2020 14:09:54 +0100
Amin Bandali <bandali <at> gnu.org> writes:

> However, I came up with a potentially more proper different fix: I think
> the presence of the dotted pair with a non-nil cdr is the main problem,
> since it means `erc-modified-channels-alist' does not fully adhere to
> the documented structure in its docstring.  So I addressed the issue in
> `erc-track-modified-channels' by wrapping up single faces in lists too,
> ensuring that `erc-modified-channels-alist' never ends in a non-nil cdr.
>
> Something along the lines of the following patch.  Thoughts?

[...]

>    (when erc-face
>      (put-text-property 0 (length channame) 'face erc-face channame)
> -    (when (eq erc-face 'erc-default-face)
> +    (when (eq (car erc-face) 'erc-default-face)
>        (add-face-text-property 0 (length channame) 'bold t channame)))
>    channame)

Normalising to having a list of faces here sounds like a good idea, if
I'm skimming the code correctly, but it would probably help
comprehension a bit here if you renamed the parameter from `erc-face' to
something like `face-list'.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 3 years and 297 days ago.

Previous Next


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