GNU bug report logs - #68880
30.0.50; [pgtk] Theme customization is not applied by custom-theme-set-faces until theme is re-enabled

Previous Next

Package: emacs;

Reported by: Dmitry Gutov <dmitry <at> gutov.dev>

Date: Thu, 1 Feb 2024 23:15:02 UTC

Severity: normal

Found in version 30.0.50

Full log


View this message in rfc822 format

From: Mauro Aranda <maurooaranda <at> gmail.com>
To: 68880 <at> debbugs.gnu.org, Dmitry Gutov <dmitry <at> gutov.dev>
Subject: bug#68880: 30.0.50; [pgtk] Theme customization is not applied by custom-theme-set-faces until theme is re-enabled
Date: Sat, 8 Mar 2025 06:54:31 -0300
Dmitry Gutov <dmitry <at> gutov.dev> writes:

> To reproduce, put this into .emacs:
>
> (add-hook
>   'after-init-hook
>   (lambda ()
>     (load-theme 'adwaita t)
>
>     (custom-theme-set-faces
>      'adwaita
>      '(font-lock-comment-face ((t (:foreground "yellow")))))))
>
> Then run emacs -Q.
>
> When the PGTK port is used, the comment face's foreground won't be
> yellow. With other ports (e.g. GTK3 or Lucid), it is.

I can't reproduce it.  As expected, with emacs -Q, the lambda function
never gets called.

So, I see the same on the 3 builds I've tried (GTK3, Lucid,
PGTK): Emacs starts with the default theme.

> The use of after-init-hook itself it not crucial - you can just as well
> enable the theme using 'M-x load-theme' and then evaluate the
> custom-theme-set-faces form.

If I start with emacs -Q and then evaluate the forms inside the
lambda function, I can't reproduce it either, because I see the exact
same thing on the 3 builds: adwaita theme gets loaded and enabled, but
the font-lock-comment-face customization doesn't get customized to
yellow.

IOW, I can reproduce, but it's not pgtk specific.


I think this is related to Bug#76685.  But since I can't reproduce the
bug exactly as reported, I would like to check before merging the bugs.





This bug report was last modified 102 days ago.

Previous Next


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