2020-05-19 19:49:52 +00:00
|
|
|
import QtGraphicalEffects 1.0
|
|
|
|
import QtQuick 2.7
|
|
|
|
import QtQuick.Controls 2.4
|
|
|
|
import QtQuick.Controls.Material 2.0
|
|
|
|
import QtQuick.Layouts 1.3
|
|
|
|
import QtQuick.Window 2.11
|
2020-05-20 02:26:58 +00:00
|
|
|
import "theme"
|
2020-10-19 22:20:38 +00:00
|
|
|
import "fonts"
|
2020-05-19 19:49:52 +00:00
|
|
|
|
2020-12-15 01:16:49 +00:00
|
|
|
// Defaults to normal size text. doesn't do its own padding!
|
|
|
|
// Setting header:true switches to header sized and bolded text
|
2020-05-19 19:49:52 +00:00
|
|
|
Label {
|
2020-12-15 01:16:49 +00:00
|
|
|
font.pointSize: size
|
|
|
|
wrapMode: multiline ? Text.WordWrap : Text.NoWrap
|
|
|
|
elide: Text.ElideRight
|
2020-05-20 02:26:58 +00:00
|
|
|
color: Theme.mainTextColor
|
2020-05-19 19:49:52 +00:00
|
|
|
textFormat: Text.PlainText
|
2020-12-15 01:16:49 +00:00
|
|
|
property bool header: false
|
|
|
|
property real size: header ? Theme.textHeaderPt : Theme.textMediumPt
|
|
|
|
property bool bold: header
|
|
|
|
property bool multiline: true
|
2020-10-19 22:20:38 +00:00
|
|
|
|
|
|
|
font.family: bold ? Fonts.applicationFontRegular.name : Fonts.applicationFontBold.name
|
|
|
|
font.styleName: bold ? "Bold" : ""
|
2020-05-19 19:49:52 +00:00
|
|
|
}
|