Merge pull request #2532 from alicevision/fix/descriptionAttributeTooltip

[AttributeItemDelegate] Position the attribute description tooltip
This commit is contained in:
Candice Bentéjac 2024-09-16 15:15:37 +02:00 committed by GitHub
commit ccd5f369e4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 10 additions and 4 deletions

View file

@ -74,6 +74,9 @@ RowLayout {
ToolTip { ToolTip {
id: parameterTooltip id: parameterTooltip
// Position in y at mouse position
y: parameterMA.mouseY + 10
text: { text: {
var tooltip = "" var tooltip = ""
if (!object.validValue && object.desc.errorMessage !== "") if (!object.validValue && object.desc.errorMessage !== "")

View file

@ -35,10 +35,13 @@ RowLayout {
layoutDirection: Qt.LeftToRight layoutDirection: Qt.LeftToRight
spacing: 3 spacing: 3
ToolTip.text: attribute.name + ": " + attribute.type ToolTip {
ToolTip.visible: nameLabel.hovered text: attribute.name + ": " + attribute.type
ToolTip.toolTip.y: nameLabel.y + nameLabel.height visible: nameLabel.hovered
ToolTip.toolTip.x: nameLabel.x
y: nameLabel.y + nameLabel.height
x: nameLabel.x
}
function updatePin(isSrc, isVisible) function updatePin(isSrc, isVisible)
{ {