So i have jumped into the world of qml from qwidgets and holy shit is it awful. Some parts are interesting, but for the most part, the part of actually getting work done, is slow and cumbersome. First, you either wait for qt to make standard controls like a button or treeview or you get to write them yourself. Yep, you get the awesome task of writing a new paint method for every control that isn’t built in. As of right now, there are a few controls that let you get things in as per expected, but it is severely lacking. For example, want to make a dockable panel? Nope, the only solution found is use a qdockwidget and jam a qml interface inside it. Want a treeview, make it yourself.
Coming from qwidgets, it doesn’t seem to solve many problems. All i can see is you get some fancy transition-animations and its easier to make a custom control (css/json vs paint override). Oh you can use javascript to control your ui behavior. I guess thats good? It looks like there is data-binding but I still see people having to use event guards so either they are missing the binding or binding is crap.
Its a whole new thing to learn, which isn’t bad at all, but the thing you’re learning is painful. The layouts are all over the place. do i use Layout.fillWidth or anchors? Things just act weird and there is little to help you figure out why. The designer is lacking in many ways, like the Layout mentioned above, not available in the designer so you have no idea it exists.
It feels like its geared towards mobile and we all know how well mobile translates to desktops (looking at you windows 8). This whole framework feels half assed and rushed out the door.
So I’ve only done the most basic of demo’s with QML and just couldn’t see a need to dig any deeper.
But your post did spark a memory of someone who had made a QML plugin that let him call python directly in QML . https://github.com/thp/pyotherside
Not sure if it is any less frustrating, but it does seem interesting at least.
I’ve worked with QML exclusively for the past year and haven’t got any plans on developing with widgets anytime soon.
I’d rather not try and convince anyone, as I take it OPs mind is already made up, but will simply say that QML is where development happens today and that widgets are effectively dead in the water; support dropping for 4.8 in 2016 and widgets overall being feature freezed since 5.0.
Granted it’s new, it won’t have as much of the convenience accumulated by widgets ocer the past decades, and it’s a new way of thinking - it’s declarative versus imperative which does require a switch in mindset, not just a remapping of what command do like switching between Qt and Gtk.
As for its ease of use, I’d say yes, it’s fantastic. Bindings are amazing, it’s Python integration effortless (you can already call Python from QML and vice versa btw) but the greatest advantage to me has been that it promotes a strong decoupling between the model (such as Maya), view (QML) and controller (Python). GUI development has gone from learning about and fighting with various convenience widgets to designing in a readable and easily adjustable syntax.
I found this an excellent resource for learning about good practices and visually stunning results.