<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>mFabrik - mobile sites, apps, HTML5 and CMS software development &#187; external display</title>
	<atom:link href="http://blog.mfabrik.com/tag/external-display/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.mfabrik.com</link>
	<description>Freedom delivered.</description>
	<lastBuildDate>Wed, 03 Aug 2011 09:47:41 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Autoconfiguring dual monitors on Ubuntu</title>
		<link>http://blog.mfabrik.com/2009/07/14/autoconfiguring-dual-monitors-on-ubuntu/</link>
		<comments>http://blog.mfabrik.com/2009/07/14/autoconfiguring-dual-monitors-on-ubuntu/#comments</comments>
		<pubDate>Tue, 14 Jul 2009 09:51:32 +0000</pubDate>
		<dc:creator>Mikko Ohtamaa</dc:creator>
				<category><![CDATA[technology]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[autodetect]]></category>
		<category><![CDATA[configuration]]></category>
		<category><![CDATA[disper]]></category>
		<category><![CDATA[display]]></category>
		<category><![CDATA[dual monitor]]></category>
		<category><![CDATA[external display]]></category>
		<category><![CDATA[hotplug]]></category>
		<category><![CDATA[internal display]]></category>
		<category><![CDATA[taskbar]]></category>

		<guid isPermaLink="false">http://blog.twinapex.fi/?p=201</guid>
		<description><![CDATA[The following shell script is a helper script for laptop users who connect an external monitor now and then to their laptop. Since Ubuntu does not provide clever ways to arrange desktop or detect connected displays, you need to run the script from terminal when you change your monitor configuration. detect the numbers of monitors [...]]]></description>
			<content:encoded><![CDATA[<p>The following shell script is a helper script for laptop users who connect an external monitor now and then to their laptop. Since Ubuntu does not provide clever ways to arrange desktop or detect connected displays, you need to run the script from terminal when you change your monitor configuration.</p>
<ul>
<li>detect the numbers of monitors you have attached</li>
<li>Activate the second (external) monitor if there are two monitors</li>
<li>Use the external monitory as the primary display, otherwise use internal display as a primary display</li>
<li>Move your taskbars to the primary display</li>
</ul>
<p>It is based on <a href="http://willem.engen.nl/projects/disper/">disper</a> tool by Willem van Engen. For now (2009), it&#8217;s nVidia only. ATI support could be possible.</p>
<pre>#!/bin/sh
#
# Detect displays and move panels to the primary display
#
# Copyright 2009 Twinapex Research
#
# Author &lt;mikko.ohtamaa@twinapex.com&gt;
#

# disper command will detect and configure monitors
disper --displays=auto -e

# parse output from disper tool how many displays we 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 that we move panels to the correct display based
# on the display count
if [ $display_count = 1 ] ; then
   echo "Moving panels to the 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 to the 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</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.mfabrik.com/2009/07/14/autoconfiguring-dual-monitors-on-ubuntu/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

