GNU bug report logs -
#6767
24.0.50; face-all-attributes returns unspecified for everything
Previous Next
Reported by: Jan Djärv <jan.h.d <at> swipnet.se>
Date: Sat, 31 Jul 2010 09:37:02 UTC
Severity: normal
Found in version 24.0.50
Done: Jan Djärv <jan.h.d <at> swipnet.se>
Bug is archived. No further changes may be made.
Full log
Message #8 received at 6767 <at> debbugs.gnu.org (full text, mbox):
> Date: Sat, 31 Jul 2010 11:36:52 +0200
> From: Jan Djärv <jan.h.d <at> swipnet.se>
> Cc:
>
> In *scratch*:
> (face-attribute 'italic :slant)
> italic ;; Good.
>
> (face-italic-p 'italic)
> (italic oblique) ;; Fine.
>
> (assq :slant (face-all-attributes 'italic))
> (:slant . unspecified) ;; Say what??
>
> In fact face-all-attributes gives me unspecified for all attributes in
> the faces I tried (about 5), including the default face.
This happens because face-new-frame-defaults has `unspecified' for all
the attributes of `italic' face (and all other faces as well). Try
(face-all-attributes 'italic (selected-frame))
and you will get what you expect.
> Did I misunderstand how face-all-attributes work?
I don't know, but it sounds like the doc string is at least misleading
in this regard. OTOH, this function is not used anywhere in Emacs, so
it could be buggy.
What is your use-case, exactly?
This bug report was last modified 15 years and 15 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.