Qt 5.0 Released
sfcrazy writes "The Qt project and Digia, the company behind Qt framework, have released the most awaited C++ framework for developers, Qt 5.0. The company claims it's one of the best releases to date and has invested a significant amount of time behind this release. It's an overhaul of the Qt 4.x series and makes Qt fit for the future."
Update: 12/19 17:46 GMT by U L : Major new features include an overhauled graphics layer, full integration of Qt Quick for creating flexible interfaces using Javascript, and increased modularization including the first steps toward de-emphasizing QtWidgets by separating them into their own module.
Oh right, this is slashdot.
But it's not even like you have to read anything. It's a video demonstration.
File under 'M' for 'Manic ranting'
... hence thousands of non-programmers continue to talk about how superior it is to GTK+
Having done a small amount of Qt programming, it's also one of the most pleasant APIs I've worked with, both in its C++ form and in PyQt.
If you didn't already know what Qt was, then you're probably not going to be particularly interested that version 5.0 is out.
Did they make any moves towards using standard C++ features rather than the MOC ugliness? What with Boost::Signals, sigcxx and C++11, I see no reason why they have to bastardise the language to provide signals.
It's the framework for KDE, which is the excellent, fast UI environment I use on my Linux rigs. Apparently a huge number of other projects either use it currently, or have used it in the past, including a number of well-known projects: Amazon Kindle, Google Earth, Adobe Photoshop, MythTV, Rosegarden, Skype, Virtualbox, VLC media player.
This really is the best cross-platform Apps framework out there. Far better than HTML5/Javascript.
One framework to rule them all, making programs for all platforms, including mobile ones, is a nice goal.
Even worse, I don't know what "C++" or "project mean"!
Wow, sent an e-mail as suggested when clicking on "use classic" banner, and got a fast response that addressed my msg
You can now use any C++ function as the target of a signal using the new QObject::connect() syntax. This is a huge win because with the new syntax the compiler and linker can check that the connections are valid instead missed connections just causing a run-time error.
The moc preprocessor is still required for QObject derived classes, mostly for the translation framework and also to provide support for the old signal/slot syntax which is still allowed. Qt5 doesn't require a C++11 compliant compiler, which is a good thing since there aren't yet any fully compliant compilers. I'm sure if there is a Qt6 it will require C++11 and use those features.
Some of the really cool C++11 features like move constructors aren't necessary with Qt because it's containers implement reference counted copy-on-write, so when you assign a QMap from another QMap no copy is made, and if the old QMap was an rvalue then there is never a need for the copy to be made when the new QMap is modified. One of the big improvements Qt4 made over Qt3 was to make container assignment atomic so this mechanism worked with threaded code and defensive deep copies weren't necessary anymore.
I used Qt Quick briefly. It seems like you get a lot of deep powerful customization, but that comes at a cost. It eventually pissed me off so I went back to QWidget, and my productivity soared.
I would not have completed my project in a reasonable time using Qt Quick. It is not "quick". Sometimes, you just want to drop tables, check boxes, buttons, etc. on to your main window, tie the click event to a slot, and call it done. You are fine with whatever default styling and rendering that Qt and the OS decide is appropriate for the widget's click/hover/etc event.
It seems with Qt Quick, you have to specify all that nonsense. Plus, the Qt Quick editor tool felt complex and confusing. I avoided it and did everything by hand. Qt Designer for QWidgets is a drag-n-drop breeze. I even got my manager on board after he saw me using it. He is an EE, and he really likes it. He is used to spending $500 on Visual Studio Pro to what Qt Designer does better for free.
Maybe I just needed to study Qt Quick more to get past the learning curve, but I knew how to do it the widget way, and I wanted the project done.
Has anybody had success migrating their project from QWidgets to Qt Quick? Unless I see a strong compelling reason, I am sticking with QWidgets. It works really well for me.
It's mature and has all the bells and whistles. Only other alternative is WxWidgets...
What else did you have in mind ?
Here's the basic group that Qt belongs as part of:
WxWidgets is public domain; and was the first (AFAIK) to do both Signals/Slots and Message Maps for inter-object comms.
Gtk was originally just MessageMaps, and now also does Signals/Slots; but it also tends to be heavily GNOME centric and rather largely ignored by GNOME in maintaining it - it moves along, but at a snails pace because they're not really paying attention to it (to my understanding from talking to someone in the GNOME community).
SDL isn't quite as feature complete as any of the others, but can get the job done.
Qt is really the only first class library in that group, and now reaches even more platforms than ever before. And with Qt embedded, it runs in many devices that you may never have thought of as having run Qt (Microwaves, TVs, Refrigerators, etc.). Qt really is to multi-platform development what Linux is to processors in that respect.
So in the sense that nothing else is really as feature complete and professional as Qt - yes, it's in its own category. But in reality there are several other major competitors - and all from the FLOSS community at that.
Truth is like the sun. You can shut it out for a time, but it ain't goin' away. - Elvis Presley (source: imdb.com)
How is Qt still relevant?
Let's see...
It's the only multi-platform development kit that is really as feature complete as most platforms.
It runs on more devices than you'd ever imagine - from small embedded devices to your kitchen appliances to mobile devices to desktops and servers.
It's what KDE is built on.
It's what MeeGo/Mer/Tizen/Sailfish are built on.
It's what Blackberry 10 (BB10) is built on.
AutoDesk is built on it.
CiscoVPN is built on it (well, a really old version at least).
There's plenty more out there; but I'm going to stop there.
Truth is like the sun. You can shut it out for a time, but it ain't goin' away. - Elvis Presley (source: imdb.com)
Small correction: wxWidgets isn't public domain. It's licensed under the wxWindows Licence which, as their page states, is like the LGPL but with a few differences.
That's ... a bit of an understatement. SDL is a frame buffer, audio buffer, and input poller. For writing GUIs, it's about as feature-complete as QPainter. Sure, you can write your own GUI widget library on top of it, but that won't be pleasant for you or your users.
SDL is more suited for abstracting the platform video/audio/input APIs, and can be used nicely in conjunction with Qt, GTK+, etc.
Most people don't know what Qt is, though. They don't realise how much of the software they use uses it.
I really wanted to change my sig to something witty, but all I could come up with is this.