LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
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.

Notices


Reply
  Search this Thread
Old 03-08-2003, 07:57 PM   #1
s0ggyfish
LQ Newbie
 
Registered: Mar 2003
Distribution: Mandrake
Posts: 9

Rep: Reputation: 0
emacs help


Just installed mandrake 9.0 and after installing emacs, the color scheme is set to something pretty wierd, like olive green background on yellow text and its getting pretty annoying. I downloaded the same version (this time not modified by mandrake) and compiled it and after the install, the background color was white and the text was black, but the menubar was still yellow text on an olive green background. Any ideas on how to change this?
 
Old 03-08-2003, 09:22 PM   #2
Dark_Helmet
Senior Member
 
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
The difficult answer is: edit your ~/.emacs file

The easy answer would be to go through your Options Menu, Customize Emacs, and hunt down the colors somewhere in there. Unfortunately, I don't know them off-hand.
 
Old 03-08-2003, 10:36 PM   #3
rnturn
Senior Member
 
Registered: Jan 2003
Location: Illinois (Chicago area)
Distribution: Red Hat (8.0, RHEL5,6), CentOS, SuSE (10.x, 11.x, 12.2, 13.2), Solaris (8-10), Tru64, MacOS, Raspian
Posts: 1,113

Rep: Reputation: 65
Use the Resources, Luke!

Quote:
Originally posted by s0ggyfish
the background color was white and the text was black, but the menubar was still yellow text on an olive green background. Any ideas on how to change this?
I know what you mean. The buttugliest color scheme since DEC UNIX's defaults for Motif.

Create a file called ``.Xresources'' (usually you place this in $HOME). In that file, you can create the following lines:

emacs*Foreground: Black
emacs*Background: wheat2
emacs*geometry: 132x48

Then issue the command:

xrdb -merge $HOME/.Xresources

and rerun emacs. An emacs started on a remote system (with ``-display myhost'', for example) will use these same colors.

You can define or redefine just about anything you want for an X application if you know the name of the resource. (For hours of fun, fire up ``editres'' and see what's available in your favorite X application.)

Hope this helps,

Rick
 
Old 03-09-2003, 01:44 AM   #4
sienarot
Member
 
Registered: Mar 2003
Location: Calgary, Alberta, Canada
Distribution: Gentoo 1.4, Debian Woody, Mandrake 8.1
Posts: 43

Rep: Reputation: 15
What variable would I have to define so that the background behind the text is the same color as the screen background? Right now, while the background is whatever color, the text background is white.
 
Old 03-09-2003, 02:40 AM   #5
rnturn
Senior Member
 
Registered: Jan 2003
Location: Illinois (Chicago area)
Distribution: Red Hat (8.0, RHEL5,6), CentOS, SuSE (10.x, 11.x, 12.2, 13.2), Solaris (8-10), Tru64, MacOS, Raspian
Posts: 1,113

Rep: Reputation: 65
Quote:
Originally posted by sienarot
What variable would I have to define so that the background behind the text is the same color as the screen background? Right now, while the background is whatever color, the text background is white.
Oh, you have that problem. I noticed that when using the emacs that Red Hat was shipping with 7.1 (19.something??) but the one that was included with 8.0 (21.2.1) doesn't do that anymore. I never noticed it with the version that RH shipped with 6.2 either. As a workaround, I used to select a background color that was a very bright gray so that that character background color almost blended in. The slight difference in color wasn't too ugly. (OK, I was turning those lemons into lemonade :-) )

To build upon Dark_Helmet's suggestion, try:

Options -> Customize Emacs -> Faces (go to group) -> Basic Faces (go to group) -> Default face (show)

You can change the foreground and background colors there. I think any color that's in the rgb.txt file is okay to put in these fields. Even that lovely golden yellow on olive green.

At least that's the torturous menu path you have to take in emacs 21.2.1. There may be a slightly different way to get to those color resources in the emacs version you're running.

Hope this helps,

Rick
 
Old 03-09-2003, 05:50 AM   #6
s0ggyfish
LQ Newbie
 
Registered: Mar 2003
Distribution: Mandrake
Posts: 9

Original Poster
Rep: Reputation: 0
thanks guys for your help, got it working (sort of, color changes in .XResources don't work for the mandrake version of emacs, but they do for the one i installed, which i stumbled upon by running emacs-21.2 instead of just emacs). One strange thing though is that the toolbar disappeared after i renamed a .emacs file (in /usr/share/themes/thEmacs/emacs/.emacs) to something else, then ran emacs, saw no changes (less a toolbar) and then renamed it to .emacs and ran emacs again, with still no toolbar. Any ideas on how to fix this?
 
Old 03-09-2003, 11:04 AM   #7
rnturn
Senior Member
 
Registered: Jan 2003
Location: Illinois (Chicago area)
Distribution: Red Hat (8.0, RHEL5,6), CentOS, SuSE (10.x, 11.x, 12.2, 13.2), Solaris (8-10), Tru64, MacOS, Raspian
Posts: 1,113

Rep: Reputation: 65
Quote:
Originally posted by s0ggyfish
One strange thing though is that the toolbar disappeared after i renamed a .emacs file (in /usr/share/themes/thEmacs/emacs/.emacs) to something else, then ran emacs, saw no changes (less a toolbar) and then renamed it to .emacs and ran emacs again, with still no toolbar.
Themes for emacs? What a strange concept!

I wonder if something from the shared file got saved in .emacs file and that's what you're picking up now. Does such a file in $HOME have a recent timestamp? Mind you, I'm just guessing as my system doesn't have that emacs themes directory and I haven't defined anything in a personal .emacs file.

There is something in the emacs info pages about toolbars. I'd look there (M-x tool-bar-mode) to see if that fixes the missing toolbar.

Good luck...
 
  


Reply


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
where is the .emacs file in the emacs source code tarball? aizkorri Programming 2 01-13-2007 03:05 PM
emacs not responding to .emacs file in Mandriva 2005 LE. Please help LaptopLinux Mandriva 1 06-08-2005 09:36 AM
Emacs. shayan_tabrizi Linux - Software 1 07-23-2004 08:02 AM
edb (emacs database) won't open file - emacs 20 & 21 tip184 Linux - Software 0 04-03-2004 08:31 AM
Emacs HELP! sathyan Programming 6 07-18-2003 03:55 AM


All times are GMT -5. The time now is 03:46 AM.

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