LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-29-2004, 01:01 PM   #1
Xavius
Member
 
Registered: Mar 2004
Posts: 107

Rep: Reputation: 15
How change text color using linux in text mode only runlevel 3?


How I can change the text color (and the background color) with linux at runlevel 3?
 
Old 03-29-2004, 01:18 PM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 270Reputation: 270Reputation: 270
Your looking for setterm command, read the man page here:
http://man.linuxquestions.org/index....ction=0&type=2

And if you want to change the default colors of directories, media files, etc, check your DIR_COLORS in /etc
 
Old 03-29-2004, 04:20 PM   #3
Xavius
Member
 
Registered: Mar 2004
Posts: 107

Original Poster
Rep: Reputation: 15
Thanks a lot trickykid

your solution seems to work... but if I use some commands like (for example) ls, after the text will have stardard color.....

I was searching something for change the text permanently.........

Have you another trick?
 
Old 03-29-2004, 04:32 PM   #4
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 270Reputation: 270Reputation: 270
You try changing the foreground color as well using setterm? And what about the DIR_COLORS file?
 
Old 08-28-2006, 10:53 AM   #5
CrippsFX
LQ Newbie
 
Registered: Aug 2004
Location: Canada
Distribution: Debian
Posts: 5

Rep: Reputation: 0
trickykid, it seems as though you are misunderstanding.
He does not want to change the color in a terminal ... he wants to change the color of the foreground text in the console ... for example: when I'm not running X, I want the console to display green by default.
I'm looking for the same thing too ...
 
Old 08-28-2006, 01:35 PM   #6
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 356Reputation: 356Reputation: 356Reputation: 356
I don't know how other distros handle it, but in SuSE, there is a folder (/etc/bootsplash/themes/SuSE/config) containing config files that can be edited to change foreground and background colors.

I expect other distros have something similar. Might take a bit of searching to find it.
 
Old 08-28-2006, 04:11 PM   #7
dracolich
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 1,274

Rep: Reputation: 63
I don't know if your distro works the same as mine - or if this is what you're looking for. I added a file to my home directory called .profile with the line to change the text color to red.

[QUOTE]export PS1='\[\033[0;31m\][\u@\h:\w]\$ \[\033[0;37m\]'[\QUOTE]

This makes the prompt red (0;31) with the prompt text as username@hostname:workingpath$ and then resets the color to gray (0;37). So if you wat it to stay red while you type just leave off the \[\033[0;37m\]. I don't remember where I found the numbers for the colors but after you find them just plug them into the line above. I don't know if this affects the output of commands such as ls. And this is user-specific so this only affects the user who has this file in their home directory.
 
Old 05-07-2009, 02:19 AM   #8
aloneattack
LQ Newbie
 
Registered: Aug 2007
Posts: 11

Rep: Reputation: 0
Please try:

Code:
setterm -foreground black -background white -store
more details here:
http://limestone.uoregon.edu/woven/H...lour-ls-6.html


Last edited by aloneattack; 05-07-2009 at 02:20 AM.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Text display not in CO80 mode after 2.6.12 kernel install in runlevel 3? rylan76 Linux - Software 2 07-05-2005 04:43 AM
No Video in Text Mode (runlevel 3) after Kernel 2.6.7 Upgrade tsales314 Linux - Laptop and Netbook 4 08-31-2004 02:06 AM
What is the command to change text color? BiO|Happy Mandriva 2 06-09-2004 02:54 PM
change text color eterm comprookie2000 Linux - Newbie 3 06-01-2004 05:33 PM
Chaning color of text using C in CLI mode WindowsBurner Programming 7 11-29-2003 08:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 11:29 PM.

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
Open Source Consulting | Domain Registration