unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#2066: Face `unspecified' inheritance ignores face-remapping-alist
@ 2009-01-26 14:46 David Reitter
  0 siblings, 0 replies; 5+ messages in thread
From: David Reitter @ 2009-01-26 14:46 UTC (permalink / raw)
  To: emacs-pretest-bug


[-- Attachment #1.1: Type: text/plain, Size: 605 bytes --]

Faces with an unspecified `inherit' attribute inherit from `default',  
right?

Unfortunately, this mechanism does not respect remapped faces (face- 
remapping-alist).  Faces, by default, seem to inherit from the frame  
default.  To demonstrate:

emacs -Q
(fundamental-mode)
(setq face-remapping-alist '((default . highlight)))
(insert (propertize "test" 'face 'fringe))

In a concrete use case, `csv-mode' fails to align its columns when  
face-remapping-alist is used, because one of its faces is not  
specified to inherit from default, causing it to inherit from the  
wrong face (see screenshot).



[-- Attachment #1.2: pastedGraphic.png --]
[-- Type: image/png, Size: 77717 bytes --]

[-- Attachment #1.3: Type: text/plain, Size: 2 bytes --]




[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 2193 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread
* bug#2066: Face `unspecified' inheritance ignores face-remapping-alist
@ 2009-01-27 19:16 Chong Yidong
  2009-01-27 20:46 ` David Reitter
  0 siblings, 1 reply; 5+ messages in thread
From: Chong Yidong @ 2009-01-27 19:16 UTC (permalink / raw)
  To: David Reitter; +Cc: 2066

> Faces with an unspecified `inherit' attribute inherit from `default',  
> right?
>
> Unfortunately, this mechanism does not respect remapped faces (face- 
> remapping-alist).  Faces, by default, seem to inherit from the frame  
> default.  To demonstrate:
>
> emacs -Q
> (fundamental-mode)
> (setq face-remapping-alist '((default . highlight)))
> (insert (propertize "test" 'face 'fringe))

I don't see any bug here.  The "test" string inserted into the buffer
has a background different from `highlight', but that's because its
background is not unspecified:

(defface fringe
  '((((class color) (background light))
     :background "grey95")
    (((class color) (background dark))
     :background "grey10")
    (t
     :background "gray"))
  "Basic face for the fringes to the left and right of windows under X."
  :version "21.1"
  :group 'frames
  :group 'basic-faces)






^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-06-09  9:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-26 14:46 bug#2066: Face `unspecified' inheritance ignores face-remapping-alist David Reitter
  -- strict thread matches above, loose matches on Subject: below --
2009-01-27 19:16 Chong Yidong
2009-01-27 20:46 ` David Reitter
2009-01-27 20:57   ` David Reitter
2012-06-09  9:38   ` Chong Yidong

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).