emacs-devel
[Top][All Lists]
Advanced

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

deftheme, :inherit & overriding existing values


From: Dirk-Jan C . Binnema
Subject: deftheme, :inherit & overriding existing values
Date: Sat, 07 May 2011 12:17:06 +0300
User-agent: Wanderlust/2.15.9 (Almost Unreal) Emacs/24.0 Mule/6.0 (HANACHIRUSATO)

Hi all,

I've 'ported' the zenburn color theme
   https://github.com/djcb/elisp/blob/master/themes/zenburn-theme.el
to the new emacs 24+ color-theme system. I'm using the latest emacs 24 from
bzr.

Overall it works well if I start the theme from my .emacs startup, but it
works less well if I load a theme after some other packages. E.g., deftheme
before wanderlust works, but not the other way around.

Let's look at the 'describe-face' output, I've removed all the 'unspecified'
values.

Loading zenburn before Wanderlust (this works):
,----
| Face: wl-highlight-folder-unread-face (sample) (customize this face)
|        Inherit: (quote zenburn-red-3)
`----

Loading Wanderlust before zenburn (this does not work, i.e. the foreground
color will be 'gold', not 'zenburn-red-3'):

,----
| Face: wl-highlight-folder-unread-face (sample) (customize this face)
|     Foreground: gold
|     Inherit: (quote zenburn-red-3)
`----

Where zenburn-red-3 is defined as
       `(zenburn-red-3 ((t (:foreground ,zenburn-red-3))))

Apparently, :inherit does not really work as I expected...
       
Reloading the theme won't help -- but, what *does* help is visiting the theme
file and issuing M-x eval-buffer.

So, I'm not sure this is actually a *bug*, but the current behaviour seems
suboptimal anyhow. The equivalent of load-theme + eval-buffer gives the
expected result - maybe that should be the default behaviour of load-theme?

Best wishes,
Dirk.

-- 
Dirk-Jan C. Binnema                  Helsinki, Finland
e:address@hidden           w:www.djcbsoftware.nl
pgp: D09C E664 897D 7D39 5047 A178 E96A C7A1 017D DA3C



reply via email to

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