[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Unexpected font face in C mode
From: |
Emanuel Berg |
Subject: |
Re: Unexpected font face in C mode |
Date: |
Sat, 10 Aug 2013 00:37:03 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.4 (gnu/linux) |
Rami A <rami.ammari@gmail.com> writes:
> Unfortunately when opening a c file I see #include and #define
> being black colored.
The faces you look for are, among others:
font-lock-preprocessor-face
font-lock-string-face
You can find that out (and the others) with this function:
(defun what-face (pos)
(interactive "d")
(let ((face (or (get-char-property (point) 'read-face-name)
(get-char-property (point) 'face))))
(if face (message "Face: %s" face)
(message "No face at %d." pos) )))
Or try `describe-char' - possibly, more robust, but also
verbose/disruptive (it opens a new buffer, as opposed to using the
echo area).
Then, in ~/.emacs, set it up like this:
(custom-set-faces
;;; gnus face
'(gnus-cite-1 ((t (:foreground "yellow" :bold nil))))
'(gnus-cite-2 ((t (:foreground "green" :bold nil))))
'(gnus-cite-3 ((t (:foreground "blue" :bold t ))))
; ...
)
Only, of course, you are not setting up the Gnus colors.
--
Emanuel Berg - programmer (hire me! CV below)
computer projects: http://user.it.uu.se/~embe8573
internet activity: http://home.student.uu.se/embe8573