It really couldn’t be simpler to plug in a second monitor to your laptop and increase your screen real estate in Ubuntu 8.04. The instructions that follow is for integrated graphic card (in my case, it’s Intel 810 graphics driver for laptop). First, use xrandr in terminal to see how many displays are connected/detected by Ubuntu (usually LVDS refers to your laptop screen, and VGA is your external monitor). Once all your displays are connected, enable dual monitor support by doing:
xrandr --output LVDS --mode 1024x768 --pos 0x0 --output VGA --mode 1280x1024 --pos 1024x0
The arguments mode and pos after output LVDS (or VGA) define the screen resolution and which part is displayed in that screen, respectively. For instance, when you used the above command, the graphics controller created a virtual screen that is 2560×1024 large. The block of 1024×768 starting from the top-left corner (0x0) will be displayed in LVDS, while the block of 1280×1024, starting from 1024×0 will be displayed in VGA. There is a missing block of 1024x(1024-768) starting from 0x768 that is not displayed at all, but I can live with that.
The first time you use the above command, you might get an error complaining “xrandr: screen cannot be larger than 1024×800 (desired size 2560×1024)”. In that case, you need to edit /etc/X11/xorg.conf (remember to create a backup). Insert these lines in between Section "Screen" and its corresponding EndSection
SubSection "Display"
Virtual 2560 1024
EndSubSection
The two numbers assign the (maximum) size of your virtual screen.
Read More »