2020-09-15 10:53:00 +00:00
|
|
|
import QtQuick 2.13
|
|
|
|
import QtQuick.Controls 2.13
|
|
|
|
import QtQuick.Layouts 1.13
|
2021-09-28 15:04:06 +00:00
|
|
|
|
|
|
|
import utils 1.0
|
2021-10-14 10:44:52 +00:00
|
|
|
import "../"
|
|
|
|
import "."
|
2020-09-15 10:53:00 +00:00
|
|
|
|
2021-10-14 10:44:52 +00:00
|
|
|
// TODO: use StatusQ components
|
2020-09-15 10:53:00 +00:00
|
|
|
Item {
|
|
|
|
id: root
|
|
|
|
property string name: ""
|
|
|
|
property string description: ""
|
|
|
|
property string letter: ""
|
|
|
|
height: glossaryEntryTitle.height + Style.current.smallPadding + glossaryEntryDescription.height
|
|
|
|
width: parent.width
|
|
|
|
|
|
|
|
GlossaryLetter {
|
|
|
|
id: glossaryLetter
|
|
|
|
text: root.letter
|
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.top: glossaryEntryTitle.top
|
|
|
|
visible: !!root.letter
|
|
|
|
}
|
|
|
|
|
|
|
|
StyledText {
|
|
|
|
id: glossaryEntryTitle
|
|
|
|
text: root.name
|
|
|
|
font.pixelSize: 17
|
|
|
|
color: Style.current.textColor
|
|
|
|
font.weight: Font.Bold
|
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.leftMargin: Style.current.bigPadding
|
|
|
|
}
|
|
|
|
|
|
|
|
StyledText {
|
|
|
|
id: glossaryEntryDescription
|
|
|
|
text: root.description
|
|
|
|
color: Style.current.textColor
|
|
|
|
font.pixelSize: 15
|
|
|
|
anchors.top: glossaryEntryTitle.bottom
|
|
|
|
anchors.topMargin: Style.current.smallPadding
|
|
|
|
anchors.left: parent.left
|
|
|
|
anchors.leftMargin: Style.current.bigPadding
|
|
|
|
anchors.right: parent.right
|
|
|
|
wrapMode: Text.WordWrap
|
|
|
|
}
|
|
|
|
}
|