;; This file: http://user.it.uu.se/~embe8573/conf/emacs-init/faces.el (font-lock-add-keywords 'emacs-lisp-mode '( ("(?interactive?)" . font-lock-builtin-face) ("font-lock-builtin-face" . font-lock-builtin-face) ("font-lock-comment-delimiter-face" . font-lock-comment-delimiter-face) ("font-lock-comment-face" . font-lock-comment-face) ("font-lock-constant-face" . font-lock-constant-face) ("font-lock-doc-face" . font-lock-doc-face) ("font-lock-function-name-face" . font-lock-function-name-face) ("font-lock-keyword-face" . font-lock-keyword-face) ("font-lock-negation-char-face" . font-lock-negation-char-face) ("font-lock-preprocessor-face" . font-lock-preprocessor-face) ("font-lock-reference-face" . font-lock-reference-face) ("font-lock-string-face" . font-lock-string-face) ("font-lock-syntactic-face-function" . font-lock-syntactic-face-function) ("font-lock-type-face" . font-lock-type-face) ("font-lock-variable-name-face" . font-lock-variable-name-face) ("font-lock-warning-face" . font-lock-warning-face) ("font-lock-regexp-grouping-construct" . 'font-lock-regexp-grouping-construct) ("font-lock-regexp-grouping-backslash" . 'font-lock-regexp-grouping-backslash) ) t) ; HOW (append) (defun what-face (pos) (interactive "d") (let((face (or (get-char-property pos 'face) (get-char-property pos 'read-cf-name) ))) (message " Face: %s" (or face "(no face!)")) )) (defmacro define-color-face (name front &optional bold back) `(progn (defvar ,name) (setq ,name '((t (:foreground ,front :background ,back :bold ,bold) ))))) (define-color-face cf-black "black") (define-color-face cf-red "red") (define-color-face cf-green "green") (define-color-face cf-blue "blue") (define-color-face cf-yellow "yellow") (define-color-face cf-magenta "magenta") (define-color-face cf-cyan "cyan") (define-color-face cf-white "white") (define-color-face cf-white-on-blue "white" nil "blue") (define-color-face cf-white-on-red "white" t "red") (define-color-face cf-white-on-black "white" nil "black") (define-color-face cf-gray "black" t) (define-color-face cf-pale-red "red" t) (define-color-face cf-green-b "green" t) (define-color-face cf-orange "yellow" t) (define-color-face cf-blue-b "blue" t) (define-color-face cf-pink "magenta" t) (define-color-face cf-dark-gray "cyan" t) (define-color-face cf-white-b "white" t) (define-color-face cf-gray-on-black "black" t "black") (define-color-face cf-pale-red-on-black "red" t "black") (define-color-face cf-black-on-white "black" nil "white") (define-color-face cf-gray-on-white "cyan" t "white") (define-color-face cf-cyan-on-black "cyan" nil "black") (define-color-face cf-dark-gray-on-blue "cyan" t "blue") (define-color-face cf-white-b-on-blue "white" t "blue") (define-color-face cf-white-b-on-red "white" t "red") (define-color-face cf-yellow-on-black "yellow" nil "black") (define-color-face cf-yellow-on-red "yellow" nil "red") (define-color-face cf-black-background nil nil "black") (define-color-face cf-all-black "black" nil "black") (define-color-face cf-button "green" t) (custom-set-faces `(nobreak-space ,cf-gray) `(bold ,cf-blue-b) `(bold-italic ,cf-magenta) `(underline ,cf-gray) `(buffer-menu-buffer ,cf-green) `(button ,cf-button) `(custom-buttom-unraised ,cf-green) `(custom-variable-tag ,cf-yellow) `(default ,cf-white-on-black) `(compilation-mode-line-exit ,cf-cyan) `(dired-directory ,cf-blue-b) `(dired-flagged ,cf-blue) `(dired-header ,cf-green) `(dired-ignored ,cf-gray) `(dired-mark ,cf-orange) `(dired-marked ,cf-yellow) `(dired-perm-write ,cf-red) `(dired-symlink ,cf-cyan) `(dired-warning ,cf-pale-red) `(font-lock-builtin-face ,cf-pink) `(font-lock-comment-delimiter-face ,cf-blue) `(font-lock-comment-face ,cf-blue-b) `(font-lock-variable-name-face ,cf-green-b) `(font-lock-keyword-face ,cf-orange) `(font-lock-string-face ,cf-green) `(font-lock-preprocessor-face ,cf-magenta) `(font-lock-constant-face ,cf-magenta) `(font-lock-warning-face ,cf-red) `(font-lock-doc-face ,cf-gray) `(font-lock-type-face ,cf-pale-red) `(font-lock-regexp-grouping-construct ,cf-white) `(font-lock-negation-char-face ,cf-gray) `(font-lock-function-name-face ,cf-yellow) `(font-lock-regexp-grouping-backslash ,cf-white-b) `(erc-action-face ,cf-white-b) `(erc-bold-face ,cf-yellow) `(erc-button ,cf-button) `(erc-command-indicator-face ,cf-dark-gray) `(erc-current-nick-face ,cf-orange) `(erc-dangerous-host-face ,cf-red) `(erc-default-face ,cf-white) `(erc-direct-msg-face ,cf-magenta) `(erc-error-face ,cf-pale-red) `(erc-fool-face ,cf-cyan) `(erc-header-line ,cf-white-on-red) `(erc-input-face ,cf-yellow) `(erc-inverse-face ,cf-pink) `(erc-keyword-face ,cf-white) `(erc-my-nick-face ,cf-yellow) `(erc-nick-default-face ,cf-blue-b) `(erc-nick-msg-face ,cf-white) `(erc-notice-face ,cf-green) `(erc-pal-face ,cf-blue) `(erc-prompt-face ,cf-gray) `(erc-timestamp-face ,cf-pale-red) `(erc-underline-face ,cf-green-b) `(nick-default-face ,cf-white) `(gnus-button ,cf-button) `(gnus-cite-1 ,cf-orange) `(gnus-cite-2 ,cf-green) `(gnus-cite-3 ,cf-pink) `(gnus-cite-4 ,cf-dark-gray ) `(gnus-cite-attribution ,cf-yellow) `(gnus-emphasis-bold ,cf-yellow) `(gnus-group-mail-1 ,cf-yellow) `(gnus-group-mail-1-empty ,cf-orange) `(gnus-group-mail-2 ,cf-cyan) `(gnus-group-mail-2-empty ,cf-cyan) `(gnus-group-mail-3 ,cf-cyan) `(gnus-group-mail-3-empty ,cf-dark-gray) `(gnus-group-mail-low ,cf-pink) `(gnus-group-mail-low-empty ,cf-gray) `(gnus-group-news-1 ,cf-dark-gray ) `(gnus-group-news-1-empty ,cf-cyan) `(gnus-group-news-2 ,cf-dark-gray ) `(gnus-group-news-2-empty ,cf-cyan) `(gnus-group-news-3 ,cf-blue-b) `(gnus-group-news-3-empty ,cf-blue) `(gnus-group-news-4 ,cf-blue-b) `(gnus-group-news-4-empty ,cf-blue) `(gnus-group-news-5 ,cf-green-b) `(gnus-group-news-5-empty ,cf-green) `(gnus-group-news-6 ,cf-blue-b) `(gnus-group-news-6-empty ,cf-blue) `(gnus-summary-normal-ancient ,cf-gray) `(gnus-summary-normal-read ,cf-gray) `(gnus-summary-normal-ticked ,cf-yellow) `(gnus-summary-selected ,cf-white-on-blue) `(gnus-summary-selected ,cf-white-on-blue) `(gnus-server-opened ,cf-green) ;; gnus-server-agent ;; gnus-server-closed ;; gnus-server-denied ;; gnus-server-offline ;; gnus-server-opened `(help-argument-name ,cf-blue-b) `(info-header-node ,cf-yellow) `(info-header-xref ,cf-cyan) `(info-index-match ,cf-magenta) `(info-menu-header ,cf-magenta) `(info-menu-star ,cf-gray) `(info-node ,cf-red) `(info-title-1 ,cf-blue-b) `(info-title-2 ,cf-black) `(info-title-3 ,cf-cyan) `(info-title-4 ,cf-pink) `(info-xref ,cf-green) `(info-xref-visited ,cf-green) `(italic ,cf-green) `(Man-overstrike ,cf-green) ; .BR `(Man-reverse ,cf-red) ; ? `(Man-underline ,cf-blue-b) ; .I `(message-cited-text ,cf-green) `(message-header-cc ,cf-blue-b) `(message-header-name ,cf-gray) `(message-header-newsgroups ,cf-blue-b) `(message-header-other ,cf-white) `(message-header-subject ,cf-pale-red) `(message-header-to ,cf-magenta) `(minibuffer-prompt ,cf-green) `(mm-uu-extract ,cf-gray) `(mode-line ,cf-white-b-on-blue) `(mode-line-inactive ,cf-gray-on-white) `(sh-quoted-exec ,cf-pale-red) `(show-paren-match ,cf-white-on-blue) ;; w3m `(w3m-anchor ,cf-green) `(w3m-arrived-anchor ,cf-green) `(w3m-bold ,cf-blue-b) `(w3m-current-anchor ,cf-green-b) `(w3m-error ,cf-red) `(w3m-form ,cf-pale-red) `(w3m-form-button ,cf-button) `(w3m-form-button-pressed ,cf-green) `(w3m-form-inactive ,cf-blue) `(w3m-header-line-location-content ,cf-yellow) `(w3m-header-line-location-titl ,cf-magenta) `(w3m-history-current-url ,cf-cyan) `(w3m-image ,cf-magenta) `(w3m-image-anchor ,cf-green) `(w3m-insert ,cf-white) `(w3m-italic ,cf-yellow) `(w3m-session-select ,cf-white-on-blue) `(w3m-session-selected ,cf-white-on-red) `(w3m-strike-through ,cf-white-on-black) `(w3m-tab-background ,cf-black-background) `(w3m-tab-selected ,cf-pale-red-on-black) `(w3m-tab-selected-background ,cf-gray) `(w3m-tab-selected-retrieving ,cf-white-b-on-blue) `(w3m-tab-unselected ,cf-gray-on-black) `(w3m-tab-unselected-retrieving ,cf-green) `(w3m-underline ,cf-pale-red) `(widget-button ,cf-button) `(widget-field ,cf-yellow) `(comint-highlight-input ,cf-cyan) `(comint-highlight-prompt ,cf-gray) )