Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I change the color depth on Ubuntu?

Status
Not open for further replies.

cpjust

Programmer
Sep 23, 2003
2,132
0
0
US
All I can see in the System menu are options for changing my background & resolution, but I don't see anything that lets me change the number of colors used.
 
Hmm... So I need to manually edit the /etc/X11/xorg.conf file? You'd think after all this time that someone would have written a GUI for it just like they have for changing the resolution...

BTW, after I edit that file, how do I get it to re-read that file and make the change? Hopefully I can do it without restarting X Windows.
 
OK, so I should go to runlevel 1 and then back to 5.

If I do that, will it close all the programs that are currently running in X Windows or will everything be exactly like it was (with the exception of the color depth)?
 
It will kill every graphical program.

I'm sceptical that you have to go to runlevel 1 though. Generally in Linux systems, level 1 is for single-user, no-networking mode, minimal system services running, and is used for maintenance (i.e. when you seriously fsck up your whole system and it won't boot even to runlevel 3 normally).

Runlevel 3 is multi-user, text-mode, with networking. generally server machines run at runlevel 3, this is what should be thought of when you hear about running Linux with no GUI at all.

runlevel 5 has X Windows.

So you should be able to drop to runlevel 3 and go back up to 5. Leaving 5 though kills X and every graphical app that depends on X, and shuts down any system services that only run at level 5 (there's not many... things like the backend to the GNOME Network Manager applet are the kinds of services that run in level 5, i.e. things that rely on a graphical system).

Cuvou.com | My personal homepage
Code:
perl -e '$|=$i=1;print" oo\n<|>\n_|_";x:sleep$|;print"\b",$i++%2?"/":"_";goto x;'
 
what is the big freaking deal about shutting down X, putting up the changes, and starting X to see what happens?

D.E.R. Management - IT Project Management Consulting
 
thedaver said:
what is the big freaking deal about shutting down X, putting up the changes, and starting X to see what happens?
Well I have a lot of programs open, and it would be nice if I could change the color depth without having to shutdown and re-open all my programs.

Since you can change the resolution without restarting X I don't see why changing the color depth would be any different though.
Does anyone know how the Screen Resolution GUI app does it? Maybe the same would work for the color depth?
 
The key combination Ctrl-Alt-Backspace will kill X and restart it, without having to mess with runlevels at all. It's also handy to know if a graphical app starts freezing up your system... Ctrl-Alt-Backspace will kill it and everything else and give ya a new login window to log back in, without having to do a hard reboot like in Windows when a similar situation arises.

If Ctrl-Alt-Backspace doesn't work, then it was probably disabled. Fedora 11 plans to disable this keyboard shortcut by default by adding the "DontZap" option in xorg.conf; if that's there already in Ubuntu, then set it to "false" or delete it.

Alternatively, I'm relatively sure that just doing a simple "System -> Log Out" will kill X and restart it again too, as the effect is the same, and the GDM manager usually doesn't run in the same X session as your desktop (try starting x11vnc when no user is logged on and you'll see what I mean).

Cuvou.com | My personal homepage
Code:
perl -e '$|=$i=1;print" oo\n<|>\n_|_";x:sleep$|;print"\b",$i++%2?"/":"_";goto x;'
 
Thanks,
I'll try that when I'm not too busy.
 
This is actually a good deal. Thanks I didn't even know about the ctrl _ alt_backspace deal thanks.
 
Wow, Ctrl-Alt-Backspace restarts X-Windows immediately!

After switching to 16-bit color, VNC doesn't suck anymore and I can actually read what's on the screen. Thanks.
 
Wow, Ctrl-Alt-Backspace restarts X-Windows immediately!

What were you expecting?

"We can categorically state that we have not released man-eating badgers into the area" - Major Mike Shearer
 
I was expecting it to close each application cleanly just like when you do a Logout.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top