My blog has been moved to ariya.ofilabs.com.

Saturday, November 15, 2008

Flickify!

As Harry entered the room, he saw Ron hopelessly fighting with his magic tablet. Ron was desperately trying to look for something using the tablet. Harry pulled his wand and then "Flickify!"

The Qt Everywhere mantra means that Qt will be available in more and more platform, including of course mobile devices. For example, the recently announced Qt S60 means that 80 million devices can become the target market for Qt application developers.

In another front, touch screen seems to be the future direction. Nokia 5800 XpressMusic (better known as Tube) starts the new generation of S60 devices with touch screen. As introduced by Apple on iPhone, navigating a long list in a device with touch screen is best done using flickable list. The scrolling effect is also often known as kinetic scrolling.

Though up to now Qt does not offer an official mean to flick-enable your list, apparently it can be done without too much effort. Heck, you do not even need to modify your code. Flick Charm, my latest graphics example exactly demonstrates the idea. The trick is to use an event filter to hijack the mouse events and then to scroll the widget properly. This simple charm apparently works on any QAbstractScrollArea subclasses, including all the ItemViews and of course QGraphicsView as well as QWebView. Check out the following screencast for the proof:

(Screencast is also available for direct watch at blip.tv or YouTube).

3 comments:

Anonymous said...

Amazing.

But... Is there any word about Nokia PC Suite for Linux? THAT would be really a serious commitment from Nokia to FOSS.

I's a shame that the company who develops internally Qt is not able to make their cell phones fully work in Linux.

Anonymous said...

Thanks Ariya, for your interesting and inspiring blog entries. They are always a pleasure to read (in fact they are currently among my personal favourites). :-)
You always manage to find stuff to write about that on one hand is easy to understand for everyone while on the other hand you provide additional gems for people who are already familiar with the topics you write about.

Thanks again!

Tackat

Ariya Hidayat said...

@Anonymous: We're not working on PC Suite. Beside, you can't expect that once Nokia gets Trolltech, everything is ported to Qt in one night.

@Tackat: Glad that you like it! :-)