Saturday, June 16, 2007

Fifteen months of mediacenter and counting

We bought a dedicated VCR form-factor mediacenter 15 months ago.

It was definitely a lot more expensive than a normal desktop PC, but we decided to bite the bullet and see whether having a mediacenter was the complete paradigm shift that friends told us about. So far the experience has been like a two-headed beast. Or maybe I should say, our mediacenter PC has been behaving like a two-headed beast.

Our friends were right about it being a paradigm shift. As Americans have known since the introduction of the TIVO, once you get a PVR your whole TV watching experience changes. Since there's so much that changes, I'll make a list of it:

  • I never surf channels anymore.
    I do surf the electronic program guide (EPG) a lot in return though, searching for programs that I'd like to record. But somehow that feels like less of a waste of time. :-)
  • I record entire series, instead of just watching an episode.
    Can you imagine never missing an episode of CSI again? I can.
  • I hardly ever watch live TV anymore.
    When I feel like watching something, I just browse through the list of recordings. With on average about 30+ hours of recorded TV on the mediacenter, there's always something that I'd like to see. So the only things I watch live now are news and sports events.
  • Commercials? What are those?
    As soon as a commercial block starts, it's next-next-next-next.... then back a few seconds and I'm done. I can actually tell whether the show aired at prime time by the number of times I have to press next. And I seriously haven't watched more than 5% of the commercials I used to watch. Admitted, I might miss some very funny commercials. But then I'll see those on YouTube, instead of them interrupting my shows.
  • The quality of TV programs doesn't suck.
    I found out that there's actually a lot of good and fun programs on TV. Just not when I want to watch them. Or actually... they're now always there when I want to watch them.
  • It's the content that matters, not the channel.
    I really watch a lot of shows now on channels that I never used to watch. Then again, I watch shows now without having any idea of the channel I'm watching. Remember: I'm not surfing channels, I'm selecting a show by name from the list of recordings.
As you can probably tell, I like the mediacenter experience a lot. In fact, within months of buying it I was really certain that I would never go without having a mediacenter again. So what's up with the two-headed monster then, you're wondering? Well, that'll have to wait until tomorrow.

Wednesday, June 13, 2007

Leopards finder looks like a zoomable interface

Jef Raskin was a man with a vision. Many of the things he thought up, are still being implemented today two years after he died. That in itself doesn't make him a visionary. But the fact that these implementations are still considered revolutionary does.

Today I watched parts of Steve Jobs keynote at WWDC. What surprised me is how close the new finder interface is getting to the concept of the zooming user interface. The list of items in a can now be shown as a cover flow, which is really the same as the album cover flow in iTunes. And surprisingly (to me at least) it seems to work equally well when browsing documents and applications as it does when browsing album covers.


At first glance this looks functionally similar to the thumbnails mode of Windows explorer, with just a nicer rendering. But that superficial similarity goes away when you see that all the "covers" are live. This means that video files have a small HUD that allows you to play them. And while they're playing you can still scroll through the documents. And video is not the only thing, you can also flick through PDFs, browse through Excel pages, etc. All without ever leaving finder - without ever switching "modes".

Once you've found the document you like, a single press of the space bar zooms in on the document opening it in the Preview applet. And another key press closes it again and takes you back to finder. From preview it is just one more action to open the document it in its native application.

So everything is just a single key press away. And it all works seamlessly and -as I said at the start- reminded me of Raskin's zoomin interface.

Sunday, June 10, 2007

Incremental search using JavaScript

Aside from this blog, I am also the webmaster (and one of the contributors) on two photo blogs(one in English, the other in Dutch). I wrote the software for maintaining these photo blogs myself, because nothing at the time seemed to do exactly what I wanted. The upside of writing your own software is that it does exactly what I want. The downside is that if I want any new feature, I have to write it myself.

This weekend I added a simple incremental search feature to the administrative interface of the photo blogs. Nothing fancy, but just an easy way for the contributors to check for example when the last post on diaper cakes was or when we had the theme week on chocolate.

My solution is completely client-side using this JavaScript:

  • var TEXT_NODE = 3;
    var TIMER;
    var SKIP_ROW_COUNT = 2;
    var SEARCH_INPUT;

    function instrument(input, skipRows) {
    SEARCH_INPUT = input;

    if (skipRows) {
    SKIP_ROW_COUNT = skipRows;
    }

    // listen to changes to the input
    input.onkeyup = input.onchange = startTimer;
    }

    function startTimer() {
    // start (or re-start) the timer, only once it expires will we start the search
    if (TIMER) {
    clearTimeout(TIMER);
    }
    TIMER = setTimeout("search()", 500);
    }

    function search() {
    var term = SEARCH_INPUT.value.toLowerCase();
    var rows = document.getElementsByTagName("tr");
    // skip first few rows (optional author book, commands and header)
    var i;
    for (i = SKIP_ROW_COUNT; i < rows.length; i++) {
    var tr = rows[i];
    // hide row if it doesn't contain the search term
    tr.style.display = (term == "" || doesNodeContain(tr, term)) ? "" : "none";
    }
    }

    function doesNodeContain(node, term) {
    if (node.nodeType == TEXT_NODE && node.nodeValue.toLowerCase().indexOf(term) >= 0) return true;
    return true;
    }
    var child = node.firstChild;
    while (child) {
    if (doesNodeContain(child, term)) {
    return true;
    }
    child = child.nextSibling;
    }
    return false;
    }
As you can see it is pretty basic stuff. Set up some event handlers on the input, start a timer whenever the user enters some text and then do the search once the timeout expires. The search itself is done using some recursive DOM scanning. There's probably a cheaper way to do this and once I find that I'll update the script. But until then, this simple script will do just fine.

You hook this up in the HTML using:
  • <input onfocus="instrument(this, 2)" type="text">
The second argument to the instrument function is the number of rows from the top that the search should ignore. I tend to have some extra rows at the top that unfortunately don't all use th's, so this is the easiest way to exclude those from the search.

I know that putting inline JavaScript in the HTML is not very Web 2.0 and makes the site inaccessible. But since this is the administrative interface for the contributors and not the front end of the website, I think I can live with myself for not making it accessible.

Saturday, June 9, 2007

The twitter thing


I have so many online presences at social websites these days (Orkut, LinkedIn, Geni, Schoolbank.nl, Hyves) that I thought I'd add another: Twitter. It has been getting a lot of attention recently, since it is apparently a great way to monitor where well known people are during conferences.

I've been putting my activities on Twitter for a few weeks now. And so far I'm not really sure what the benefit is, either for me or for others. That might of course have something to do with the fact that I've set my profile to be only visible to friends, of whom I don't yet have any on Twitter.

But what I see from Twitter currently is that it is yet another way for you to tell people what you're doing. It's pretty much like a mini version of many personal blogs. So lots of messages are of the type "at the grocery", "on the bus to work", "stuck in traffic", "having fun with Dunya and Desi", etc.

The problem is that I don't believe in most of those personal blogs. Some people might find it interesting to read about one another's love life or their adventures at work, I only care about that type of story when it's exceptionally well written. Which -unfortunately- doesn't happen very often in the blogosphere.

I'm not saying that this site isn't personal or that it's well written, because I indeed often share my personal opinion in a rant-like fashion. But at least occasionally I try to write something that might be useful to some people in the community, or some personal opinion that could be interesting to someone else but my loved ones. I'm not sure if I'm succeeding at those things, but I think I have a better chance here that at Twitter.

"Grabbing cup of coffee"

Oops, sorry. That of course should have gone to Twitter.

Tuesday, June 5, 2007

My modern dentist

Yesterday early in the afternoon I got a text message on my mobile saying:

  • Dear sir/madam,
    You have an upcoming appointment at dental practice xxxx.
    Kind regards, the team at dental practice xxxx
    Appointment: 06/05/2007 at 8:00 AM


I just love it when even classic practices like dentists start to use modern technology. Well ok, text messages are not exactly modern anymore. But still... I can imagine this reminder might help some people making their appointments when they'd otherwise forget.

Oh and by the way: no holes. Thanks for asking.

Sunday, June 3, 2007

JavaFX: it's for building rich client applications


Last month, at JavaOne, Sun introduced JavaFX to the world. Those following more closely had already seen this language under it's previous name: F3 - Form Follows Function.

I see a lot of blogs that put JavaFX in the same category as Adobe's Flex and Microsoft's Silverlight - even Jeff Atwood does so at his much appreciated Coding Horror blog. I must admit that I haven't looked at Silverlight enough to know whether that comparison is valid, but to me JavaFX is certainly different to Flex.

Flex is a tool for building applications that run in the Flash player in your browser, so called Rich Internet Applications. And although it is apparently a great language and tool to use, it hasn't gained widespread adoption. The reason for that is probably very simple: there are less obtrusive ways to reach the same goal. Ajax is the buzzword for these applications now and they're often much more intuitive to their users. But enough has been said about that on other blogs.

JavaFX is a programming language that was created to declaratively build Swing applications. If you've never programmed Java GUI applications before: Swing is a client-side library/framework for building GUI applications, much like Microsoft's old MFC framework, their more recent WinForms or Borland's VCL.

Note that the resulting application of any of these frameworks doesn't run in your browser, it runs on your machine as a stand-alone application. And that to me is the main difference between Flex and JavaFX. The former is a tool for building rich internet applications, the latter is a tool for building fat client applications.

Friday, June 1, 2007

This scrum? Or that scrum? Or that scrum?

This week I took a training that now officially makes me a certified scrum master.


Or wait... let's make it sound even more official: I'm now a Certified ScrumMaster! There, that looks a lot better. And geeky, with a camel-case word in it. But actually all it takes to become a certified scrum master is completing a two day training. Now the training wasn't bad, mind you. But I do feel that a certification should require some kind of exam. Especially a certification that claims you're a master in something.

One of the things that I really noticed during our training is the apparent difference between the way our trainer implements scrum in companies and the way I understood it from Ken Schwaber's books (on agile software development and on agile project management) and video (Google TechTalk on scrum).

I have the feeling that in Ken's approach the role of the Product Owner is much less involved than what we've been taught this week. And that the actual ScrumMaster role is a lot less intensive then what Ken suggests in his TechTalk.

The Product Owner role we've learned during our training was pretty close to what Toyota seems to call the Chief Engineer. And that's a term we can probably all imagine what it means. In my recent history it has been called: technical lead, technical project lead, technical team lead, principal developer and I'm probably still missing a few. The only real difference I see is that the Chief Engineer is empowered, meaning that he/she has the backing of management and is allowed to do the things necessary to get a product or project completed. But of course having a Chief Engineer somewhat dilutes the role of the scrum master whose major responsibility is guarding that the team really follows the process. With such a simple process, that should never be a full time job. Which Ken seems to suggest it often is.

Of course in scrum it doesn't really matter if companies implement it slightly different. After all, this is an agile process. So what's a little flexibility between friends. And I actually believe that this flexibility is what makes scrum work for so many companies. Have a little faith in the ability of your people to somehow work towards the goals that you set out for them. It of course depends on the people, but then again... that's what I already said a few months ago.

What this training mostly showed me is that it really matters a lot who helps you implement scrum in your organization. If Ken Schwaber would have taught us, we probably would come away with a "completely" different interpretation of scrum. Not necessarily better or worse, but definitely different. Now that is something that you might want to consider before you book the first scrum training for your company.