Menu items in Tablet UI now wrapped

This commit is contained in:
Vladyslav Stelmakhovskyi 2017-03-18 15:44:32 +01:00
parent d45266f28b
commit 5335bf8862

View file

@ -32,8 +32,7 @@ Item {
anchors {
left: parent.left
leftMargin: hifi.dimensions.menuPadding.x + 15
top: label.top
topMargin: 0
verticalCenter: label.verticalCenter
}
width: 20
visible: source.visible && source.type === 1 && source.checkable
@ -51,6 +50,8 @@ Item {
RalewaySemiBold {
id: label
size: 20
//wrap will work only if width is set
width: parent.width - (check.width + check.anchors.leftMargin) - tail.width
font.capitalization: isSubMenu ? Font.MixedCase : Font.AllUppercase
anchors.left: check.right
anchors.verticalCenter: parent.verticalCenter
@ -58,6 +59,7 @@ Item {
color: source.enabled ? hifi.colors.baseGrayShadow : hifi.colors.baseGrayShadow50
enabled: source.visible && (source.type !== 0 ? source.enabled : false)
visible: source.visible
wrapMode: Text.WordWrap
}
Item {