Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

can i modify the color of emacs mini buffer?

Tags:

emacs

i like emacs in terminal,but the blue color of mini buffer is hard to see clearly.

really need it,thanks for help!

like image 649
chenge Avatar asked Jul 03 '10 09:07

chenge


2 Answers

Try this,

(set-face-foreground 'minibuffer-prompt "white")
like image 131
huaiyuan Avatar answered Oct 23 '22 18:10

huaiyuan


If you can't stand your terminal's blue color, you can probably change it. The different terminal emulators have different tools for this, but most use X resources.

My own personal color choices for urxvt:

URxvt.background:       #000000
URxvt.foreground:       gray75
URxvt.color3:           DarkGoldenrod
URxvt.color4:           RoyalBlue
URxvt.color11:          LightGoldenrod
URxvt.color12:          LightSteelBlue
URxvt.color7:           gray75
URxvt.colorBD:          #ffffff
URxvt.colorUL:          LightSlateGrey
URxvt.colorIT:          SteelBlue
URxvt.cursorColor:      grey90
URxvt.highlightColor:   grey25

But of course, your own terminal emulator of choice may have a different class (URxvt) or application (urxvt, not used in my example) name, and the resource names may be different as well. urxvt will use color names (from the server's rgb.txt file -- use xcolorsel(1) to see them in a handy application) or numbers, but other terminals may not be this flexible.

From my xterm(1) manpage, the colors and their numbers are:

0  black
1  red3
2  green3
3  yellow3
4  a customizable dark blue
5  magenta3
6  cyan3
7  gray90

8  gray30
9  red
10 green
11 yellow
12 a customizable light blue
13 magenta
14 cyan
15 white

If your terminal does use X resources, save your desired resources to a file (by convention named ~/.Xdefaults or ~/.Xresources) and use xrdb -merge <filename> to load your resources into the server. Then start your terminal again, and try it out.

If your terminal uses some other mechanism to configure color choices (perhaps it has a Preferences menu item or something similar), it will probably still have different colors listed somewhere, and you'll need to change colors 4 and 12 to change the blue color.

On the other hand, if you like the blue for everything except emacs, you can either try to get emacs to use a different color (no idea there, sorry), or you can run your terminal emulator with a different "class", so it will read different X resources. (xterm(1) has a -class parameter for this.)

like image 3
sarnold Avatar answered Oct 23 '22 17:10

sarnold