diff --git a/share/qtcreator/qmldesigner/itemLibrary/quick.metainfo b/share/qtcreator/qmldesigner/itemLibrary/quick.metainfo index 17c2c114b8c..13f5ffabcdb 100644 --- a/share/qtcreator/qmldesigner/itemLibrary/quick.metainfo +++ b/share/qtcreator/qmldesigner/itemLibrary/quick.metainfo @@ -203,7 +203,7 @@ MetaInfo { libraryIcon: "images/gridview-icon.png" version: "2.0" - QmlSource { source: "source/gridviewv2.qml" } + QmlSource { source: "source/gridview.qml" } toolTip: qsTr("Organizes dynamic data sets in a grid.") } } @@ -218,7 +218,7 @@ MetaInfo { libraryIcon: "images/listview-icon.png" version: "2.0" - QmlSource { source: "source/listviewv2.qml" } + QmlSource { source: "source/listview.qml" } toolTip: qsTr("Organizes dynamic data sets in a list.") } } @@ -233,7 +233,7 @@ MetaInfo { libraryIcon: "images/pathview-icon.png" version: "2.0" - QmlSource { source: "source/pathviewv2.qml" } + QmlSource { source: "source/pathview.qml" } toolTip: qsTr("Organizes dynamic data sets along a path.") } } diff --git a/share/qtcreator/qmldesigner/itemLibrary/quick3d_particles3d.metainfo b/share/qtcreator/qmldesigner/itemLibrary/quick3d_particles3d.metainfo index c988cc49dc4..459097c4e58 100644 --- a/share/qtcreator/qmldesigner/itemLibrary/quick3d_particles3d.metainfo +++ b/share/qtcreator/qmldesigner/itemLibrary/quick3d_particles3d.metainfo @@ -418,7 +418,7 @@ MetaInfo { libraryIcon: "images/particle-system-24px.png" version: "6.2" requiredImport: "QtQuick3D.Particles3D" - QmlSource { source: "./source/particleeffect_rainmist.qml" } + QmlSource { source: "source/particleeffect_rainmist.qml" } ExtraFile { source: "images/smoke2.png" } } ItemLibraryEntry { diff --git a/share/qtcreator/qmldesigner/itemLibrary/source/component.qml b/share/qtcreator/qmldesigner/itemLibrary/source/component.qml new file mode 100644 index 00000000000..282a96b0f3f --- /dev/null +++ b/share/qtcreator/qmldesigner/itemLibrary/source/component.qml @@ -0,0 +1,12 @@ +// Copyright (C) 2021 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +import QtQuick + +Component { + Item { + id: componentRoot + width: 100 + height: 100 + } +} diff --git a/share/qtcreator/qmldesigner/itemLibrary/source/component3d.qml b/share/qtcreator/qmldesigner/itemLibrary/source/component3d.qml new file mode 100644 index 00000000000..76b6a357dfc --- /dev/null +++ b/share/qtcreator/qmldesigner/itemLibrary/source/component3d.qml @@ -0,0 +1,11 @@ +// Copyright (C) 2021 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +import QtQuick +import QtQuick3D + +Component { + Node { + id: componentRoot + } +} diff --git a/share/qtcreator/qmldesigner/itemLibrary/source/gridview.qml b/share/qtcreator/qmldesigner/itemLibrary/source/gridview.qml new file mode 100644 index 00000000000..e4f5988f6aa --- /dev/null +++ b/share/qtcreator/qmldesigner/itemLibrary/source/gridview.qml @@ -0,0 +1,61 @@ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +import QtQuick + +GridView { + width: 140 + height: 140 + cellWidth: 70 + cellHeight: 70 + + model: ListModel { + + ListElement { + name: "Grey" + colorCode: "grey" + + } + + ListElement { + name: "Red" + colorCode: "red" + + } + + ListElement { + name: "Blue" + colorCode: "blue" + + } + + ListElement { + name: "Green" + colorCode: "green" + + } + } + + delegate: Item { + height: 50 + x: 5 + + Column { + spacing: 5 + Rectangle { + width: 40 + height: 40 + color: colorCode + anchors.horizontalCenter: parent.horizontalCenter + } + + Text { + x: 5 + text: name + anchors.horizontalCenter: parent.horizontalCenter + font.bold: true + } + + } + } +} diff --git a/share/qtcreator/qmldesigner/itemLibrary/source/listview.qml b/share/qtcreator/qmldesigner/itemLibrary/source/listview.qml new file mode 100644 index 00000000000..7782ac5e123 --- /dev/null +++ b/share/qtcreator/qmldesigner/itemLibrary/source/listview.qml @@ -0,0 +1,41 @@ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +import QtQuick + +ListView { + width: 160 + height: 80 + model: ListModel { + ListElement { + name: "Red" + colorCode: "red" + } + ListElement { + name: "Green" + colorCode: "green" + } + ListElement { + name: "Blue" + colorCode: "blue" + } + ListElement { + name: "White" + colorCode: "white" + } + } + + delegate: Row { + spacing: 5 + Rectangle { + width: 100 + height: 20 + color: colorCode + } + + Text { + width: 100 + text: name + } + } +} diff --git a/share/qtcreator/qmldesigner/itemLibrary/source/pathview.qml b/share/qtcreator/qmldesigner/itemLibrary/source/pathview.qml new file mode 100644 index 00000000000..74fb7e3b985 --- /dev/null +++ b/share/qtcreator/qmldesigner/itemLibrary/source/pathview.qml @@ -0,0 +1,50 @@ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0 + +import QtQuick + +PathView { + width: 250 + height: 130 + + path: Path { + startX: 120 + startY: 100 + PathQuad { x: 120; y: 25; controlX: 260; controlY: 75 } + PathQuad { x: 120; y: 100; controlX: -20; controlY: 75 } + } + model: ListModel { + ListElement { + name: "Grey" + colorCode: "grey" + } + ListElement { + name: "Red" + colorCode: "red" + } + ListElement { + name: "Blue" + colorCode: "blue" + } + ListElement { + name: "Green" + colorCode: "green" + } + } + delegate: Column { + spacing: 5 + Rectangle { + width: 40 + height: 40 + color: colorCode + anchors.horizontalCenter: parent.horizontalCenter + } + Text { + x: 5 + text: name + anchors.horizontalCenter: parent.horizontalCenter + font.bold: true + } + } +} +