Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 08-13-2004, 06:26 PM   #1
LQ Newbie
Registered: Aug 2004
Posts: 2

Rep: Reputation: 0
Why can't I change Emacs color settings?

For some reason, the color settings in my .emacs file always get overriden to white on black. For example, if I set my background color to yellow in .emacs, upon startup I will see the background flash yellow and then change right back to black.

I've checked to make sure I am only making one call to set-background-color in my .emacs file. It looks like there is something that's happening after the .emacs file is read that loads a new set of colors.

I am using red hat linux 9.
Old 08-13-2004, 11:16 PM   #2
Senior Member
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 53
yea it's a little weird -- this is what i do and it works
first to do background foregrond color in emacs in a file in your home dir first
used to be
so now i make both cause i can't remember which
read it in without logging out with "xrdb ~/.Xdefaults"
emacs.background: black
emacs.foreground: wheat
emacs.pointerColor: Orchid
emacs.cursorColor: Orchid
emacs.bitmapIcon: on
emacs.font: *fixed-bold-r-*-15-*-*
emacs.geometry: 107x40
ok then i put the background color i want at the very end of ~/.emacs
(setq initial-frame-alist
   '(background-color . "#010B45")
Old 08-14-2004, 01:05 AM   #3
LQ Newbie
Registered: Aug 2004
Posts: 2

Original Poster
Rep: Reputation: 0
I read in the .Xdefaults file with xrdb and set the bg color at the very end of the .emacs file, but it didn't work. I can watch the bg color progress as it initializes. It starts out with the bg color I set in my .Xdefaults file. It then changes to the color I set in .emacs (If i set it multiple times, I can see it flash each of the colors). It then always changes to white font on black background. I can then manually change the background with the set-background-color command with no problem.

The top menu bar ("File Edit Options Buffers Tools Help") always keeps the color settings from the .Xdefaults file.

Any suggestions?
Old 08-27-2004, 07:07 AM   #4
LQ Newbie
Registered: Aug 2004
Posts: 1

Rep: Reputation: 0

I had this problem and it turns out that the culprit is KDE, which is set by default to apply its colours to non-KDE apps.

I found the solution here:

I hope this helps, I am now enjoying Emacs with a lovely "papaya whip" background.



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
emacs - keep changes in settings kentri9 Linux - Software 5 04-13-2005 09:00 AM
Mplayer remember color settings TazG Linux - Software 0 07-13-2004 02:49 PM
emacs color-syntax highlighting with perl SerfurJ Linux - Software 2 09-22-2003 08:40 AM
color in emacs esromneb Linux - Software 2 07-17-2003 04:10 PM
how to change bg and fg color in emacs linux_rookie Linux - Software 1 06-23-2001 07:48 AM > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:09 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration