Details
-
Bug
-
Resolution: Invalid
-
P1: Critical
-
6.2.5, 6.3.1
-
d01880e8f6 (qt/qtdeclarative/dev) d01880e8f6 (qt/tqtc-qtdeclarative/dev)
Description
https://doc.qt.io/qt-6/qml-codingconventions.html says, "For better readability, we separate these different parts with an empty line."
However, this is no longer properly enforced in Qt 6.x.
In the example below, both Qt 5.15 and 6.x correctly insert a line between import and Rectangle. However, on Qt 5.15 inserts a line between id and property – Qt 6.x does not.
Input file
import QtQuick 2.15 Rectangle { id: photo property bool thumbnail: false }
Outcome for Qt 5.15.10 (correct)
import QtQuick 2.15 Rectangle { id: photo property bool thumbnail: false }
Outcome for Qt 6.x (wrong)
import QtQuick 2.15 Rectangle { id: photo property bool thumbnail: false }