У меня есть простой дизайн QML, который состоит из двух компонентов, расположенных рядом, а затем еще одного компонента (называемого HUD).HUD должен заполнить оставшуюся высоту, но вместо этого он оставляет зазор.
Как я могу заставить HUD заполнить всю доступную ширину.Я пытаюсь добиться второго изображения.
Page {
width: parent.width
height: parent.height
title: qsTr("Home")
ColumnLayout {
anchors.fill: parent
RowLayout {
Layout.fillWidth: true;
StatusBar {
width: parent.width * 0.5;
height: parent.height * 0.1
anchors.left: parent.left;
}
MenuBar {
width: parent.width * 0.5;
height: parent.height * 0.1
anchors.right: parent.right;
}
}
// The below should fill the remaining height but its not?
HUD {
Layout.fillWidth: true;
Layout.fillHeight: true;
}
}
}