summaryrefslogtreecommitdiffstats
path: root/examples/demos/stocqt/content/Banner.qml
blob: 43c8e3603078af216e3b02d6f2005bfc7a31b52e (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
// Copyright (C) 2017 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

import QtQuick
import QtQuick.Layouts

Rectangle {
    id: banner
    height: 80
    color: "#000000"

    GridLayout {
        anchors.fill: parent
        rows: 1
        columns: 3
        Rectangle {
            Layout.leftMargin: 10
            Layout.topMargin: 20
            Layout.alignment: Qt.AlignLeft | Qt.AlignTop
            Image {
                id: arrow
                source: "./images/icon-left-arrow.png"
                visible: root.currentIndex == 1 ? true : false

                MouseArea {
                    anchors.fill: parent
                    onClicked: root.currentIndex = 0;
                }
            }
        }
        Text {
            id: stocText
            color: "#ffffff"
            font.family: "Abel"
            font.pointSize: 40
            text: "Stoc"
            Layout.alignment: Qt.AlignRight
            Layout.leftMargin: parent.width / 2.5
        }
        Text {
            id: qtText
            color: "#5caa15"
            font.family: "Abel"
            font.pointSize: 40
            text: "Qt"
            Layout.fillWidth: true
        }
    }
}