diff --git a/share/qtcreator/qmldesigner/landingpage/content/App.qml b/share/qtcreator/qmldesigner/landingpage/content/App.qml new file mode 100644 index 00000000000..1a5e1efe05e --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/App.qml @@ -0,0 +1,62 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick Studio Components. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import QtQuick.Window 2.15 + +Item { + width: 1024 + height: 768 + + visible: true + property alias qtVersion: mainScreen.qtVersion + property alias qdsVersion: mainScreen.qdsVersion + property alias cmakeLists: mainScreen.cmakeLists + property alias qdsInstalled: mainScreen.qdsInstalled + property alias projectFileExists: mainScreen.projectFileExists + property alias rememberSelection: mainScreen.rememberCheckboxCheckState + + signal openQtc(bool rememberSelection) + signal openQds(bool rememberSelection) + signal installQds() + signal generateCmake() + signal generateProjectFile() + + Screen01 { + id: mainScreen + anchors.fill: parent + openQtcButton.onClicked: openQtc(rememberSelection === Qt.Checked) + openQdsButton.onClicked: openQds(rememberSelection === Qt.Checked) + installButton.onClicked: installQds() + generateCmakeButton.onClicked: generateCmake() + generateProjectFileButton.onClicked: generateProjectFile() + } + +} + diff --git a/share/qtcreator/qmldesigner/landingpage/content/InstallQdsStatusBlock.ui.qml b/share/qtcreator/qmldesigner/landingpage/content/InstallQdsStatusBlock.ui.qml new file mode 100644 index 00000000000..4132d62b200 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/InstallQdsStatusBlock.ui.qml @@ -0,0 +1,77 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick Studio Components. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +/* +This is a UI file (.ui.qml) that is intended to be edited in Qt Design Studio only. +It is supposed to be strictly declarative and only uses a subset of QML. If you edit +this file manually, you might introduce QML code that is not supported by Qt Design Studio. +Check out https://doc.qt.io/qtcreator/creator-quick-ui-forms.html for details on .ui.qml files. +*/ +import QtQuick 2.15 +import QtQuick.Controls 2.15 +import LandingPage + +Rectangle { + id: installQdsBlock + color: "#c3c3c3" + border.width: 0 + property alias installQdsBlockVisible: installQdsBlock.visible + property alias installButton: installButton + height: 200 + + Text { + id: statusText + text: qsTr("No Qt Design Studio installation found") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + anchors.topMargin: 10 + anchors.horizontalCenter: parent.horizontalCenter + } + + Text { + id: suggestionText + text: qsTr("Would you like to install it now?") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: statusText.bottom + anchors.topMargin: 10 + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + + PushButton { + id: installButton + anchors.top: suggestionText.bottom + text: "Install" + anchors.topMargin: Constants.buttonDefaultMargin + anchors.horizontalCenterOffset: 0 + anchors.horizontalCenter: parent.horizontalCenter + } +} diff --git a/share/qtcreator/qmldesigner/landingpage/content/LandingSeparator.qml b/share/qtcreator/qmldesigner/landingpage/content/LandingSeparator.qml new file mode 100644 index 00000000000..41dda25cd3d --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/LandingSeparator.qml @@ -0,0 +1,39 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick Studio Components. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.15 +import QtQuick.Controls 2.15 + +Rectangle { + color: "#313131" + width: parent.width + height: 2 + z: 10 + anchors.horizontalCenter: parent.horizontalCenter +} diff --git a/share/qtcreator/qmldesigner/landingpage/content/ProjectInfoStatusBlock.ui.qml b/share/qtcreator/qmldesigner/landingpage/content/ProjectInfoStatusBlock.ui.qml new file mode 100644 index 00000000000..2ee64e0f397 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/ProjectInfoStatusBlock.ui.qml @@ -0,0 +1,204 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick Studio Components. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +/* +This is a UI file (.ui.qml) that is intended to be edited in Qt Design Studio only. +It is supposed to be strictly declarative and only uses a subset of QML. If you edit +this file manually, you might introduce QML code that is not supported by Qt Design Studio. +Check out https://doc.qt.io/qtcreator/creator-quick-ui-forms.html for details on .ui.qml files. +*/ +import QtQuick 2.15 +import QtQuick.Controls 2.15 +import LandingPage + +Rectangle { + id: projectInfo + height: 300 + color: "#c3c3c3" + border.color: "#ffffff" + border.width: 0 + property bool qdsInstalled: qdsVersionText.text.length > 0 + property bool projectFileExists: false + property string qdsVersion: "UNKNOWN" + property string qtVersion: "UNKNOWN" + property alias cmakeListText: cmakeList.text + property alias generateCmakeButton: generateCmakeButton + property alias generateProjectFileButton: generateProjectFileButton + + Item { + id: projectFileInfoBox + width: projectInfo.width + height: 150 + anchors.top: parent.top + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 30 + + Text { + id: projectFileInfoTitle + text: qsTr("QML PROJECT FILE INFO") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 10 + } + + Item { + id: projectFileInfoVersionBox + width: parent.width + height: 150 + visible: projectFileExists + anchors.top: projectFileInfoTitle.bottom + anchors.topMargin: 0 + anchors.horizontalCenter: parent.horizontalCenter + + Text { + id: qtVersionText + text: qsTr("Qt Version - ") + qtVersion + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 10 + } + + Text { + id: qdsVersionText + text: qsTr("Qt Design Studio Version - ") + qdsVersion + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: qtVersionText.bottom + horizontalAlignment: Text.AlignHCenter + anchors.topMargin: 10 + anchors.horizontalCenter: parent.horizontalCenter + } + } + + Item { + id: projectFileInfoMissingBox + width: parent.width + height: 200 + visible: !projectFileInfoVersionBox.visible + anchors.top: projectFileInfoTitle.bottom + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 0 + + Text { + id: projectFileInfoMissingText + text: qsTr("No QML project file found - Would you like to create one?") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 10 + } + + PushButton { + id: generateProjectFileButton + anchors.top: projectFileInfoMissingText.bottom + text: "Generate" + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: Constants.buttonDefaultMargin + } + } + } + + Item { + id: cmakeInfoBox + width: projectInfo.width + height: 200 + anchors.top: projectFileInfoBox.bottom + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 40 + + Text { + id: cmakeInfoTitle + text: qsTr("CMAKE RESOURCE FILES") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 10 + } + + Item { + id: cmakeListBox + width: 150 + height: 40 + visible: cmakeListText.length > 0 + anchors.top: cmakeInfoTitle.bottom + anchors.topMargin: 10 + anchors.horizontalCenter: parent.horizontalCenter + + Text { + id: cmakeList + text: qsTr("") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.topMargin: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + } + + Item { + id: cmakeMissingBox + width: cmakeInfoBox.width + height: 200 + visible: cmakeListText.length === 0 + anchors.top: cmakeInfoTitle.bottom + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: 10 + + Text { + id: cmakeMissingText + text: qsTr("No resource files found - Would you like to generate them?") + font.family: "TitilliumWeb" + font.pixelSize: 18 + anchors.top: parent.top + horizontalAlignment: Text.AlignHCenter + anchors.topMargin: 10 + anchors.horizontalCenter: parent.horizontalCenter + } + + PushButton { + id: generateCmakeButton + anchors.top: cmakeMissingText.bottom + text: "Generate" + anchors.topMargin: Constants.buttonDefaultMargin + anchors.horizontalCenter: parent.horizontalCenter + } + } + } +} diff --git a/share/qtcreator/qmldesigner/landingpage/content/PushButton.ui.qml b/share/qtcreator/qmldesigner/landingpage/content/PushButton.ui.qml new file mode 100644 index 00000000000..63bb38565f6 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/PushButton.ui.qml @@ -0,0 +1,126 @@ + + +/**************************************************************************** +** +** Copyright (C) 2021 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Creator. +** +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +****************************************************************************/ +import QtQuick 2.15 +import QtQuick.Templates 2.15 + +Button { + id: control + + implicitWidth: Math.max( + buttonBackground ? buttonBackground.implicitWidth : 0, + textItem.implicitWidth + leftPadding + rightPadding) + implicitHeight: Math.max( + buttonBackground ? buttonBackground.implicitHeight : 0, + textItem.implicitHeight + topPadding + bottomPadding) + leftPadding: 4 + rightPadding: 4 + + text: "My Button" + property alias fontpixelSize: textItem.font.pixelSize + property bool forceHover: false + state: "normal" + + background: buttonBackground + Rectangle { + id: buttonBackground + color: "#00000000" + implicitWidth: 100 + implicitHeight: 40 + opacity: enabled ? 1 : 0.3 + radius: 2 + border.color: "#047eff" + anchors.fill: parent + } + + contentItem: textItem + + Text { + id: textItem + text: control.text + font.pixelSize: 18 + + opacity: enabled ? 1.0 : 0.3 + color: "#ffffff" + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + rightPadding: 5 + leftPadding: 5 + } + + states: [ + State { + name: "normal" + when: !control.down && !control.hovered && !control.forceHover + + PropertyChanges { + target: buttonBackground + color: "#323232" + border.color: "#868686" + } + + PropertyChanges { + target: textItem + color: "#ffffff" + } + }, + State { + name: "hover" + when: (control.hovered || control.forceHover) && !control.down + PropertyChanges { + target: textItem + color: "#ffffff" + } + + PropertyChanges { + target: buttonBackground + color: "#474747" + border.color: "#adadad" + } + }, + State { + name: "activeQds" + when: control.down + PropertyChanges { + target: textItem + color: "#111111" + } + + PropertyChanges { + target: buttonBackground + color: "#2e769e" + border.color: "#2e769e" + } + } + ] +} + +/*##^## +Designer { + D{i:0;height:40;width:142} +} +##^##*/ + diff --git a/share/qtcreator/qmldesigner/landingpage/content/Screen01.ui.qml b/share/qtcreator/qmldesigner/landingpage/content/Screen01.ui.qml new file mode 100644 index 00000000000..e54a5d058b9 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/content/Screen01.ui.qml @@ -0,0 +1,199 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Quick Studio Components. +** +** $QT_BEGIN_LICENSE:GPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 or (at your option) any later version +** approved by the KDE Free Qt Foundation. The licenses are as published by +** the Free Software Foundation and appearing in the file LICENSE.GPL3 +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +/* +This is a UI file (.ui.qml) that is intended to be edited in Qt Design Studio only. +It is supposed to be strictly declarative and only uses a subset of QML. If you edit +this file manually, you might introduce QML code that is not supported by Qt Design Studio. +Check out https://doc.qt.io/qtcreator/creator-quick-ui-forms.html for details on .ui.qml files. +*/ +import QtQuick 2.15 +import QtQuick.Controls 6.2 +import LandingPage + +Rectangle { + id: rectangle2 + width: 1024 + height: 768 + color: "#c3c3c3" + property bool qdsInstalled: true + property alias openQtcButton: openQtc + property alias openQdsButton: openQds + property alias projectFileExists: projectInfoStatusBlock.projectFileExists + property alias installButton: installQdsStatusBlock.installButton + property alias generateCmakeButton: projectInfoStatusBlock.generateCmakeButton + property alias generateProjectFileButton: projectInfoStatusBlock.generateProjectFileButton + property alias qtVersion: projectInfoStatusBlock.qtVersion + property alias qdsVersion: projectInfoStatusBlock.qdsVersion + property alias cmakeLists: projectInfoStatusBlock.cmakeListText + property alias installQdsBlockVisible: installQdsStatusBlock.visible + property alias rememberCheckboxCheckState: rememberCheckbox.checkState + + Rectangle { + id: logoArea + width: parent.width + height: 180 + color: "#c3c3c3" + anchors.top: parent.top + anchors.horizontalCenter: parent.horizontalCenter + + Image { + id: qdsLogo + source: "logo.png" + anchors.horizontalCenter: parent.horizontalCenter + anchors.top: parent.top + anchors.topMargin: 30 + } + + Text { + id: qdsText + text: qsTr("Qt Design Studio") + font.pixelSize: 55 + font.family: "TitilliumWeb" + anchors.horizontalCenter: parent.horizontalCenter + anchors.bottom: parent.bottom + anchors.bottomMargin: 20 + } + } + + Item { + id: statusBox + anchors.top: logoArea.bottom + anchors.bottom: buttonBox.top + anchors.left: parent.left + anchors.right: parent.right + anchors.rightMargin: 0 + anchors.leftMargin: 0 + + LandingSeparator { + id: topSeparator + anchors.top: parent.top + anchors.horizontalCenter: parent.horizontalCenter + } + + InstallQdsStatusBlock { + id: installQdsStatusBlock + width: parent.width + anchors.top: parent.top + anchors.topMargin: 0 + anchors.horizontalCenter: parent.horizontalCenter + visible: !qdsInstalled + } + + ProjectInfoStatusBlock { + id: projectInfoStatusBlock + width: parent.width + visible: !installQdsStatusBlock.visible + anchors.top: parent.top + anchors.topMargin: 0 + anchors.horizontalCenter: parent.horizontalCenter + } + + LandingSeparator { + id: bottomSeparator + anchors.bottom: parent.bottom + anchors.horizontalCenter: parent.horizontalCenter + } + } + + Rectangle { + id: buttonBox + width: parent.width + height: 220 + anchors.bottom: parent.bottom + anchors.horizontalCenter: parent.horizontalCenter + color: "#c3c3c3" + + Item { + id: openQdsBox + width: parent.width / 2 + height: parent.height + anchors.left: parent.left + anchors.bottom: parent.bottom + anchors.bottomMargin: 0 + anchors.leftMargin: 0 + + Text { + id: openQdsText + text: qsTr("Open with Qt Design Studio") + font.pixelSize: 22 + font.family: "TitilliumWeb" + anchors.horizontalCenter: parent.horizontalCenter + anchors.top: parent.top + anchors.topMargin: 50 + } + + PushButton { + id: openQds + anchors.top: openQdsText.bottom + anchors.horizontalCenter: parent.horizontalCenter + text: "Open" + anchors.topMargin: Constants.buttonSmallMargin + enabled: qdsInstalled + } + } + + Item { + id: openQtcBox + width: parent.width / 2 + height: parent.height + anchors.right: parent.right + anchors.bottom: parent.bottom + anchors.bottomMargin: 0 + anchors.rightMargin: 0 + + Text { + id: openQtcText + text: qsTr("Open with Qt Creator - Text Mode") + font.pixelSize: 22 + font.family: "TitilliumWeb" + anchors.horizontalCenter: parent.horizontalCenter + anchors.top: parent.top + anchors.topMargin: 50 + } + + PushButton { + id: openQtc + anchors.top: openQtcText.bottom + anchors.horizontalCenter: parent.horizontalCenter + anchors.topMargin: Constants.buttonSmallMargin + text: "Open" + } + } + + CheckBox { + id: rememberCheckbox + text: qsTr("Remember my choice") + font.family: "TitilliumWeb" + anchors.bottom: parent.bottom + anchors.bottomMargin: 30 + anchors.horizontalCenter: parent.horizontalCenter + } + } +} diff --git a/share/qtcreator/qmldesigner/landingpage/content/logo.png b/share/qtcreator/qmldesigner/landingpage/content/logo.png new file mode 100644 index 00000000000..e4cf99cfa9b Binary files /dev/null and b/share/qtcreator/qmldesigner/landingpage/content/logo.png differ diff --git a/share/qtcreator/qmldesigner/landingpage/content/logo@2x.png b/share/qtcreator/qmldesigner/landingpage/content/logo@2x.png new file mode 100644 index 00000000000..4c39c4ff737 Binary files /dev/null and b/share/qtcreator/qmldesigner/landingpage/content/logo@2x.png differ diff --git a/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/Constants.qml b/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/Constants.qml new file mode 100644 index 00000000000..e3f9067f8b3 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/Constants.qml @@ -0,0 +1,32 @@ +/**************************************************************************** +** +** Copyright (C) 2022 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ +** +** This file is part of Qt Creator. +** +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. +** +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. +** +****************************************************************************/ + +pragma Singleton +import QtQuick 2.10 + +QtObject { + readonly property int buttonDefaultMargin: 30 + readonly property int buttonSmallMargin: 20 +} diff --git a/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/qmldir b/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/qmldir new file mode 100644 index 00000000000..616ac203530 --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/imports/LandingPage/qmldir @@ -0,0 +1 @@ +singleton Constants 1.0 Constants.qml diff --git a/share/qtcreator/qmldesigner/landingpage/landingpage.qmlproject b/share/qtcreator/qmldesigner/landingpage/landingpage.qmlproject new file mode 100644 index 00000000000..54915a68ddb --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/landingpage.qmlproject @@ -0,0 +1,79 @@ +import QmlProject 1.1 + +Project { + mainFile: "content/App.qml" + + /* Include .qml, .js, and image files from current directory and subdirectories */ + QmlFiles { + directory: "content" + } + + QmlFiles { + directory: "imports" + } + + JavaScriptFiles { + directory: "content" + } + + JavaScriptFiles { + directory: "imports" + } + + ImageFiles { + directory: "content" + } + + Files { + filter: "*.conf" + files: ["qtquickcontrols2.conf"] + } + + Files { + filter: "qmldir" + directory: "." + } + + Files { + filter: "*.ttf;*.otf" + } + + Files { + filter: "*.wav;*.mp3" + } + + Files { + filter: "*.mp4" + } + + Files { + filter: "*.glsl;*.glslv;*.glslf;*.vsh;*.fsh;*.vert;*.frag" + } + + Files { + filter: "*.mesh" + directory: "asset_imports" + } + + Environment { + QT_QUICK_CONTROLS_CONF: "qtquickcontrols2.conf" + QT_AUTO_SCREEN_SCALE_FACTOR: "1" + QMLSCENE_CORE_PROFILE: "true" // Required for macOS, but can create issues on embedded Linux + QT_LOGGING_RULES: "qt.qml.connections=false" + QT_ENABLE_HIGHDPI_SCALING: "0" + /* Useful for debugging + QSG_VISUALIZE=batches + QSG_VISUALIZE=clip + QSG_VISUALIZE=changes + QSG_VISUALIZE=overdraw + */ + } + + + /* List of plugin directories passed to QML runtime */ + importPaths: [ "imports", "../../../../share/3rdparty/studiofonts" ] + + qt6Project: true + + qdsVersion: "3.2" +} diff --git a/share/qtcreator/qmldesigner/landingpage/main.qml b/share/qtcreator/qmldesigner/landingpage/main.qml new file mode 100644 index 00000000000..0e6d3dfb3cd --- /dev/null +++ b/share/qtcreator/qmldesigner/landingpage/main.qml @@ -0,0 +1,9 @@ +/* This file is generated and only relevant for integrating the project into a Qt 6 and cmake based +C++ project. */ + +import QtQuick +import "content" + +App { + +}