Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Emacs color theme setting

Tags:

emacs

i'm now configure my own emacs color theme , base on the color-theme plugin.

i just can't find how to define the status bar's color (where the current line number ,file name ,mode is shown ) .such as if you use color-theme-jb-simple , the status bar's color is likely blue4 ,but i can't find where it is defined .anyone knows ?

thanks all.

like image 692
mike Avatar asked Feb 25 '23 23:02

mike


2 Answers

I tried vpit3833's answer with 'modeline, but got an error on startup:
error: Invalid face, modeline

After some searching, I created the following:

;  I use the following with TERM=xterm-256color
(set-face-foreground 'mode-line "#606060")
(set-face-background 'mode-line "#202020")
(set-face-foreground 'mode-line-inactive "#606060")
(set-face-background 'mode-line-inactive "#202020")

My terminal is Xterm (with export TERM=xterm-256color), on Ubuntu 14.04 and Emacs version 24.3+1-2ubuntu1.

Update: I now set TERM=xterm-256color via a line in my ~/.Xdefaluts file:
xterm*termName: xterm-256color

You may find the following diagnostics to be useful:

M-x list-colors-display
M-x list-faces-display

Related links:

https://www.gnu.org/software/emacs/manual/html_node/emacs/Colors.html https://www.gnu.org/software/emacs/manual/html_node/emacs/Faces.html

like image 81
mpb Avatar answered Mar 04 '23 05:03

mpb


(set-face-background 'modeline "Blue") makes my modeline (what you call status bar is called modeline in Emacs) blue.

like image 42
vpit3833 Avatar answered Mar 04 '23 06:03

vpit3833