EsoErik

Tuesday, November 24, 2015

 

Doing anything significant whatsoever with QML, part 1

As a long time C++ and Python (PyQt) Qt developer, I have been observing the Qt project's move towards Javascript/ECMA script with a mixture of contempt and dismay.  Since the early days of Qt4, every dot release of Qt included some new Javascript module or feature that would supposedly shift every paradigm.  However, to be quite frank, the included examples for the latest Qt Javascript features were low quality hello-world type applications with glaring bugs.  Nothing in the mosh pit of QtScript, QtDeclarative, QtQuick, and/or QML seemed appealing, and nobody anywhere seemed to be using it for anything.

However, that is beginning to change.  Wanting to fix some issues I encountered in KDE5/plasma, I discovered that it's largely QML.  Even the start-menu/kicker thingy is QML.  In order to make that menu taller, which was a simple click-drag operation in KDE4 (drag the top right corner to resize as if it were a window), KDE5 required me to edit a QML file.  Needing to edit a file rather than simply click-dragging is moronic, but, in any case, I had manipulated my first QML file, and that QML file represents a GUI thing that I use quite often.

My interest piqued, I spent an hour here and there over the course of the following weeks familiarizing myself with QML, Qt Quick2, the Qt Quick 2 scene graph, Javascript, interfacing C++ and QML, doing OpenGL in Javascript in QML, exposing QAbstractItemModel derivatives implemented in C++ to QML, and the like.

My impression at this point:

In other words, as I write this, it's my opinion that QML and the entire Qt Javascript effort has been a complete waste of time whose only significant impact has been to cause the useful C++ parts of Qt to go essentially unmaintained for the last five years.  For example, Qt 5.5.1 still doesn't support mouse event compression on X11, making it unsuitable for anything where mouse movement can cause computation that takes more than 1/60th of a second.  Things so basic that they can't not work... don't work.  And nobody cares, because javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript javascript.

Nonetheless, it is conceivably possible that I've had a rough time with QML simply because I'm thrashing about, ignorantly trying to do simple things in impossibly stupid ways that go against the flow.  Maybe I would have a fine time if I just read the documentation, worked through a few tutorials, and gave up my hidebound C++-centric ways.  So, I'm doing exactly that, and part 2 will detail my rebirth and first fresh steps with Jesus QML.

Comments:

Post a Comment

Subscribe to Post Comments [Atom]





<< Home

Archives

July 2009   August 2009   September 2009   October 2009   November 2009   December 2009   January 2010   September 2010   December 2010   January 2011   February 2011   April 2011   June 2011   August 2011   February 2012   June 2012   July 2012   August 2012   October 2012   November 2012   January 2014   April 2014   June 2014   August 2014   September 2014   October 2014   January 2015   March 2015   April 2015   June 2015   November 2015   December 2015   January 2016   June 2016   August 2016   January 2017   March 2017   April 2018   April 2019   June 2019   January 2020  

This page is powered by Blogger. Isn't yours?

Subscribe to Posts [Atom]