Debian Codegraph @

src/qml/CGroupBox.qml

raw
1 // SPDX-License-Identifier: GPL-3.0-or-later
2 // Copyright 2019 Juan Palacios <[email protected]>
3
4 import QtQuick 2.15
5 import QtQuick.Controls 2.15
6 import "Style.js" as Style
7
8 GroupBox {
9 id: control
10
11 property alias showLine: bg.visible
12
13 label: Label {
14 text: control.title
15 font.pointSize: Style.GroupBox.text_size
16 font.bold: Style.GroupBox.text_bold
17 width: control.width
18 horizontalAlignment: Text.AlignHCenter
19 y: control.padding / 2
20 }
21
22 background: Rectangle {
23 id: bg
24
25 color: Style.GroupBox.background
26 border.color: enabled ? Style.GroupBox.border_color
27 : Style.GroupBox.border_color_alt
28 radius: Style.GroupBox.radius
29 }
30 }