Archive for January, 2004
LCOD – 1.21.04 – Change default resolutions in X
Posted by Jon Zobrist in Linux, Linux Command of the Day on January 21, 2004
edit /etc/X11/XF86Config-4
(or /etc/X11/XF86Config if that’s what you have)
find the line that says DefaultColorDepth X
where X is something like 8/15/16/24.
This tells you what your default color depth is in bits per pixel (bpp).
You likely want 16 or 24 for high/true color.
Now, in the same section find the Subsection that has the Depth entry that matches your DefaultColorDepth ( Depth 16 if your DefaultColorDepth was 16, for example.)
See the line that says something like
Modes “1280×1024″ “1024×768″ “800×600″ “640×480″
Those are your resultions, seperated by a space, and in order that you prefer them. So if you have “1280×1024″ and you’d rather have “1600×1200″ add a “1600×1200″ to the first part after Modes. So, in this example, you would have
Modes “1600×1200″ “1280×1024″ “1024×768″ “800×600″ “640×480″
Now, logout of your X windows, some versions of Linux this will restart your X display, some it will not. Most X servers allow you to use the CTRL ALT BACKSPACE to kill the X server, so do this at the login screen if it hasn’t already resized to your new resolution.
Also note, you can hit CTRL ALT + or CTRL ALT – to change your resolution in X while it’s running. This will use your first entry as the default desktop size, which will become a virtual size if you go to a smaller, causing you to only view part of your desktop. If you want to permenantly make your desktop smaller, just delete the parts on the Modes line before the resolution you want. So if you wanted 640×480 desktop, your modes would look like this after
Modes “640×480″
thats it