C

Qt Quick Ultralite Motorcycle Cluster Demo

// Copyright (C) 2024 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial
import QtQuick 2.0

Item {
    id: root
    width: 500
    height: 44

    property alias text: txt.text
    property alias color: txt.color

    Text {
        id: txt
        anchors.horizontalCenter: inputTextBottomLine.horizontalCenter
        anchors.bottom: inputTextBottomLine.bottom
        anchors.bottomMargin: 6
        font.pixelSize: 34
    }

    Rectangle {
        id: inputTextBottomLine
        width: 500
        height: 2
        anchors.top: root.top
        anchors.topMargin: 42

        color: txt.color

        Rectangle {
            width: 2
            height: 8
            anchors.bottom: inputTextBottomLine.bottom
            anchors.left: inputTextBottomLine.left
            color: txt.color
         }

        Rectangle {
            width: 2
            height: 8
            anchors.bottom: inputTextBottomLine.bottom
            anchors.right: inputTextBottomLine.right
            color: txt.color
         }
    }
}