[ui] Viewer: use RowLayout instead of manual relative sizes

This commit is contained in:
Fabien Castan 2020-01-27 12:32:34 +01:00
parent fcdb3721c3
commit dabf19dae9

View file

@ -163,25 +163,31 @@ FocusScope {
height: depthMapNodeName.height+8 height: depthMapNodeName.height+8
radius: 0 radius: 0
padding: 4 padding: 4
// selectable filepath to source image
TextField { RowLayout {
width: parent.width-depthMapNodeName.width-5 anchors.fill: parent
padding: 0 // selectable filepath to source image
anchors.right: depthMapNodeName.left TextField {
anchors.rightMargin: 5 padding: 0
background: Item {} background: Item {}
font.pointSize: 8 horizontalAlignment: TextInput.AlignLeft
readOnly: true Layout.fillWidth: true
selectByMouse: true font.pointSize: 8
text: Filepath.urlToString(image.source) readOnly: true
} selectByMouse: true
// show which depthmap node is active text: Filepath.urlToString(image.source)
Label { }
id: depthMapNodeName // show which depthmap node is active
text: _reconstruction.depthMap.label Label {
anchors.right: parent.right id: depthMapNodeName
font.pointSize: 8 visible: imageType.type != "image"
visible: imageType.type != "image" text: _reconstruction.depthMap.label
font.pointSize: 8
horizontalAlignment: TextInput.AlignLeft
Layout.fillWidth: false
Layout.preferredWidth: contentWidth
}
} }
} }