Archive for November, 2008

Nvidia twinview and xrandr

AJ, I agree that GUI tools for multihead are lacking. I recently got my nvidia twinview working much easier with some fiddling.

Inspired by smcv’s setup, I also have my external monitor above my laptop screen, and it’s only slightly wider than the laptop screen so I run them at the same width. Since my laptop has an Nvidia Geforce Go 6200, I’ve generally used nvidia-settings to set twinview mode on and off. Since that’s a GUI app, I’ve had to click several times to turn twinview on and off. Turning twinview off automatically moves all the windows to my laptop display, and turning twinview back on moves the ones which were on the external display back to it, so I can undock and redock from my CRT albeit with a whole lot of mouse clicking.

Now on Intrepid (not sure if this could have been done on Hardy, but anyway) I found a command line way to toggle twinview on and off. I had used nvidia-settings to write to my xorg.conf, which had produced the following:

Section “Screen”
Identifier    “Screen0”
Device        “Videocard0”
Monitor        “Monitor0”
Defaultdepth    24
Option        “TwinView”    “1”
Option        “TwinViewXineramaInfoOrder”    “CRT-0”
Option        “metamodes”    “CRT: 1280x1024_85 +0+0, DFP: nvidia-auto-select +0+1024”

This at least allowed me to boot into twinview if the CRT was connected at the time.

I have added a metamode now, so that the line above reads:

Option        “metamodes”    “CRT: 1280x1024_85 +0+0, DFP: nvidia-auto-select +0+1024; CRT: null, DFP: nvidia-auto-select +0+0”

This lets me run “xrandr -s 0” to select the twinview (CRT at 1280×1024 85 Hz and DFP below it) and “xrandr -s 1” to turn off twinview.

I then discovered that my Fn+F7 combination automagically does the latter, so I only need to use xbindkeys to enable turning twinview on, so my .xbindkeysrc contains the following:

“exec xrandr -s 0”
Mod4 + F7

That binds it to the combination of Super_L (my Windows key) and F7, so I can undock with Fn+F7 and redock with Win+F7.

This is so much easier than using the nvidia-settings app! It’s going to save literally hours of my life to spend on other things… hope it helps someone else too.

OLPC Give 1 Get 1 2008

One Laptop Per Child resumed the Give 1 Get 1 program on Monday, via Amazon, available in the USA and 30 countries in Europe. USA orders can be shipped overnight, so buyers get the XOs much faster than last year. You pay $399, get an XO, and help fund OLPC deployments in developing countries – see where the laptops from last year’s G1G1 went.

The XO rose quickly to #1 on Amazon’s “Bestsellers in Computers and PC Hardware” and is still there.

There are videos on OLPC’s Youtube channel, introducing the XO laptop, OLPC’s mission and how the laptops are used for education.

The XO laptop runs Sugar, a platform and user interface designed for learning. You can run Sugar on various GNU/Linux distributions, including Ubuntu, Debian and Fedora.

You can also run a conventional GNU/Linux distribution on the XO, either by installing onto the built-in NAND flash storage, or from a USB drive or SD card – including Ubuntu, Debian, and Fedora. Amazon also lists Fedora 10 preinstalled on an SD card as a companion product to the XO (for preorder before F-10 is released). You do need a developer key, but then you can simply insert the SD card and boot Fedora without needing to install anything.

Microsoft also have a version of Windows XP for the XO, but this is not available for sale anywhere, as far as I can tell – so you’d need to be in one of two towns in Colombia to run it. “OLPC builds XOs with Linux. OLPC will continue to build XOs with Linux. OLPC has no plans to change this. None.

In addition to the comprehensive description on the Amazon listing, see OLPC News’s buyers guide for more information on buying the OLPC XO.

Sugar notifications and window manager plans

Subtitled, “it’s not what you know, it’s who you know to be working on it…”

gregdek wrote:

We should also be using the standard notification, alert mechanisms, and system tray specs that supports. (Seems like the only reason this hasn’t been done so far has been time.) Here’s what that means to me: when I use my IRC client in GNOME and someone says “hello gregdek,” I get a glowing icon on my system tray. (Yaaay! Somebody likes me!) But XoIRC, right now, is incapable. Which makes IRC much less useful for me (although I’ll probably get more done.) This is an opportunity to work directly with the folks at, and this is important; if Sugar is to be viable, we must learn to work with other projects and take advantage of the work they’ve already done. What will these notifications look like in Sugar, exactly, which currently doesn’t have a “system tray”, per se? Unclear, but thankfully Eben is really good at solving these kinds of problems.

Notification support landed recently in Sugar git master and XoIRC, courtesy of Tomeu, so if you run the crack-of-the-day or wait for a release you can use, that’s fixed.

It’s probably time to move beyond Matchbox

The Sugar development community is in agreement there.

Scott is looking at Awesome, which is a tiled window manager that also has a compatibility mode that allows for floating layers. There are other tiled window managers being considered; everyone’s got their favorite, of course, but it does look like Awesome is in the lead right now.

Sayamindu‘s been working on Metacity for some time. Who you think is in the lead depends on who you spend time with…

I’m looking forward to an event where we can all be represented and discuss all the options – hopefully the January XO Camp will be that event.

I hope the Sugar Camp will have been of value – certainly some communication is better than none. But we have so many people expressing their opinions at the top of their voices, not leading to actual implementation, that my response is “show me the code”.

Comparing files in Nautilus with diff-ext

I spend a lot of time at the command line so my fingers can run diff commands faster than reaching for the mouse, but I was interested to see Ben Martin’s article on on doing a diff without touching the command line. Since Ubuntu Intrepid already has a package, enabling this is as simple as:

sudo apt-get install diff-ext

killall -15 nautilus


(or you can install diff-ext using Synaptic, and log out and in again, and click on Applications > Programming > Diff-ext to configure it.)

The third step is to select a diff program to be launched by Nautilus – I use meld which supports 3-way diffs.

The article describes its usage:

Now you should be able to select two files in a directory in Nautilus, right-click to bring up the context menu, and notice a Compare entry toward the bottom of the menu. Selecting Compare will run your preferred diff utility on these files as shown in the adjacent screenshot.

If you have only a single file highlighted and bring up the context menu you will see “Compare later” in the context menu. Selecting that option places the path of the selected file onto a stack. The next time you select a single file you will see both “Compare later” and “Compare to ‘/…/first-file'” in the context menu.

f you select two files, you will be able to compare those two like before, but also have the option to run a three-way comparison with a file from the “Compare later” stack. Although I mention a compare stack, currently gdiff-ext only lets you compare with the very last thing you added to the “Compare later” stack.

If you select two directories and choose Compare, then both directories are passed to your nominated diff tool.

Ubuntu-ZA reapproved

As Nick Ali mentioned, the Ubuntu South Africa LoCoTeam went through the (now annual) review process with the LoCoCouncil and got reapproved.

As Nick says,

The yearly review gives LoCos a chance to take stock of how a LoCo is doing, what can be improved, and make plans for the future. The LoCo Council is here to make sure LoCos have the resources and help they need to support their areas.

I’m really energised by the increasing participation in ubuntu-za, and I’m looking forward to the coming year. Doing these reviews definitely helps put the focus on sustained activity.

Ubuntu South Africa release parties

Jonathan Carter already wrote about the Johannesburg release party. Here are his photos from that event.

I went to the Cape Town event which was held at Camps Bay High School’s tuXlab – an Ubuntu-powered school lab. We had about 30 people attending, which was awesome, considering that only a few signed up on the planning wiki page.

We distributed CDs, talked about hardware issues, and did several installs. I took some photos, and Reenen Laurie has posted his as well.

Thanks to:

  • Eleanor Lenders of Inkululeko for arranging the venue, posting signs, fetching pizza and going in search of balloons!
  • Rob Burger, the sysadmin of the CBHS tuXlab for spending the whole of Saturday upgrading machines to Intrepid so we could have some freshly installed machines to use – and for burning CDs.
  • Andy Rabagliati for organising the event and handling the complaints about bluetooth so well…
  • Everyone who attended! This community is about you!

It was great to have the event at a tuXlab, and it’s definitely worth holding our release parties at the same, or similar, tuXlabs in the future.

On that note, these school labs are largely supported by volunteers, so if you are available to help, please speak up on the ubuntu-za mailing list.