Ignore laptop LCD when external display present

Ross Burton ross at burtonini.com
Fri Mar 9 13:04:31 PST 2007


On Fri, 2007-03-09 at 13:52 -0600, Ian Pilcher wrote:
> I have a ThinkPad T42 with an ATI Radeon Mobility M7 chip (radeon
> driver) and a built-in 1024x768 LCD.  I also have a port replicator and
> a 1280x1024 LCD monitor.  When the laptop is in the port replicator
> (to which the external LCD is connected), I would like X to ignore the
> built-in 1024x768 LCD and exclusively use the external 1280x1024 LCD.
> 
> Is this possible?  The "default" behavior seems to limit the resolution
> displayed on the external LCD to 1024x768 (the resolution of the built-
> in LCD).  I can force things with the PanelSize option, but that makes
> the built-in display useless when the laptop isn't in the port
> replicator.

The default policy of xrandr is to display *something* on all screens,
instead of having screens that should work but don't.  Obviously in this
case (and mine) you want to turn off the internal screen.

I have a small script that I've bound to Fn-F8 which does this:

if xrandr -q | grep -q  "VGA connected"; then
  xrandr --output LVDS --off --output VGA --mode 1680x1050
else
  xrandr --output VGA --off --output LVDS --mode 1024x768
fi

When I plug in my monitor, I hit Fn-F8 and voila, internal display turns
off and my desktop expands.  My next plan is to find out if the Intel
driver sends a signal when a monitor is connected so I don't even need
to press a button. :)

Ross
-- 
Ross Burton                                 mail: ross at burtonini.com
                                          jabber: ross at burtonini.com
                                     www: http://www.burtonini.com./
 PGP Fingerprint: 1A21 F5B0 D8D0 CFE3 81D4 E25A 2D09 E447 D0B4 33DF






More information about the xorg mailing list