Since I started using Linux as my main operating system, my whole world revolved around Gnome and GTK+. I sometimes toyed with cross-platform toolkits like wxWidgets, but they did not convince me. In the last year — particularly during the my employment at Siemens — I became some kind of a Qt enthusiast.
This has several reasons. First, Qt uses C++. You might say that the programming language is a matter of taste. If so, I suggest you try work with GObject for a day or learn the horrible mess of non-debuggable code that is Vala. Secondly, there is QML. Object-oriented programming language are not fit to layout User Interfaces. The Qt Markup Language is a nice way to quickly build User Interfaces. Finally, there is the community. GTK3 has not even been ported to Windows yet some weeks ago, while Qt has official and community port for almost every platform there is. New additions — like Qt3D — are released frequently.
When Canonical announced the Ubuntu Touch platform and I heard that it is based on Qt, I was pretty eager to try out their SDK. In this blogpost I want to present some insights I gained in the last days. Note, I will only talk about the QML part of the Ubuntu SDK. I have not touched any C++ code yet.
Besides the awesomeness that is vanilla QML, Ubuntu Touch adds some Components that want to create a unified look and feel. While the idea is really nice and there are many good concepts, it still lacks a lot of advanced features — like Tables or Rich Text Editors. Currently, the SDK may be sufficient to build a simple app for the phone, but there I could not imagine building a full-blown desktop app with it. Qt 5.1 introduced a wide range of native-looking widgets. If the engineers at Canonical are smart, they will embrace this toolkit for the desktop apps.
Now lets talk about the big aim that the Ubuntu folks target: convergence. During the last days I have worked on adding a desktop layout to two different apps. Unfortunately, I ran into two major problems. The fist is that the utilities for adaptive layouts cannot be nested. The documentation says they can but I at least on my machine it didn’t work. Secondly these adaptive Layouts cannot be used in combination with Tabs. A common approach for adaptive apps is to show multiple columns instead of tabs on a desktop, but this currently isn’t possible without a lot of nasty workarounds in you app. I suggests that the Ubuntu SDK add this functionality to the build-in Tabs element. This would ease the development of convergent Apps a lot.
This is just one example. Generally, the development kit should come with adaptive widgets. Otherwise we end up in a world where each app has a different look and feel. A key feature of free Desktop Environments has always been the unified look of Apps — we should not abandon this in my opinion.
Some of you might have seen the documentation on qt-project.org already. While it is not perfect, the one of the Ubuntu SDK is far from useful. The components have a lot of undocumented or wrongly documented behaviour, there are missing many examples and it strutured very badly. Luckly, a feature has been added that allows the community to edit the documentation. So I am sure this will improve in the future.
Also, I want to point out the awesome community of Ubuntu here. In my opinion this is one of the best features of the free operating system. I hope that Canonicals tries to make the development process — from design to deployment — as open as possible and keeps embracing the community as part of the development process. This could be the advantage of Ubuntu compared to systems like Android or iOS that are developed behind closed door.
Finally, I am really not a fan of the life-cycle model of Android. In my opinion Maemo was one of the best mobile operating systems so far, because it allowed real multitasking while still allowing a relativly long battery life. Sadly, Ubuntu seems to go the path of Android here and suspends Apps by default. Even worse, currently there is no way for a non-core app to run in the background. I hope that Ubuntu will make it easy for developers in the future to allow apps not to suspend, but I am afraid they will add a complex mechanism that forces the developers to write a separate daemon using some restrictive API. If that will be the case I might be moving to SailfishOS, that stayed very close to the concept of Maemo.
Let’s be fair. The Ubuntu SDK is new and still very young. However, if someone would currently ask me if he/she should use it for a new app, I would most likely say no.
Still I think that Ubuntu Touch has the potential for a bright future. The currently release is just a preview of what will come and the direction is definitely the right one. I hope that my suggestions from the view of an app developer are taken into account.