As mentioned in previous blog posts, we are currently playing around with ideas for a new widget architecture. While I was in Brazil, I spent some time working with guys at INdT in Recife. We decided to put together a proof-of-concept demo.
QML application using styled components.
The idea behind the project is to take a different approach to UI components and from what we have done in the past.
In Qt today the look-and-feel of a widget is to a large degree implemented in the widget itself, often intertwined with the logic. Styling of widgets is done by forwarding painting calls to QStyle and by requesting hints from the style for certain behavior or property values.
As I wrote in I can haz teh future, plz, we want to separate the UI component data-and-logic from the look-and-feel. This allows us to save the UX designer from having to deal with the messy, complicated and error-prone parts, while at the same time saving the developers from additional pain when said designer changes his or her mind. Win-win. :)
In my presentation at the Bossa'10 Conference I referred to the component's data-and-logic part as "controls", but after a reconsidering, I now refer to them as "models" (as per the MVC design pattern). The component models are implemented as sub-classes of QObject and export their values through properties.
We implement the look-and-feel part of the UI components using QML since this is what it does best.
As part of the proof-of-concept we have also implemented a styling system. The idea is that it builds the component by populating it with a scene-graph consisting of primitives. This gives the style full freedom to decide how the widgets will look and behave.
Stay up to date with the latest marketing, sales and service tips and news.
Download the latest release here: www.qt.io/download.
Qt 5.12 was developed with a strong focus on quality and is a long-term-supported (LTS) release that will be supported for 3 years.
Näytä tämä julkaisu Instagramissa.
Want to build something for tomorrow, join #QtPeople today! We have loads of cool jobs you don’t want to miss! http://qt.io/careers #builtwithQt #software #developers #coding #framework #tool #tooling #C++ #QML #engineers #sales #tech #technology #UI #UX #CX #Qt #Qtdev #global #openpositions #careers #job
Henkilön Qt (@theqtcompany) jakama julkaisu