mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-20 02:29:08 +08:00
High-level layout of Marketplace window
Currently just a title and a page. The title is separate because in between there will be the tabs selecting which page is shown. The title will also change depending on that, but that'll have to be implemented separately. The page is loaded with a loader to make it efficient, and also to make it extensible when the tabs get implemented in a follow-up ticket. Contributes to issue CURA-8556.
This commit is contained in:
parent
8beac74417
commit
97edf59660
@ -2,6 +2,8 @@
|
|||||||
// Cura is released under the terms of the LGPLv3 or higher.
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.15
|
import QtQuick 2.15
|
||||||
|
import QtQuick.Controls 2.15
|
||||||
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window 2.2
|
import QtQuick.Window 2.2
|
||||||
|
|
||||||
import UM 1.2 as UM
|
import UM 1.2 as UM
|
||||||
@ -18,4 +20,35 @@ Window
|
|||||||
|
|
||||||
title: "Marketplace" //Seen by Ultimaker as a brand name, so this doesn't get translated.
|
title: "Marketplace" //Seen by Ultimaker as a brand name, so this doesn't get translated.
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
|
|
||||||
|
Rectangle //Background color.
|
||||||
|
{
|
||||||
|
anchors.fill: parent
|
||||||
|
color: UM.Theme.getColor("main_background")
|
||||||
|
|
||||||
|
ColumnLayout
|
||||||
|
{
|
||||||
|
anchors.fill: parent
|
||||||
|
anchors.margins: UM.Theme.getSize("default_margin").width
|
||||||
|
|
||||||
|
spacing: UM.Theme.getSize("default_margin").height
|
||||||
|
|
||||||
|
Label //Page title.
|
||||||
|
{
|
||||||
|
Layout.preferredWidth: parent.width
|
||||||
|
Layout.preferredHeight: contentHeight
|
||||||
|
|
||||||
|
font: UM.Theme.getFont("large")
|
||||||
|
color: UM.Theme.getColor("text")
|
||||||
|
text: catalog.i18nc("@header", "Install Plugins")
|
||||||
|
}
|
||||||
|
Loader //Page contents.
|
||||||
|
{
|
||||||
|
Layout.preferredWidth: parent.width
|
||||||
|
Layout.fillHeight: true
|
||||||
|
|
||||||
|
source: "Plugins.qml"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
9
plugins/Marketplace/resources/qml/Plugins.qml
Normal file
9
plugins/Marketplace/resources/qml/Plugins.qml
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
// Copyright (c) 2021 Ultimaker B.V.
|
||||||
|
// Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
|
import QtQuick 2.15
|
||||||
|
|
||||||
|
Rectangle
|
||||||
|
{
|
||||||
|
color: "pink" //TODO
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user