Earlier quoted context omitted.
I avoided Qt for a long time due to what I'd heard about moc being required. However recent versions support connecting lambdas to slots which is sufficient for my relatively simple application to avoid using moc to set up signals/slots.
Do you have a link that shows how to compile a Qt app without moc? I looked specifically for this and could only find this, which is unofficial and contains a bunch of ugly macros: https://woboq.com/blog/verdigris-qt-without-moc.html
Qt 5.7 released
41–50 of 108 posts
Re: Qt 5.7 released
#42I want to like Qt but I hate that it needs moc. Also I don't like that it doesn't use much of the STL - it forces you to use classes like "QVector" and "QList" instead of std::vector and std::list.
https://github.com/woboq/verdigris
Unlike Copperspice, the other MOC-less Qt, this one is API compatible with Qt itself, you just include it and drop the MOC and use its functions instead of the original library ones and it can connect to normal Qt data structures.
And like others have said, you can use as few or as many Qt data structures as you want. The problem is that if you end up using Qt IO, you end up getting QStrings and QVariants, which you usually want to keep that way and end up using containers that recognize those types.
If we had a good C++ var type, and a usable string class, there would be an argument to depreciate whats there, but even Qt cannot do utf-8 right (QString is utf-16).
Re: Qt 5.7 released
#43Earlier quoted context omitted.
While it doesn't have a similar commercial backing, wxWidgets is still going strong and is quite solid.
I always wondered why, after all these years, the only alternatives that remain are wxWidgets and Qt. It's a very common pattern, multiplatform gui programming! and after all this time, we only have 2 choices..
Also, the reason not too many have become mainstream (like wx and Qt) is probably largely because it's quite a difficult job to create a new one, even on one OS only [1], unless all you are doing is thinly wrapping an existing native toolkit. I read some about this in a book that goes somewhat into the internals of Qt3 or 4.
[1] and cross-platform is harder still.
Re: Qt 5.7 released
#44Earlier quoted context omitted.
I always wondered why, after all these years, the only alternatives that remain are wxWidgets and Qt. It's a very common pattern, multiplatform gui programming! and after all this time, we only have 2 choices..
It's an incredibly fast moving target. Just look at the GTK mess, let alone keeping a wrapper toolkit up to date with other vendors' OS updates. Plus for operating systems like Windows it's not really clear which GUI technology to wrap. All the wrappers I've seen so far wrap the old school Win32 API but many modern applications are written in WPF or WinRT. Supporting all three would be difficult. Also OS X is a somew…
Good point indeed.
Re: Qt 5.7 released
#45I want to like Qt but I hate that it needs moc. Also I don't like that it doesn't use much of the STL - it forces you to use classes like "QVector" and "QList" instead of std::vector and std::list.
Theres a neat project in the works: https://github.com/woboq/verdigris Unlike Copperspice, the other MOC-less Qt, this one is API compatible with Qt itself, you just include it and drop the MOC and use its functions instead of the original library ones and it can connect to normal Qt data structures. And like others have said, you can use as few or as many Qt data structures as you want. The problem is that if you en…
Re: Qt 5.7 released
#46Earlier quoted context omitted.
QML is basically a JavaScript superset ?
Yeah, it's that bad... If all of your code base is C++, what do you think the mindset is of the main developers? The only compromise they were able to allow themselves to think in was... ECMAScript. Sad.
Re: Qt 5.7 released
#47I want to like Qt but I hate that it needs moc. Also I don't like that it doesn't use much of the STL - it forces you to use classes like "QVector" and "QList" instead of std::vector and std::list.
Which are quite better designed, more lightweight and better suited to the GUI tasks -- not to mention take less time to compile when used. Of course if you want you can also use STL.
Re: Qt 5.7 released
#48I want to like Qt but I hate that it needs moc. Also I don't like that it doesn't use much of the STL - it forces you to use classes like "QVector" and "QList" instead of std::vector and std::list.
You can use std as much as you want. Qt doesn't force you to use their containers. Moc is not a problem anymore also, it's more an a myth now than anything else.
I'm not sure what you mean by "Moc is not a problem anymore, ...". AFAICT, Moc is still used by Qt and is at least still in their documentation. http://doc.qt.io/qt-5/why-moc.html I'm personally not too bothered by Moc and see it as a trade off of using Qt. I'd prefer a cleaner "pure" C++ solution, but I don't know of any GUI toolkits as nice as Qt without Moc.
Qt is still my preferred GUI framework, and I use it from C++, Python, and lately Common Lisp. My biggest complaints are the way it's been increasingly tied to Qt Creator and the focus on Qt Quick and QML.
Re: Qt 5.7 released
#49Earlier quoted context omitted.
What's wrong with paying for an extremely high quality GUI toolkit? Btw. It's very easy to comply LGPLv3 in proprietary project if you want. 1) If you don't modify the Qt library and link dynamically there is no problem whatsoever. 2) If you modify the Qt library or link statically, it's enough to provide modified version of the Qt library and combined object files that make it possible to relink the application to d…
Many developers feel entitled to get their tools for free, but expect to be able to charge for their stuff, it seems. This is what made RoboVM go comercial AFAIK, as they could hardly make a living from contributions.
Re: Qt 5.7 released
#50I want to like Qt but I hate that it needs moc. Also I don't like that it doesn't use much of the STL - it forces you to use classes like "QVector" and "QList" instead of std::vector and std::list.
Sure, its another build step, but so what? I mean, most large complex software has numerous build steps and MOC is pretty straightforward (and if you use QMake or QtCreator, its pretty much invisible to the programmer). I'm trying to understand why people dislike it so much.