QtDesignStudio/FAQ: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
(First FAQ entry with correct structure of table of contents)
(Second entry)
Line 11: Line 11:


===What are the main differences between Qt Quick and Qt Ultralite?===
===What are the main differences between Qt Quick and Qt Ultralite?===
There are several differences that result from optimizations needed for the embedded world. These include:
There are several differences due to optimizations required by the embedded world. These include:
* Some QML types are unavailable in Qt Ultralite. The available types are listed [https://doc.qt.io/QtForMCUs-2.8/qtul-qmltypes.html here].
* Some QML types are unavailable in Qt Ultralite. The available types are listed [https://doc.qt.io/QtForMCUs-2.8/qtul-qmltypes.html here].
* Some of the types have additional constraints what is described [https://doc.qt.io/QtForMCUs-2.8/qtul-known-issues.html here].
* Some of the types have additional constraints what is described [https://doc.qt.io/QtForMCUs-2.8/qtul-known-issues.html here].
Line 17: Line 17:


For full overview of the differences please refer to [https://doc.qt.io/QtForMCUs-2.8/qtul-qtquick-differences.html QtForMCUs docs].
For full overview of the differences please refer to [https://doc.qt.io/QtForMCUs-2.8/qtul-qtquick-differences.html QtForMCUs docs].
===I'm starting a project for MCU, what should I remember at the very beginning?===
You can start immediately and create a new project using the Qt for MCUs presets.
The components and their properties available in the Design Studio editor should respect the MCU rules.  However, if you plan to edit the QML code manually, you may end up creating code that is not valid for the MCU and you won't notice it at first glance.
In this case it is worth configuring 'Qt for MCUs SDK' in 'Preferences->Devices->MCU'. The kit can be obtained from the Qt Maintenance Tool (an appropriate license is required). All you need to do is set the appropriate SDK installation path and reopen/create your project. With the MCUs SDK configured, Design Studio will automatically add an additional deployment step to your project that generates MCU-compliant C++ code. If something goes wrong during this process, such as using properties that are not available in Qt for MCU, you will see an error in the console.
For example, the following code for the Rectangle is perfectly fine, you can paste it into your MCU project in the Design Studio and run it:
<syntaxhighlight lang="qml">
Rectangle {
    width: 200
    height: 200
    visible: true
    anchors.centerIn: parent
    color: "red"
    rotation: 45
    border.width: 10
    border.color: "green" 
}
</syntaxhighlight>
However, a Rectangle type for MCU does not have ''border'' and ''rotation'' properties. If you configure the MCU SDK kit, you will see errors in the console and Design Studio won't be able to run the project/generate a preview:
{{WarningBox|text=C:/SomePath/SomeProject/Screen01.ui.qml:24:9: error: Group property of unknown type
border.width: 10
C:/git/dev/qt4mcu/tests/UntitledProject59/Screen01.ui.qml:23:9: error: Binding on property of unknown type
rotation: 45
}}


==Qt Bridge for Figma export==
==Qt Bridge for Figma export==

Revision as of 12:29, 25 September 2024

En Ar Bg De El Es Fa Fi Fr Hi Hu It Ja Kn Ko Ms Nl Pl Pt Ru Sq Th Tr Uk Zh

This page contains technical FAQs for Design Studio, its MCU support as well as Figma integration.

Design Studio & MCU

What are the main differences between Qt Quick and Qt Ultralite?

There are several differences due to optimizations required by the embedded world. These include:

  • Some QML types are unavailable in Qt Ultralite. The available types are listed here.
  • Some of the types have additional constraints what is described here.
  • The QML/JS support is limited for MCU to the features described here.

For full overview of the differences please refer to QtForMCUs docs.

I'm starting a project for MCU, what should I remember at the very beginning?

You can start immediately and create a new project using the Qt for MCUs presets.

The components and their properties available in the Design Studio editor should respect the MCU rules. However, if you plan to edit the QML code manually, you may end up creating code that is not valid for the MCU and you won't notice it at first glance.

In this case it is worth configuring 'Qt for MCUs SDK' in 'Preferences->Devices->MCU'. The kit can be obtained from the Qt Maintenance Tool (an appropriate license is required). All you need to do is set the appropriate SDK installation path and reopen/create your project. With the MCUs SDK configured, Design Studio will automatically add an additional deployment step to your project that generates MCU-compliant C++ code. If something goes wrong during this process, such as using properties that are not available in Qt for MCU, you will see an error in the console.

For example, the following code for the Rectangle is perfectly fine, you can paste it into your MCU project in the Design Studio and run it:

Rectangle { 
    width: 200 
    height: 200 
    visible: true 
    anchors.centerIn: parent 
    color: "red" 
    rotation: 45 
    border.width: 10 
    border.color: "green"  
}

However, a Rectangle type for MCU does not have border and rotation properties. If you configure the MCU SDK kit, you will see errors in the console and Design Studio won't be able to run the project/generate a preview:

C:/SomePath/SomeProject/Screen01.ui.qml:24:9: error: Group property of unknown type

border.width: 10

C:/git/dev/qt4mcu/tests/UntitledProject59/Screen01.ui.qml:23:9: error: Binding on property of unknown type

rotation: 45

Qt Bridge for Figma export

Design Studio import of data from Qt Bridge for Figma

Lorem Ipsum1?

Lorem Ipsum

Lorem Ipsum2?

Lorem Ipsum

Lorem Ipsum3?

Lorem Ipsum