how to specify notmuch colors in emacs24

David Belohrad david at belohrad.ch
Tue Mar 11 03:02:13 PDT 2014


Hi All,

thanks for extensive answers on this thread. The plum-1 and other
definitions are coming from 'tango-dark' theme of emacs 24, which I
wanted to modify. I understood hence, that the two ways of settings the
colors (notmuch/emacs24) are so far somehow incompatible and hence there
is no way how to specify the notmuch colors the emacs24 way.

many thanks
.d.



Austin Clements <amdragon at MIT.EDU> writes:

> Quoth David Belohrad on Mar 06 at  2:24 pm:
>> Dear All,
>> 
>> so far I'm changing some color faces programmatically:
>> 
>>   (setq notmuch-search-line-faces '(("deleted" . (:foreground "red"
>>                                                   :background "blue"))
>>                                      ("unread" . (:foreground "DeepSkyBlue"))
>>                                      ("flagged" . (:foreground "firebrick1"))
>>                                      ))
>> 
>> 
>> I recently upgraded to emacs24. I was using default shipped tango-dark
>> theme. Then (because of VHDL mode I'm using) I have created a custom
>> theme, and I'd like to 'backport' the piece of code above into the
>> custom theme so it is in accordance with the philosophy of themes.
>> 
>> I have no idea how to specify it using the 'class approach',as e.g.
>> 
>>    `(gnus-group-news-1 ((,class (:foreground ,plum-1))))
>>    `(gnus-group-news-1-low ((,class (:foreground ,plum-2))))
>> 
>> Any hint would be greatly appreciated
>
> I'm not sure what the values of `class', `plum-1', and `plum-2' are in
> your above snippet or what the context of that snippet is, so I may be
> misunderstanding your problem, but it may help to know that
> `gnus-group-news-1' and `notmuch-search-line-faces' are very different
> types of variables.
>
> The value of `gnus-group-news-1' is a face; something like
> (:foreground "plum1").  It looks like what you've written above is
> actually a "face specification", which uses a bunch of conditions (the
> ,class part) to determine which of several potential faces to assign
> to the variable (though you listed only one face for each variable, so
> I'm not sure why you have a condition).  It's unfortunate that Emacs
> distinguishes faces and face specification, but that's how it is.
>
> `notmuch-search-line-faces' is *not* a face variable like
> `gnus-group-news-1'.  It's an association list that maps tags to
> faces.  As such, it won't work if your theme is trying to treat it
> like a face variable, since its value is not a face, but rather a data
> structure that has faces in it.


More information about the notmuch mailing list