Giuseppe D’Angelo
97 results
KDTableToListProxyModel: a flattening proxy model
30 September 2019
With this blog post we are going to kickstart our brand new blog series about KDToolBox. The first class we're exploring is KDTableToListProxyModel, a table-to-list proxy model. The main use case for KDTableToListProxyModel is exposing tabular models to Qt Quick. Qt Quick has a certain number of "view" elements that only support list models: for […]
At KDAB we invest a significant amount of efforts in research and development. We are always looking for new tooling, libraries and utilities that can make our job easier and improve the C++ and Qt ecosystems. Ultimately, the gained knowledge and skills make our customers happier. As part of this process we develop lots of […]
New in Qt 5.11: improvements to the model/view APIs (part 2)
Automated validity checks using QAbstractItemModelTester
In the last episode of this series we discussed QAbstractItemModel::checkIndex(). QAbstractItemModel::checkIndex() is a function added in Qt 5.11 that allows developers of model classes to perform some validity checks on the QModelIndex objects passed to the model; specifically, on the indices passed to the APIs that model classes need to implement (rowCount(), columnCount(), data, setData(), […]
The Qt model/view APIs are used throughout Qt -- in Qt Widgets, in Qt Quick, as well as in other non-GUI code. As I tell my students when I deliver Qt trainings: mastering the usage of model/view classes and functions is mandatory knowledge, any non-trivial Qt application is going to be data-driven, with the data […]
KDAB at QtDay 2018
25 April 2018
QtDay is the yearly Italian conference about Qt and Qt-related technologies. Its 2018 edition (the seventh so far!) will be once more in the beautiful city of Florence, on May 23 and 24. And, once more, KDAB will be there. I am also glad to announce that my talk has also been accepted: I am […]
Qt talks at CppCon 2017
7 August 2017
The program for CppCon 2017 is now published! CppCon is the annual conference for the C++ community: five days packed with over 100 talks, as well as inspiring keynotes, panel discussions, hallway chats, fun evening events and much more. CppCon is a project of the Standard C++ Foundation, a not-for-profit organization whose purpose is to […]
Property bindings are one of the most interesting features of the QML language. In QML, when we set a value on a property, the right hand side expression isn't evaluated just once to produce a value, like in a ordinary imperative language. In particular, if the expression involves other properties, then the property we're setting […]
3D scenes in applications are trending and will become more important with VR/AR growth. While Qt allowed OpenGL integration, managing rendering code remained challenging. Qt's new Qt 3D module addresses this with simple APIs for getting 3D content into applications. This short talk introduces Qt 3D's design ideas, use cases, and ease of implementation.
KDAB contributions to Qt 5.9
31 May 2017
Qt 5.9 has just been released! This release marks two important milestones for the Qt Project. The first is that now the Qt 5 series has had more releases than any other Qt version ever (the last release of the Qt 4 series was Qt 4.8). The second milestone is that Qt 5.9 will be […]
A small new feature that I have added to Qt 5.8 is the possibility of disabling narrowing conversions in the new-style QObject::connect statement. In this short blog post I would like to share with you why I thought this was useful and therefore implemented it. The problem Since Qt 5.0, the new-style, PMF-based (pointer to […]
All Qt developers have asked themselves at least once in their careers: "why isn't my slot invoked?" (I've asked myself that question many, many times). There are a number of reasons why a connection may fail to be properly set up, and ultimately cause our slot not to be invoked. This blog post is a […]
New in Qt 5.8: meta-object support for namespaces
Using namespaces in Qt for enumeration introspection
A small new feature that was added to Qt 5.8 is the ability for moc (Qt's meta-object compiler) to extract meta-object information at the namespace level. This means, for instance, that you can have introspection support for enumerations defined in a namespace (not just in QObject subclasses, or classes tagged with Q_GADGET), and use such […]
KDAB contributions to Qt 5.8
28 February 2017
Qt 5.8 has just been released! Another great release of Qt, made possible by thousands of commits by over a hundred different contributors: And here we are again, with the usual showcase of the most outstanding contributions to Qt 5.8 developed by KDAB engineers. In no particular order: Qt 3D Qt 3D continues to receive […]
Integrating OpenGL with Qt Quick 2 applications (part 2)
Implementing overlays and underlays with the Qt Quick 2 renderer
In the last blog post we gave a very high level introduction to the Qt Quick 2 renderer. We also showed how various signals are emitted by the renderer during the synchronization and rendering steps. In this blog post we're going to discuss those signals and show how they can be used to implement overlays […]
The last post from my colleague Marc Mutz about deprecating Q_FOREACH caused quite an uproar amongst the Qt developers who follow this blog. I personally feel that this was caused fundamentally by a perceived threat: there is a cost associated to porting away a codebase from a well-known construct (Q_FOREACH) to a new and yet-undiscovered […]
For today's blog I would like to share with you the little adventure I had when fixing a very strange bug in Qt. Pop quiz Don't think about this too much, just guess: what does this QML snippet print? There are no JavaScript semantic tricks involved; and using either == or === does not change […]
Multithreading with Qt
How to leverage the modern C++11 threading capabilities in your Qt application
This talk introduces you to the fundamentals of threading in Qt. We will discuss how threads, QObjects and events interact together; how a thread affinity of a QObject has a play in signals and slots connections; and how you can leverage the modern C++11 threading capabilities in your Qt application. Cross-platform thread support was introduced […]
This talk will introduce you to various effective strategies of drawing raw OpenGL content inside a Qt Quick 2 scene. After a brief introduction to how the Qt Quick 2 renderer works, we will see the APIs in Qt 5.6 that allow us to integrate existing OpenGL code and QML. One of the foundation pillars […]
This talk introduces you to the fundamentals of threading in Qt / qthread. We will discuss how threads, QObjects and events interact together; how a thread affinity of a QObject has a play in signals and slots connections; and how you can leverage the modern C++11 threading capabilities in your Qt application.
This talk will introduce you to various effective strategies of drawing raw OpenGL content inside a Qt Quick 2 scene. After a brief introduction to how the Qt Quick 2 renderer works, we will see the APIs in Qt 5.6 that allow us to integrate existing OpenGL code and QML.