My blog has been moved to

Monday, June 29, 2009

ivory tower? I'd pick one of the anomalies of water

The Qt/S60 team continues to make some progresses. After Pyramid, Temple, and Garden, finally Tower came out of its cage. For a quick intro of what is inside Tower, check out the video. In particular, QtWebKit is included in this prerelease (yay!), thanks to the hard work of Simon, Norbert, Laszlo, Janne, Kristian, and other great hackers. My little contribution improves from only the basic engine behind the infamous Fluid Launcher (remember PictureFlow?) to a tech-demo QtWebKit-based web browser (created quickly in 1.5 days, cause I needed to rush to LinuxTag) dubbed Anomaly (Mobile). Once I am free again (now we're busy preparing for Akademy), I will put some more efforts to add more polishes to Anomaly Mobile. Imagine having visual bookmarks, flick support, Google suggest, optimized disk cache, double-tap-to-zoom, of course also smooth zooming in and out, snap scrolling, perhaps even night mode for your Nokia 5800, Nokia N97, and other Nokia touch devices, all implemented with Qt? /me just drools :-)

quattro cinque due

Again the freshly baked: Qt 4.5.2.

Details on the changes in this release is available in the changes-4.5.2 file. As for QtWebKit, some weeks ago I played the patch monkey role and did backport and test a number of critical fixes from WebKit trunk, among others stuff related to canvas, memory access and leaks, rendering painting and performance, JavaScript, plugin handling, clipboard, SVG, and many others. In addition Simon also tackled the backporting of various security fixes.

Overall, 4.5.2 seems to be a solid patch release. An upgrade from 4.5.x is highly recommended.

In a related note, Qt Creator 1.2 was also out. It brings a better fakevim plugin, regex search/replace, and numerous other improvements. Grab it while it's hot.

Wednesday, June 24, 2009

and the only chance we have of moving on

Like I wrote before, an exciting event is coming up soon: LinuxTag. I am still polishing the slides for my Advanced Graphics Programming with Qt. In few hours I will be flying to Berlin.

If you are around, drop Qt Software stand #108 in hall 7.2b a visit!

there was a time that we'd stay up all night, best friends, talking til the daylight

Just like last year, I took again the picture of the horizon from my apartment, in the early few seconds of Monday. Last Sunday was summer solstice (for the northern hemisphere), the day was 2 seconds longer (in Oslo) compared to Saturday.

Wednesday, June 10, 2009

Please, I'll be strong, I'm finding it hard to resist

Things are always exciting.

Within three weeks, I will be in Gran Canaria for the Desktop Summit, specifically for Akademy 2009. The summit is also sponsored by Nokia, via Qt Software and Maemo.

My talk, Special F/X with Graphics View will be on Tuesday afternoon. There will be some graphics demo which will be shown for time there, so show up if you are interested in. Check also an array of other fabulous presentations.

I can't wait to finally meet many fellow KDE hackers face to face. And yes, this will be my first Akademy. Afterall, there is always a first time for everything...

Wait, I'm wrong, should have done better than this

Things are always exciting.

Within two weeks, I will be in Berlin for LinuxTag, "Where .COM meets .ORG", one of the important FOSS shows in Europe. We (as in Qt Software) will have a stand, just check stand #108 in hall 7.2b. Drop us a visit!

And if you stay until Saturday, feel free to show up at my short talk (as in 30 minutes) Advanced Graphics Programming with Qt. Nothing fancy there, but if you want to kick-start doing cool stuff with Qt, try not to miss it. Of course, there is a whole stack of attractive presentations at the KDE track (and other tracks, too) on Saturday.

I can't wait to see Berlin again. And of course, since our very own Mr. Portale lives in Berlin, we would not miss the chance to exchange our cuisine experiences, just like the last time. This time however, I will make sure it's not only about pizza!

In all cases, if you are around and want to have a chat, drop me an email (ariya.hidayat AT gmail DOT com).

Sunday, June 07, 2009

QS_BIND macro magic

At my request, Kent kindly changed the initialization of the Qt bindings (from the binding generator project) so that the class wrappers are populated in a single function for every module. This also means, you don't have to compile everything as plugins and then deploy them with your scripted application. You can just include the appropriate .pri file (e.g. generated_cpp/com_trolltech_qt_gui/com_trolltech_qt_gui.pri for Qt Gui bindings) and then build together with your project (or compiled to non-shipped, project-wide static library, if you wish).

Another gem: for each module you will have a source file, e.g. qt_gui_init.cpp for Qt Gui, that is responsible to create the wrapper classes. This means, the two macro tricks would work:

// example: QS_BIND_MODULE(new QScriptEngine, core)
#define QS_BIND_MODULE(engine, modulename) \
extern void qtscript_initialize_com_trolltech_qt_##modulename##_bindings(QScriptValue &extensionObject); \
  { QScriptValue extensionObject = (engine)->globalObject(); \
  qtscript_initialize_com_trolltech_qt_##modulename##_bindings(extensionObject); }

// example: QS_BIND_CLASS(new QScriptEngine, QPushButton)
#define QS_BIND_CLASS(engine, classname) \
extern QScriptValue qtscript_create_##classname##_class(QScriptEngine*); \
  (engine)->globalObject().setProperty(#classname, \
      qtscript_create_##classname##_class((engine)), \

(or download/git-clone it from

While the first is arguable already useful, the second one is interesting because it allows you to limit the bindings to certain classes only. For example, if you want to extend the look-and-feel of some GUI elements in your cool applications, just offer the user the bindings for QPainter, QBrush, QPen, and other related classes. Neat, isn't it?

On a related note, you should also perform some kind of dance that our QtScript hero has also created the bindings for the Animation and State Machine frameworks slated for Qt 4.6.

Isn't the Qt Script world wonderful?

how to get Spotify running on OpenSUSE

Since there is no native Linux client yet, we have to use Spotify via Wine. On my OpenSUSE 11.1 (32-bit) machine, installing Wine (I got version 1.1.9) is as easy as:

sudo zypper install wine

Now, since I am using KDE 4 with PulseAudio, the step to configure Wine must be modified a bit (after Paul Betts' hint):

padsp winecfg

Then choose OSS Driver (not ALSA Driver) in the Audio tab. Follow the other steps, i.e. closing it, run winecfg again, choose the right settings for DirectSound.

After that, download Spotify for Windows. Open Dolphin, find the download file, click on it. Wine will be automatically launched and the installation will start. After a while, you can enjoy Spotify (even with systray integration).



Martabak - a popular snack in some places, including my home country, Indonesia - is actually easy to prepare. Basically it is just crepe (but potentially with many eggs for the batter), stuffed with vegetables and (if you wish) minced meat, deep fried for 3 minutes. Typically it is served with a dipping sauce that is a combination of shallots, chili pepper, palm sugar, soy bean, vinegar, and often cucumber slices.

Wednesday, June 03, 2009

it got cold and then dark so suddenly and rained

Cutting a long story short, check out my latest example of a less-than-150-lines code (pick your battle: C++ version or Python version) to show the weather status and day forecasts for almost all places in this blue planet, powered by Google, based on QtWebKit. As always, let's start with the screenshot (aka the proof):

I doubt there is a need for this to be a plasmoid, as it will just clutter Plasma with yet another weather applet. But hey, if people like it, I (or someone else, preferably) can make it.

Monday, June 01, 2009

all the blessings in May

I was sadly too lazy to update this blog. My only excuse is because there were many good things happened last month. The context here is of course Qt Software and Qt in general.

First thing first: we just open our source code repository. It's git, and it is hosted at You can track every single commit from the engineers inside Qt Software, fantastic to see how certain bug is fixed and to localize regression breakage. For more goodies in the repository, check out what Benjamin, an ex-troll, has written.

But the beauty does not stop here. Now we are also accepting external contributions to Qt. It means that you can help us fixing bugs and implementing features. Read and digest the Contribution Guidelines to find out how. Since the repository was opened, every cool kid and his dogs have cloned it like crazy and we even have merged some of the contributions.

The domino effect. Since now we have the infrastructure on Gitorious, the project repository for Qt/S60 was going public, too. The repository is at I can imagine that this will be valuable for all the S60 fans out there, not only for Nokia platforms, but for other S60 devices e.g. for Samsung. If you see their video, you realize now what my PictureFlow Everywhere vision all about :-)

It does not stop there. Some research projects are moving towards more openness. Check for example the really cool multi-touch support being worked on by Brad. Also, the brand-new Declarative User Interface project, a concept of making good looking, fluid user interface via a non-imperative description of the interface. Both projects can be tracked from the repositories at and, respectively.

Two bleeding-edges frameworks slated for Qt 4.6, Animation and State Machine, were finally merged into qt/master. If you love to compile Qt on a daily basis, you can really start to use both frameworks for your upcoming cool applications.

Last but not least, do not miss the Qt Mobility project announcement. The project aims to offer good API to access mobile functionalities, both for Nokia and non-Nokia platforms. The first set of API for Service Framework was going public already. Check its repository at

Along with our successful visit to Pycon Tre Italia, can you see now how last month I got adrenalin kicks on a daily basis?

I of course do not abandon Graphics Dojo corner. Expect few cool things coming out in the next few weeks. Stay tuned!

traffic jams? no sweat!

Ronald and I were doing podcast whose topic is about programming and other related things. We tried not to dive too much into the technical details, though. Check out the first two episodes with me at

We will plan to have this on a regular basis. Who knows this becomes yet-another-Jeff-and-Joel clone? :-) Feedbacks are warmly welcomed.

Note: skip this if you don't understand Indonesian. There are tons of similar podcasts in English, so we pick our own lovely language!

Again, kudos to Ronald!