Skip to main content

Thread: nVidia Dual Monitor - Auto detection?


hello,

i've installed ubuntu on laptop. laptop has nvidia card i'm forced use nvidia configuration tools.

i'd happen automatically start using monitors if they're detected. or, make simple script enable monitors without needing restart x.

had similar want , found solution?

well may can :
http://blog.mfabrik.com/2009/07/14/a...ors-on-ubuntu/
following shell script helper script laptop users connect external monitor , laptop. since ubuntu not provide clever ways arrange desktop or detect connected displays, need run script terminal when change monitor configuration.

detect numbers of monitors have attached
activate second (external) monitor if there 2 monitors
use external monitory primary display, otherwise use internal display primary display
move taskbars primary display
based on disper tool willem van engen. (2009), it’s nvidia only. ati support possible.

code:
#!/bin/sh # # detect displays , move panels primary display # # copyright 2009 twinapex research # # author <mikko.ohtamaa@twinapex.com> #  # disper command detect , configure monitors disper --displays=auto -e  # parse output disper tool how many displays have attached # disper prints 2 lines per displer lines=`disper -l|wc -l`  display_count=$((lines / 2))  echo $display_count  echo "detected display count:" $display_count  # make sure move panels correct display based # on display count if [ $display_count = 1 ] ;    echo "moving panels internal lcd display"    gconftool-2 \         --set "/apps/panel/toplevels/bottom_panel_screen0/monitor" \         --type integer "0"    gconftool-2 \         --set "/apps/panel/toplevels/top_panel_screen0/monitor" \         --type integer "0" else    echo "moving panels external display"    gconftool-2 \         --set "/apps/panel/toplevels/bottom_panel_screen0/monitor" \         --type integer "1"    gconftool-2 \         --set "/apps/panel/toplevels/top_panel_screen0/monitor" \         --type integer "1" fi


Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [ubuntu] nVidia Dual Monitor - Auto detection?


Ubuntu

Comments

Popular posts from this blog

Joomla site hacked, cant see front and - Joomla! Forum - community, help and support

Christian Home School Programs - Joomla! Forum - community, help and support

Trouble with PF_OutFlag_I_USE_AUDIO and PF_CHECKOUT_LAYER_AUDIO