Twitbar 2.0

With the youth of today’s attention spans halving every 18 months, it is good to know that Deskbar’s triple-extreme ease of extensibility (that’s XXXEoE™) meant that, for Phil Wilson, "it took longer to write [his] blog post than [a Post-to-Twitter Deskbar extension]"

Python rocks. \m/

Calling All Szemerédi Fans

One of the reason’s why Terry Tao‘s wig is so big in the math world is the Green-Tao theorem, which states that the sequence of prime numbers contains arbitrarily long arithmetic progressions.
If that means anything to you, you might be interested in his forthcoming article in the Bulletin of the American Mathematical Society, entitled “What is Good Mathematics” (PDF). He’s also in a
New York Times article
from last week, and his little brothers gets a mention. Yay me – I’m in the NYT. 🙂

Election, Shmelection

Having nothing new to say about technology at the moment, here is a brief interlude…

A state election is coming up, which for all practical purposes means that I am supposed to bless one of the two major political parties. The trouble is that I find both prospects are utterly uninspiring (yes, even more uninspiring than the usual parade of political hacks), and the polls show that I am not alone. The incumbent is corrupt and incompetent, but is predicted to lurch home in front of a totally forgettable and farcical opposition.

Actually, there are politicians that I admire (!), but they don’t happen to be in my electorate. In fact, I’ve always lived in “safe” (rather than marginal) seats, so I feel like my vote doesn’t matter anyway, and I’m being taken for granted. Marginal seats get the pork barrels, boundaries are gerrymandered, and geographically dispersed interests are under-represented. So I got to thinking… what if we had a democracy without electorates? Or, to be precise, a single electorate – the whole country.

Here’s how it would work. I would go to the ballot box, and put one X next to the name of who I wanted to represent me in the nation’s Parliament, and that’s that. Those who mustered a minimum number of votes (say, 0.01% of the voting population) would become Members of Parliament. But not all MPs would be equal, their vote in Parliament would be weighted by how many votes they garnered at the election. A majority would be still needed to pass laws. Not a majority of MPs (or a majority of seats), but a weighted majority, representing the population. Corporations work somewhat like this. Some shareholders have a greater share than others, and thus have greater say in how the corporation is run. I wonder if there’s any lessons from the corporate experience (or elsewhere) as to how this alternative universe would pan out.

Ah, but what if a tremendously charismatic evil genius takes 55% of the vote at election time, then the system becomes a one-person dictatorship, no? One countermeasure would be to have rolling elections, so that each MP was elected for a four year term, but we had elections every two years, so that only half of the Parliamentary weight would be up for grabs at each election – each citizen is represented twice. No one MP could represent a majority weight solely by himself (or herself).

Would this work? Am I a naïve engineer trying to imagine an mathematical fix for a messy human problem? Would this reduce elections to a popularity contest, or beauty over brains? Would this lead to only extremist politicians backed by vocal, passionate interest groups? Would this lead to weak and unstable (and ineffective?) government, if there was no clear majority party (as you get in the two-party system)? Would it lead to opportunist, independent politicians selling off their critical (weighted) vote if a proposal is hovering around the 50% mark? Would it destroy the concept of a political party entirely (why vote for a follower when you could vote for the leader)? Would that ruin the Westminster notion of the executive (Ministers) being drawn from, practically speaking, MPs of the majority party? Is it even logistically possible?

All I really want is a reason to vote for (rather than against) somebody next week. (Sigh)…

Been There, Done That, Got Loads of Free T-Shirts was pretty cool – there were OLPCs to play with, faces put with names (and nicks), an awesome Open Day full of shiny demos, and a luncheon pilgrimage to the Red Hat Noodle Bar.

I gave a talk about superswitcher at the GNOME miniconf. It wasn’t the sexiest topic, and I was a little nervous (I haven’t really done a lot of presenting before), but I don’t think it sucked. It was a better experience than one I had a few years ago, when it was really cold, and my hands were stiff and frozen just before I had to get up on stage, so I thought to run some warm water over my hands, only to turn the tap on far too fast, and the splash gave me a nice big wet patch right over my groin :-). Unfortunately, the video appears to be lost. There are OGGs of Davyd’s introduction and t-shirt handing out (trust me, it’s not that interesting) beforehand, and the Avahi talk afterwards, but not the one of me. So much for my 15 minutes of fame, but really, there wasn’t a lot to it (if you want to find out what superswitcher does, just download and try it). At least Davyd took a photo.

Anyway, I talked a little bit about the wnck library, and if you want to start playing around with that, then I have some wnck python example programs that are pretty short and simple. Another example I gave is how easy a (Python) D-Bus program can be. Here’s a 4-liner that tickles superswitcher (yeah, you will need a version after 0.4):

#!/usr/bin/env python
import dbus

Finally, Enso was just released, albeit Windows-only and trial-ware (yeah, they gotta eat). From my biased viewpoint, it looks sort of Deskbarish (they mention Python plug-ins!), sort of Superswitcherish (they switch windows by find-as-you-type title search, and they trigger on Caps Lock!), sort of Quicksilverish (Santa is still yet to gift me a BlingBook Pro), sort of Google Desktop Ctrl-Ctrl-ish, surely sort of other things I haven’t seen yet, and heavily influenced by the late Jef Raskin’s The Humane Interface (certainly interesting reading for UI designer wannabes, especially those who want to get away from the “nothing’s changed since the 90s, overlapping windows, files and folders, icons on a desktop” rut). The Flash demos are all very flash :-), although I don’t really see the life-changing-ness of being able to calculate anywhere (maybe I just wasn’t cut out to be an accountant). The “learn as” feature seems nifty at first glance (although if it’s just files or URLs, you could simply just bookmark them in Nautilus or Epiphany and pick them up in the Deskbar).

Update (2007-01-29): Terry didn’t win, by the way, but he still made the news. Apparently he “is a true-blue Australian with a fondness for meat pies, football, cricket, and our easygoing, honest, and relaxed culture”, despite me being unable to remember the last time he ate a meat pie, watched the footy, or the cricket. He is, however, easygoing, honest and relaxed.


Just a short note to say I’ll be at linux.con in Sydney next week. Drop me a line if you wanna meet.

I don’t have much else to write about, so instead look at Drew Kerr’s Gimmie / panel menu musings.


It’s nowhere near “release early, release often”, but superswitcher 0.4 is finally out. The project is now hosted on Google Code, which means a subversion repository, an issue (bug) tracker, an one-stop download shop and probably more to come.

You can now also download a i386.deb binary package directly, rather than just the source tarball. This is the first time that I’ve rolled a .deb, so feedback is most welcome.

One new feature I’d like to highlight is the ability to use the Caps Lock key to switch windows (WITHOUT HAVING TO TYPE LIKE THIS) instead of the Super key, which is most useful if, for example, your Thinkpad has no Super key, or something like compiz wants the Super key. This promotes the larger-than-average Caps Lock key from my most hated wart on the keyboard to one of the most cherished keys. Hooray for the poor neglected Caps Lock.

Changes since 0.3:

  • Can now drag-and-drop workspaces.
  • New -c, -v and -? command line options.
    -c or –trigger-on-caps-lock makes Caps Lock also switch windows.
    -v or –version shows the version number and exits.
    -? or –help shows a brief instruction guide.
  • Super-Shift-Control-Insert now moves *all* windows from this workspace to a new workspace, so as to be consistent with Shift = Move, Control = Move-All-Windows-in-this-Workspace and Insert = New-Workspace.
  • Now does window-frame geometry calculations “the right way”, via a window’s _NET_FRAME_EXTENTS X property, rather than presuming that its frame is the same as its parent X window.
  • Now warps the pointer to the activated window’s center, under focus-follows-mouse in metacity. This fixes the behavior where window activation would be ‘stolen’ by whatever window was under where the pointer was at the time.
  • Now works when NumLock is on. Fixes bug #1.

Get it fresh from the superswitcher project page. Its page is still updated but is no longer definitive.

Thanks to Drew Kerr for his help.

OK, back to Kerry O’Keeffe calling the cricket…

Because Australia Loves an Underdog

Bugger the Melbourne Cup, this is where the betting action is:

Thanks to Alex for the tip.

La La La I Can’t Search You (Unless You’re With the Band)

As a GNOMEy person, I read Planet GNOME (also known as p.g.o) – a collection of GNOMEy people’s blogs – a lot. Using Google’s Custom Search Engine (roll-your-own-search-engine thingy), I took Planet GNOME’s OPML file and made a search engine over just those websites that are p.g.o’s blogs. As an example, compare Google’s regular results page for cairo (which is dominated by Cairo the Egyptian city), with the Bloggers of Planet GNOME results page for cairo (which is Cairo the graphics library, and its GNOME-related adventures).

Enjoy (but don’t pronounce) BoPG:CSE – the Bloggers of Planet GNOME custom search engine. Sure, it’s not perfect, but it will only get better.

Update (2006-11-09): It looks like jdub has embedded the searchbox at

How to Speak Australian on a Six String Guitar

  1. Take an unofficial anthem.
  2. Chuck out the boring chords and revise history with some 7ths, since they have more Star Power. Shorten it for fashionable attention spans.
  3. Plug a guitar into a cheap ‘n’ nasty laptop sound card, and play like your mother (country) just died. If you are an ordinary guitarist and need 30 takes, then play like your entire extended family just died.

Listen (mp3 or ogg, about 1MB large and exactly 1 minute long), or read the score (PDF for printing, or PNG image for imagining, or Lilypond source for the hard-core). Everything’s CC-SA licensed.

On another note (haha), it’s been a year-ish since my first post (I’d link to it, but it’s crap). All up, 37 posts and 6,600 words, with a three month hiatus in the middle. In comparison, my buddy Wes has just squeezed out his 100th blog post since starting 10 months ago. I think the man has found his calling. There are some choice quotes there, bro.

Update (2006-10-23): For search engines’ sake, I really should mention the words Waltzing Matilda, tablature (not just chords) and arranged for classical guitar.

Creating Passionate Grandmas

My grandma doesn’t particularly like computers (she’s always afraid that she’ll accidentally break something, having previously been caught in the crossfire of Media Player, iTunes, RealPlayer and WinAmp all squabbling about who “owns” .mp3 files) but she loves the internet and e-mail. Again and again, people have mused that all they needed from their computer was a web browser (and web-mail like GMail, Hotmail, Yahoo, or whatever) and an internet connection. Now, what if you designed a user interface for those people, rather than copying the traditional “desktop” metaphor?

This is what I’d do: there wouldn’t be a Start Menu, but only two buttons – one for the web browser, and one to log out. And the browser itself would be simpler. A common Firefox setup has as the home page. This gives me three text boxes – Firefox has the Location bar and the Search bar, and Google gives me a third one. If I installed the Yahoo toolbar, I’d have yet another. This is crazy! There should just be one place to type stuff in. If it looks like you entered a URL, it would take you there. If it looked like you were entering search terms, it would search. Enter an e-mail address – it will compose an e-mail. Users of GNOME’s Deskbar would know what I’m talking about.

This magic text box would take pride of place – it would be big and central. It’s the most important part of the UI, and it’s also all you need. Under that, for convenience, I’d sprinkle half a dozen links, with nice big icons. E-mail, obviously, and one or two nifty web apps – writely, tadalist, whatever webbly calendar and blog-reader are flavors-of-the-month. And that’s it. All very simple, clean, and (hopefully) unbreakable. My Grandma might never have to see “the file system” ever again.

How would I implement this? Well, we already have a light-weight “desktop” in XFCE, and a light-weight Gecko-backed browser in GNOME’s Epiphany. I don’t need big apps like, Evolution, or even a file manager like Nautilus. What’s missing? Photos and music, I guess. Maybe I’d concede some specialist apps like F-Spot and Rhythmbox (or Songbird??), if I was going to do this properly. But as far as making a mere prototype, it was no effort at all. Oh, I need a sexy project name, so let’s take two of the biggest brands in the Linux community and mash them together. Voila: Foxybuntu. Enjoy the 3.5MB screencast (mirror). Yeah, the image quality is lousy, since it’s a 256-color GIF and hence dithery, but you should be able to get the idea.