Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm sure the answer to this question was already presented here in some where, but a quick search (here + Google) didn't find it.

I connect a screen to my laptop, and it's blank. How do I extend my desktop to this screen?

share|improve this question
    
Although that's technically done with the operating system's cooperation, Linux follows the standard set by makers, who have done two things: engraved an icon on F5 to indicate that the function key is Fn+F5 (on many, but not all, laptops), and provided a windows driver. So if all you want to know is the key combination, this question is off-topic. But if you also want other methods such as a command line or GUI application, the question is on-topic. –  Gilles May 4 '11 at 23:00

3 Answers 3

For example in KDE4 you run System Settings, and in Display settings you select to extend monitor (and also at which side -- left or right -- you would like to "place" the second monitor). 100% straightforward.

share|improve this answer

Right now I am answering this with my notebook connected to a monitor. To have my desktop extended I use xrandr and its graphical interface ARandR, both of them working pretty well.

Indeed I have a script, which I execute everytime I log to my notebook having the screen attached to it:

#!/bin/sh
xrandr --output LVDS1 --mode 1280x800 --pos 0x0 --rotate normal --output VGA1 --mode 1440x900 --pos 1280x0 --rotate normal --output HDMI1 --off

To understand it, first of all you must see that it references three outputs: LVDS1 which is the laptop screen; VGA1 which is my external monitor; and HDMI1 which is disabled (option --off right after it) cause I don't have any monitor attached to that port.

You can get the list of outputs available with:

xrandr -q

Following every output are some parameters that set specific features for them:

  • mode: sets the resolution of the output.
  • pos: which sets the position of the output relative to the top left corner of the composed desktop.
  • rotate: which sets the rotation you want for the output.

I have an Intel graphics adapter. In the case of nVidia, they have an application to select TwinView, for example.

share|improve this answer
    
tl;dr :) Can you summarize why your answer is better than Fn-F5? –  ripper234 May 5 '11 at 18:50
    
Simple: because not always Fn-F5 works, and with the method I described you can position just as you need the screens you are using. I have a link to that script in my desktop, so that when I have the external monitor attached to my laptop, I can easily set up the screens (without it, the system just enables the external monitor and shuts off the one of the laptop). –  nozimica May 5 '11 at 20:35

(Let me treat this Q&A as a memo to my future self)

The easiest way I found with simply press the "extend desktop" button - Function F5.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.