Adding Another Resolution to xrandr

From banana_wiki
Jump to: navigation, search

Typically when you use an old nvidia or ati card with GNU/Linux the maximum resolution will not be detected correctly. It is a real bummer running 1024x768 on a 23" screen, this should fix that issue. I have confirmed this to work on several old PCs with old-ish nvidia cards using nouveau as the driver.

First let’s make sure we can actually fit the new mode:

xrandr | grep maximum

Then we will use gtf to make the mode line we desire: * note: this example uses 1920x1080 as our desired resolution and 60Hz as our refresh rate, you may want to adjust yours accordingly.

gtf 1920 1080 60

Now we add the new mode with xrandr:

xrandr --newmode "1920x1080_60" 172.80 1920 2040 2248 2576 1080 1081 1084 1118 -HSync +Vsync

Now we add the mode to our desired output: * note: again yours may be different here

xrandr --addmode VGA 1920x1080_60

Now finally we apply the new mode:

xrandr --output VGA --mode 1920x1080_60</code>

Now to make it keep the changes we need to add these modes to xorg.conf

nano /etc/X11/xorg.conf

And Find your “Screen Section`: * note: yours may or may not look like below:

Section "Screen"
Identifier "Primary Screen"
Device "ATI Technologies, Inc. M22 [Radeon Mobility M300]"
EndSection

And add to it so it looks like:

Section "Screen"
Identifier "Primary Screen"
Device "ATI Technologies, Inc. M22 [Radeon Mobility M300]"
DefaultDepth 24SubSection "Display"
Depth 24Modes "1920x1080""1024x768""640x480"
EndSubSection
EndSection