Archive for May, 2008

Help protect the Web against undue proprietary influence

Friday, May 30th, 2008

Even if Firefox 3 will be available within your operating system’s software repositories, do the project a favour and pledge to make an explicit download as part of the Spread Firefox “Download Day“.

50 quotations for humanists and rationalists

Sunday, May 25th, 2008

A great collection of quotations for people who like their reality just as it is. If, like me, you weren’t “imprinted” while young, or like others, you were imprinted, but managed to break free, you’ll enjoy these.

Top 50 quotes for non-theists

XP SP3 and Ubuntu 8.04: performance tests

Tuesday, May 20th, 2008

(Liferea is proving to be a major distraction and productivity brake today!) There’s a fascinating comparison of XP SP3 and Hardy Heron on Mohammed Saleh’s blog (nice, polished presentation of the results too). He ran his tests on an AMD Athlon64 X2 5600+ based system. The results and findings, while interesting, are perhaps not entirely surprising. Executive summary: XP for graphics and multimedia, Ubuntu for multi-tasking and disk intensive tasks.

Don’t reinstall the wheel?

Tuesday, May 20th, 2008

There’s an interesting discussion on the blog of Debian and Ubuntu user, David Welton, about the relative merits of clean installing versus using dist-upgrade. The opinion of the poster and the commenters seems to be divided between whether or not upgrading, as opposed to doing a fresh install, is an advisable thing. I think Daniel Ruoso’s point that many dist-upgrade problems are likeley to be caused by non-supported packages, is a noteworthy one.

Having come to Ubuntu after having been a Windows user continually since v.3.1, my hunch was that I should favour clean installs over performing upgrades of existing systems (let’s face it, each Windows version generally required several clean installs during its own lifetime, without having to wait for the next official release). My first installation of Ubuntu was the 32-bit version of 6.06, Dapper Drake. I played with this on and off until Feisty was released, and despite my reservations about performing version upgrades as opposed to clean installations, I read the Ubuntu docs and decided to use dist-upgrade to update the system (via Edgy, of course, as dist-upgrade will not allow you to jump versions).

With it being on a spare machine, I was a bit cavalier and carried on using it while the upgrade took place. I was absolutely gob-smacked to see the application I was working with upgrade itself while I was using it. It temporarily used a different font set, then refreshed the window, and then politely advised me that it should be restarted (the app, not the OS) at a time convenient to me. Coming from Windows, this was radical stuff. It was like performing a 12,000 mile service, including tyre changes, while you’re doing 70mph on the motorway.

Despite having used the system while it was being upgraded, the process went well and Feisty ran sweetly (on an old P4 with 1GB RAM and 40GB HD). In fact, it went so well, and I liked Feisty so much that the experience convinced me to take the fateful step of shifting my life and work over to Linux on a permanent basis.

Sadly though, my next attempt at using dist-upgrade did not go so smoothly. When the time came to upgrade from Feisty to Gutsy (something I did mainly to get access to better wi-fi drivers) I again turned to dist-upgrade. Despite having all the latest updates installed on Feisty, and despite being sensible by leaving the machine alone while it upgraded, the resulting systems (one laptop and one desktop) were riddled with glitches and bugs, and sent me running for the ISO image. Gutsy was rather glitchy even after clean installs in my experience, although a couple of months into the life of the release the updates had taken care of the most irksome bugs.

After the Feisty to Gutsy experience, I ignored the dist-upgrade facility when moving to Hardy and performed clean installations instead. It would be nice to be able to rely on dist-upgrade and it would be great not to have to re-configure your machine manually after each version install, but the facility just seems too unreliable. On the upside, I can honestly say that I can build an Ubuntu workstation from scratch, import my data, and install 90% plus of the apps, utilities and other stuff I need, in around three to four hours or so. Windows upgrades used to be a major PITA. It always seemed to take the better part of a day to get a useable system (downloading huge service packs and updates, feeding application suite CDs to the drive and typing in CD-key after CD-key, hunting around for all those 3rd party utilities you’d installed, etc.) and the better part of a week a week to cross the ‘t’s and dot the ‘i’s. Ubuntu takes a few hours for the fundamental system, applications and major utilities (thanks to the wonderful synaptic), and I get most of the fine tuning done within a day, with one or two things I overlook being taken care of on day 2. Of course, the odd thing crops up over the following week or two, but Synaptic generally takes care of it within a few moments. It’s wonderful stuff! But I digress…

It’s the little things…

Thursday, May 15th, 2008

Just downloaded a .iso disk image using Ubuntu 8.04. The download completes and Firefox 3.0 (beta 5) pops-up its “Download complete” message in the bottom right corner of my screen. I click on that and up pops the “Downloads” list, with my ISO image at the top. I click on the entry expecting a Nautilus window to fire up on the folder in which the file downloaded, but no, it’s more convenient than that. I don’t know whether I have Firefox, GNOME, or Ubuntu to thank, but instead of simply being taken to the download folder, it automatically fires up GNOME’s “Write to Disk” dialog box. Why shouldn’t it I guess? What else was I planning to do with a .iso file?

Trivial perhaps, but sweet.

Formatting code snippets in OpenOffice Writer documents

Friday, May 9th, 2008

If you ever have the need to provide code samples within the constraints of a typical, word-processed, A4 document template, the following tip might help.

As anyone who uses OpenOffice’s formatting styles will know, Writer has a basic “Teletype” style which can be used as-is, or customized to suit for formatting code snippets. However, one problem that often occurs is that when inserting code snippets into such documents, even with the Teletype style’s monospace font set to a relatively small point size, you still often run out of horizontal space within the confines of the A4 template — and statements end up containing arbitrary breaks and wrap onto the subsequent line, often leaving the code sample hard to read.

One method for alleviating the effects of this is to use a book publisher-style “line continuatation” character, such as  or, if you’ve forgotten your reading glasses:

Using this character you can avoid awkward to read snippets such as this:

function listusers()
{
    $this->set('userlist', $this->User->findAll(null, array('id',
    'username', 'first_name', 'last_name'), 'id DESC'));
}

or monstrosities like this:

function listusers()
{
    $this->set(
        'userlist',
        $this->User->findAll(
            null,
            array(
                'id',
                'username',
                'first_name',
                'last_name'
            ),
            'id DESC'
        )
    );
}

using instead the rather more elegant (from a word processing point of view, at least):

function listusers()
{
	$this->set('userlist', $this->User->findAll(null,
	 array('id', 'username', 'first_name',
	 'last_name'), 'id DESC'));
}

Obviously, a solution is only useful if it’s easy to apply and so creating a macro to simplify the insertion of the  character is helpful. If you have never created a macro using OpenOffice, worry not, it really couldn’t be simpler. Just go Tools > Macros > Record Macros, then select the line continuation character (Insert > Special Character, select the OpenSymbol character set, locate the line continuation arrow (Unicode code point: U+E48C) and insert, then simply click the “Stop Recording” macro button which will be floating around somewhere over your document window. You will then be asked to give the macro a name and save it.

So far so good, this has helped, but needing to manually select the macro each time you need it will still be an embuggerance. The solution is obvious enough, just assign a keyboard shortcut to the macro. To do this, go Tools > Customise > Keyboard, select the macro’s container within the Category pane, select the macro itself within the Function pane, select the keyboard shortcut you wish to use from the Shortcut keys pane, and that shortcut should automatically appear within the Keys pane. Click OK and Bob’s yer uncle. One DTP-style line continuation character ready to go. Simple, innit?

Footnotes:

  • “Line continuation character” is just the name I use. I’ve no idea what the official name for  is!
  • The notes above are relevant forOpenOffice v.2.4 at least.

Lens Flare

Wednesday, May 7th, 2008

Yet again DPReview shows everyone else how to do technical reviews. Just check out the interactive Flash applet for this Nikon lens review. Rotate the zoom and aperture dials at the bottom to redraw the graphs, and use the drop down menus to select different optical tests and comparisons with other equipment. Amazing stuff.

If you are going to use Flash, this is how to do it!

(It also works fine in Firefox 3 Beta 5 on Ubuntu 8.04 using the Adobe proprietary player.)