Welcome to mirror list, hosted at ThFree Co, Russian Federation.

PrintCoreConfiguration.qml « ConfigurationMenu « Menus « qml « resources - github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 73fc342d6651cb81b7c20a5525ddbc9089160d0a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
// Copyright (c) 2018 Ultimaker B.V.
// Cura is released under the terms of the LGPLv3 or higher.

import QtQuick 2.7
import QtQuick.Controls 2.0

import UM 1.2 as UM


Column
{
    id: extruderInfo
    property var printCoreConfiguration
    property var mainColor: "black"
    spacing: Math.round(UM.Theme.getSize("default_margin").height / 2)

    height: childrenRect.height

    Item
    {
        id: extruder
        width: parent.width
        height: childrenRect.height

        Label
        {
            id: extruderLabel
            text: catalog.i18nc("@label:extruder label", "Extruder")
            renderType: Text.NativeRendering
            elide: Text.ElideRight
            anchors.left: parent.left
            font: UM.Theme.getFont("default")
            color: mainColor
        }

        // Rounded item to show the extruder number
        Item
        {
            id: extruderIconItem
            anchors.verticalCenter: extruderLabel.verticalCenter
            anchors.left: extruderLabel.right
            anchors.leftMargin: Math.round(UM.Theme.getSize("default_margin").width / 2)

            width: UM.Theme.getSize("section_icon").width
            height: UM.Theme.getSize("section_icon").height

            UM.RecolorImage {
                id: mainCircle
                anchors.fill: parent

                anchors.centerIn: parent
                sourceSize.width: parent.width
                sourceSize.height: parent.height
                source: UM.Theme.getIcon("extruder_button")
                color: mainColor
            }

            Label
            {
                id: extruderNumberText
                anchors.centerIn: parent
                text: printCoreConfiguration.position + 1
                renderType: Text.NativeRendering
                font: UM.Theme.getFont("default")
                color: mainColor
            }
        }
    }

    Label
    {
        id: materialLabel
        text: printCoreConfiguration.material == null ? "" : printCoreConfiguration.material.name
        renderType: Text.NativeRendering
        elide: Text.ElideRight
        width: parent.width
        font: UM.Theme.getFont("default_bold")
        color: mainColor
    }

    Label
    {
        id: printCoreTypeLabel
        text: printCoreConfiguration.hotendID
        renderType: Text.NativeRendering
        elide: Text.ElideRight
        width: parent.width
        font: UM.Theme.getFont("default")
        color: mainColor
    }
}