mirror of
https://github.com/alicevision/Meshroom.git
synced 2025-08-06 10:18:42 +02:00
[AttributePin] Add tooltip to display type of attribute
This commit is contained in:
parent
9c33c57305
commit
de5ca552f7
2 changed files with 7 additions and 2 deletions
|
@ -33,7 +33,7 @@ RowLayout {
|
||||||
var tooltip = ""
|
var tooltip = ""
|
||||||
if (!attribute.validValue && attribute.desc.errorMessage !== "")
|
if (!attribute.validValue && attribute.desc.errorMessage !== "")
|
||||||
tooltip += "<i><b>Error: </b>" + Format.plainToHtml(attribute.desc.errorMessage) + "</i><br><br>"
|
tooltip += "<i><b>Error: </b>" + Format.plainToHtml(attribute.desc.errorMessage) + "</i><br><br>"
|
||||||
tooltip += "<b> " + attribute.desc.name + "</b><br>" + Format.plainToHtml(attribute.desc.description)
|
tooltip += "<b> " + attribute.desc.name + ": " + attribute.type + "</b><br>" + Format.plainToHtml(attribute.desc.description)
|
||||||
|
|
||||||
parameterTooltip.text = tooltip
|
parameterTooltip.text = tooltip
|
||||||
}
|
}
|
||||||
|
@ -78,7 +78,7 @@ RowLayout {
|
||||||
var tooltip = ""
|
var tooltip = ""
|
||||||
if (!object.validValue && object.desc.errorMessage !== "")
|
if (!object.validValue && object.desc.errorMessage !== "")
|
||||||
tooltip += "<i><b>Error: </b>" + Format.plainToHtml(object.desc.errorMessage) + "</i><br><br>"
|
tooltip += "<i><b>Error: </b>" + Format.plainToHtml(object.desc.errorMessage) + "</i><br><br>"
|
||||||
tooltip += "<b>" + object.desc.name + "</b><br>" + Format.plainToHtml(object.description)
|
tooltip += "<b>" + object.desc.name + ": " + attribute.type + "</b><br>" + Format.plainToHtml(object.description)
|
||||||
return tooltip
|
return tooltip
|
||||||
}
|
}
|
||||||
visible: parameterMA.containsMouse
|
visible: parameterMA.containsMouse
|
||||||
|
|
|
@ -35,6 +35,11 @@ RowLayout {
|
||||||
layoutDirection: Qt.LeftToRight
|
layoutDirection: Qt.LeftToRight
|
||||||
spacing: 3
|
spacing: 3
|
||||||
|
|
||||||
|
ToolTip.text: attribute.name + ": " + attribute.type
|
||||||
|
ToolTip.visible: nameLabel.hovered
|
||||||
|
ToolTip.toolTip.y: nameLabel.y + nameLabel.height
|
||||||
|
ToolTip.toolTip.x: nameLabel.x
|
||||||
|
|
||||||
function updatePin(isSrc, isVisible)
|
function updatePin(isSrc, isVisible)
|
||||||
{
|
{
|
||||||
if (isSrc) {
|
if (isSrc) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue