Been wondering about Nokia’s strategy for conquering the rapidly expanding app space? Great! So were we, which is why we joined up with a recent dev event carried out by the Finnish company for an update on how and where things are going. It’s a familiar narrative by this point: Qt is all set to become the way that Nokia-friendly apps are made — whether it be for Symbian smartphones or MeeGo-powered mobile computers, coffee machines or infotainment consoles
Well, who wouldn’t, after all they played 150 millions for it.
Whatever Nokia paid for TT, it was cheap; probably the best investment Nokia ever made.
The acquisition price is peanuts compared to what Nokia is continuously investing in Qt, and what Qt is actually worth to Nokia. It’s the basis of everything Nokia is doing these days, though it takes time for the effects to trickle to end users.
Qt itself is awesome, but I hate using it purely because I hate C++. There is no reason that a systems language has to be so messed up as C++ is. Anyone else feel like its time for a new language that actually gets things right while retaining all the power and speed of C++? (It’s certainly possible.)
On a side note, the word “infotainment” needs to die. And wait a second, it actually passes Chrome’s spell check. Something is very wrong here.
C++ suffers from what made it so successful…its ability used as imperative, single rooted OO hierarchical or generic programming. The flexibility has allowed it to remain relevant through all these years but has made it difficult to work with properly (the difficulty is more about creating your own dialect based on what task you to want solve).
Unfortunately one of QT’s problems is that it absolutely does select its own dialect for you and it carries a lot of baggage along with it. But there is no question here: of the frameworks out there QT is most cross platform and most complete.
It’s sad for nokia that they didn’t make this move before the first iphones came out. At this point they are trying to play catchup just because of timing.
That’s considered a perk.
Of course Qt doesn’t magically remove the rest of C++, but it provides an optimized, well-understood path that rewards those willing to stay on it.
After qt went lgpl I was sort of hoping it would move away from being a jdk copy over to something lighter weight better integratred with libstdc++. In effect ripping out all the reimplemented functionality (custom collections, etc) and becoming a more modern toolkit.
As I’ve mentioned before where I work used to hold the first 2 licenses of QT ever sold. Our newest development project has a very strong separation between algorithm and interface. At that time we just dumped Qt, partly because the algorithms all use libstdc++ and partly because qt4 really killed network display performance, especially for CAD type operations.
There’s the choice of using UTF16 as QString internal (UTF8 is more obvious), the moc compiler….a lot of stuff legacy from the 90’s.
Edited 2010-08-07 17:21 UTC
Many Qt developers strongly prefer the classes offered by Qt to those in stdlib. I (like almost everybody else) learned stdlib much before Qt, and I really don’t miss using the stdlib stuff.
“Modern” is a loaded word. What you see as modern, many will see as clunky committee-driven design.
What are you using for drawing now? Cairo?
Do you hate the kind of C++ you use with Qt? Because it’s pretty much the same as using Java.
People who think they hate C++ usually don’t hate C++ the language, they hate the libraries they are forced to use. C++ can be as productive and “fluid” as any other language, when you have a good library. I get the same kick from writing C++ code with Qt as I get from churning out Python code (and that’s saying a lot).
“Go” might evolve into one.
Ever heard of something called Perl? 😉
Perl (5) is a mess to maintain, when project gets big. Perl 6 aims to fix that but it’s incompatible…
It is hard to argue with that, but I’d imagine good practices and a solid IDE could go a long way to help that.
Unfortunately yes. It was the first scripting language I learned.
If HP Lovecraft designed a programming language, he would base it on Perl.
My favourite author and least favourite language compaired with each other…interesting.
C++ with Qt is certainly better than using C++ with any other library I know of, however it’s not quite like Java. Obviously, there is some manual memory management involved (although that makes sense, given C++’s purpose). The biggest problem is just the inconsistent, complicated syntax. Also, the main feature I find myself wanting in C++ is something like algebraic data types. Boost.Variant gives some really bad error messages. I have written my own variant class using C++0x’s variadic templates, which makes the error messages nice, and the compile times much faster, but it’s not feature complete yet. I’ll admit that I do love all the power that C++ gives you (there is no way I could write a variant type in any other language I know of, obviously not counting languages with it built in), but I don’t see why a “powerful” language has to make so many mistakes.
I really hope not. Go is the only “modern” language I know of that has a syntax even worse than C++ (not counting esoteric languages, of course). Also, it’s missing a lot of features such as generics/templates. D2 is the best option I know of, but it’s not yet ready. Also, I am working on my own programming language in my spare time, mainly just for fun, that has all of the features I want. I doubt I will ever finish it though…
There is actually very little manual memory management going on, since the QObject hierarchy and implicit sharing do the bulk of the work. If you do lots of memory management, you are doing something wrong.
Do you really need that in normal programs?
Maybe not in the typical GUI-driven business application. But if you are writing more low-level code (and I do use Qt for low-level code, since it provides platform-independent unicode strings and threading), it’s very handy (and safe!) if you can unwrap data via pattern matching.
C++ is a hell of an ugly language (D2 shows that pretty much the same functionality can be provided far more elegantly), but it is also one of the few languages that provides stellar performance, while having far more abstraction than C. I use C++ as a necessity, but will drop it very soon once a widely-accepted alternative comes along.
I know that C++0x solves some of the current problems of C++, but language support for currying, lambdas, and type inference does make life far easier. I mean, explicitly writing function objects in 2010…
What do you mean here? Language support for lambdas and type inference are exactly what C++0x is bringing to table (and currying is trivial when you have lambdas). Granted that garbage collection would make closures safer and more natural…
C++ is not the “optimal” solution by any means. I’m a recovered C++ hater myself (mostly because I used to be a Symbian programmer). But, a language to replace it needs to reach a pretty damn broad adoption and acceptance before it even gets close.
My main gripes are addressed by C++0x.
Sorry, I have not been so explicit here. I know that C++0x provides lambdas and some type inference. I played with some of the new features in fresh g++ versions. They do clean up a lot of code, but it will still take some years until everyone supports them (e.g. OS X via XCode, rather than MacPorts).
Indeed. D2 as a language provides an excellent replacement. But it will take some time until the compilers and libraries catch up.
But I sometimes wonder if taking a full plunge into functional languages is not better. I have written some small programs in Haskell, and they are often more elegant than in C++. Of course, Haskell has its own set of problems, it’s often hard predict performance in a lazy language, and stuff like performant hash tables are not trivial (yes, I do know Data.Judy).
That said, I am happily using Qt in various projects, including:
http://github.com/danieldk/dact
http://github.com/danieldk/alpinocorpus
http://github.com/langkit/citar
Edited 2010-08-07 16:51 UTC
I don’t like C++ libraries much either when they are written in the template-tastic style of boost. But I find the Qt dialect of C++ to be quite nice to someone who doesn’t like C++ all that much. It makes the language perfectly acceptable to me. I personally still prefer to develop Qt apps in QtRuby, and there are plenty of other good language bindings for Qt like PyQt, PerlQt, PySide, Qyoto(C#) and so on.
QtRuby is nice, however, OS X is badly supported. Try to compile a recent version .
Yes, sorry, sorry. We need to fix cmake to work better with frameworks I think on Mac OS X (was that your problem?). I have no excuse to not help fix it – I am writing this on an iMac.
I agree with Richard Dale!
I use QtRuby as well for all my stand-alone apps; as a result, along with QTDesigner, I don’t need to know hardly anything about C++! And, my friends all use my apps no matter what OS they are running! SWETE!!!
So do I and that’s why I use PyQT.
To appreciate C++ all you have to do is see how much additional work it actually takes to develop a cross-platform Java application. Perhaps Java has improved but a lot of us were burned by the promise of ‘write once run anywhere’ that really was ‘write once debug everywhere’ so you can get a non-native looking application.
C++ can be needlessly finicky and lacks memory management. It can also feel like it has one foot firmly planted in the 70’s. I prefer C# but would take C++ over python.
As for Qt it is the best cross-platform toolkit available, such a shame the open source world is still building around GTK.
Qt in C# would be awesome. Aside from a few minor annoyances, C# is what Java should have been and what C++ should have been heading towards and not away from. Just check out the C++ FQA for just some of the many reasons why C++ is broken by design (http://yosefk.com/c++fqa/).
Tying cross-platform toolkit to Windows-only language would be an EPIC facepalm.
What makes you think C# is windows only? Ever heard of mono?
The language isn’t Windows-only…
C# is .NET only. .NET is Windows-only. Mono is crappy implementation of .NET which is backed by Microsoft and their subsidiary, Novell, only so that people can point at it and try to make an argument that .NET can run outside of Windows, all in hope to get C# more used.
If C# get ubiquitous, they will just shutdown Mono by claiming patent infringement, telling people to buy Windows it they need .NET. So Mono shouldn’t count if you’re examining possibility to use C#.
Microsoft is corporation with drug dealer mentality, take one sniff and you are their for life.
C# is an ECMA standard
http://www.ecma-international.org/publications/standards/Ecma-334.h…
In practice, C# is a “Microsoft language”, as they will always have the best implementation of the whole .Net stack. The others (just Mono in practice) are shoddy & slow imitations at best.
The psychology at play is “better to reign in hell than serve in heaven”.
C# as a language is completely separate from the .net stack. You can read through the spec yourself.
Mono is a step behind but that is what everyone expected. For quick in-house Win/OSX apps it is pretty good.
No I think the psychology at play is paranoia.
Reading through the spec doesn’t help the fact that there is no C# implementation that is separate from .net stack.
Mono is separate from the .net stack. You know this, yet choose to ignore it.
Mono is an implementation of the .net stack.
Qyoto
… wraps qt for .net (clr), just like gtk# does for gtk+. It still doesn’t make c# an independent language in practice. Having C# running on jvm would.
No it’s a binding for Qt that doesn’t use .net. It doesn’t even clone the Winforms API like Mono.
Visual studio can’t do anything with a program written in Qt. There is no .net wrapping involved.
So it has its own vm and c# compiler?
A language has to have its own VM and compiler to be an independent language? That makes zero sense.
You do realize that Quoto uses Qt controls, right? C# bindings in Qt are no more dependent on Microsoft than Perl bindings.
Visual Studio would not even be able to compile this simple hello world application:
http://www.kdedevelopers.org/node/1678
I consider Scala to be a language that is dependent on Java, for example. At least as long as I can see an implementation that doesn’t need JVM.
Slapping on a UI library (that is not Swing) doesn’t make it an independent language.
And, this is a stupid game on semantics ;-).
The C# specs are written and published solely by Microsoft. So its a pain fact that C# is a MS language, especially considering that the standardization was just a marketing stunt. Neither C# 3.0, nor the new C# 4.0 are standardized by any committee.
Well Ruby isn’t standardized by a committee either, and nobody complains about that. You either believe that Microsoft are acting in good faith to make C# more popular, or you don’t. I don’t think it possible to have a rational argument about that.
Edited 2010-08-08 14:42 UTC
I wasn’t writing about Ruby. Why are changing the subject?
I was simply supporting the argument that C# is a Microsoft language. That’s a plain fact and no topic changing to Ruby is going to change that.
No the C# spec was written by Microsoft and now exists independently of them as an ECMA standard.
Wait I thought that C# was published solely by Microsoft? Now you acknowledge that it is an ECMA standard but the problem is that it is behind?
At least keep your criticisms consistent.
Yes, but it’s not the greatest solution for FOSS GUI development…
That may be true, but you still can’t ignore it. Whether Microsoft ever does anything “evil” or not, if you write an application for Mono, a lot of people are not going to use it. It’s simply not very well accepted by the FOSS community. Personally, I doubt Microsoft will ever do any harm to Mono, but I wouldn’t bet on it. So therefore, I don’t write code for C#/Mono.
Agreed and I have stated numerous times that Qt is the best cross-platform dev kit available.
Mono and C# should be viewed separately but it is of course understandable as to why they have a close association.
Mono clones .net functionality that is not an ECMA standard. I highly doubt MS would go after Mono especially when it is already behind and there are no plans to implement WPF:
http://www.mono-project.com/WPF
So rejecting Mono is one thing but I think rejecting C# entirely goes too far. C# is under their Community Promise and threatening an independent implementation would be a p.r. disaster of the ages.
http://www.microsoft.com/interop/cp/default.mspx
Show me working C# implementation that doesn’t compile to MSIL. Either JVM implementation, or something like that. If you can’t do that, then stop lying that C# is not Microsoft-only language.
You twoface jerkface. You saying here that Mono is “pretty good” and on your blog you write that is crap and has memory leaks. So which is it?
You dress up facts for the occasion, to always suit your Windows zealotry.
Quoting Andy Grove: “Only paranoid survive”.
Qyoto.
Do you not understand what ECMA certified means?
http://www.ecma-international.org/memento/index.html
On my blog I was talking about Mono ASP.NET, not Mono on the desktop.
So is OOXML.
So is the UMD disc inside the psp.
Just use Qyoto: C# bindings for Qt :-). See http://techbase.kde.org/Development/Languages/Qyoto.
C++ has many weak points, but the C++ FQA borders on being trollish, and is often half-true. I’ll take a random question:
http://yosefk.com/c++fqa/dtor.html#fqa-11.1
His criticism is that RAII fails if there is no clear ownership of resources. He fails to mention that TR1 has shared_pointers, which is a pointer-wrapping class that does reference counting. As it shows, RAII can handle cases where the is no single owning object.
Another mosty question:
http://yosefk.com/c++fqa/operator.html#fqa-13.2
So, he does not like DSLs defined within a language. Big deal, I dislike having to invoke external preprocessors when something can easily be done within the language. Doing so, also provides many opportunities for optimizations (see template-based matrix libraries).
You obviously didn’t use Java for a decade. Quit talking about things you don’t know about. Java works as promised, try again.
No I didn’t use Java for a decade. I correctly predicted that Sun wouldn’t fix Java in time to compete with .net so I switched.
Says the guy who claimed C# to be a Windows language.
Java is dead on the desktop, sorry if you didn’t get the memo. I don’t even have the JRE installed.
It was designed for that. The version 2 of the spec is very interesting.
D2 is great, but it’s still not ready after several years. The compiler crashes even on some basic template tests. Also, DMD is not very portable and its backend is not quite as good as LDC, but LDC doesn’t support D2 very well yet. Both projects don’t look terribly active, so I’m not sure if we’ll ever see a complete D2 compiler.
“Qt is all set to become the way that Nokia-friendly apps are made ”
but what about user friendly apps? I don’t think most people will be too excited about a whole bunch of desktop linux ports to their phone.
Maybe it is only me, but every time I use a Qt app or see one in action it seems terribly slow to me.
Judging by what I saw so far, Qt is bogging Nokia down performance wise.