Connection View is a collection of views that enable you to create connections between components and the application, to bind component properties together, and to add custom properties for components.
The components of the application UI and the application logic need to communicate with each other. For example, a button needs to know that the user has clicked it. The button may then change color to indicate its state or perform an action. Further, the application needs to know whether the user clicked the button because it may need to relay this clicking event to other applications. For this purpose, a button typically contains a Mouse Area component, which can receive different pointer events and emit signals in response to them.
Another way to connect components is to bind their properties together. A component's property can be assigned a static value which stays constant until it is explicitly changed. To make the UI more dynamic, you can use property bindings. This means that you can specify relationships between component properties so that when the value of a property changes, the values of any properties that are bound to it are updated accordingly.
In addition, application developers can use the Backends view to access QObject objects implemented in C++ from QML files.
|Connections||Create connections between components and the application logic by accessing signals outside of the components that emit them.||Connecting Components to Signals|
|Bindings||Dynamically change the behavior of a component by creating a binding between the properties of two components.||Adding Bindings Between Properties|
|Properties||Add custom properties that would not otherwise exist for a particular preset component or your own custom component.||Specifying Dynamic Properties|
|Backends||Access QObject objects implemented in C++ from QML files.||Managing C++ Backend Objects|
© 2021 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.