Show truncated text in tooltips (#31908, #27891, #32159) [4.7.0]#32345
Draft
mathesoncalum wants to merge 6 commits intomusescore:4.7from
Draft
Show truncated text in tooltips (#31908, #27891, #32159) [4.7.0]#32345mathesoncalum wants to merge 6 commits intomusescore:4.7from
mathesoncalum wants to merge 6 commits intomusescore:4.7from
Conversation
This was
linked to
issues
Feb 23, 2026
mathesoncalum
commented
Feb 23, 2026
| font: ui.theme.bodyBoldFont | ||
| horizontalAlignment: Text.AlignLeft | ||
| wrapMode: Text.WordWrap | ||
| maximumLineCount: 2 |
Contributor
Author
There was a problem hiding this comment.
Alternatively we could accommodate blank titles and use the description text instead...
Eism
approved these changes
Mar 9, 2026
0657c25 to
fec651a
Compare
- CheckBox.qml - VisibilityBox.qml - InspectorPropertyView.qml - InstrumentsDialog.qml - NewScoreDialog.qml
…dialog and instruments dialog
fec651a to
0dcc46a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves: #31908
Resolves: #27891
Resolves: #32159
I was hoping to come up with a clean, general solution that works in all cases for this one but there are a few cases that require special treatment - usually when the
MouseAreafor aStyledTextLabeloverlaps with anotherMouseAreaunderneath.FlatButtonsare an example of this - allowing theStyledTextLabelto accept hover events here would result in it intercepting hover events for the button underneath (where we have theHOVEREDstate). So in this case you would need to integrate the "truncation" logic with the existingMouseArealogic for the button. The buttons in the sound flag popup actually add another layer of complexity since they supply their ownStyledTextLabelsthroughcontentItem. As a result, there isn't really a satisfying way to have theFlatButtonevaluate whether the text is truncated and perform the necessary tooltip logic.The solution for the sound flag popup proposed in this PR is quite simple - once the
contentItemis completed we'll set the button's tooltip title (if truncated). For most other cases we can use the newdisplayTruncatedTextOnHoverproperty. As mentioned previously, we should be careful not to steal hover events withStyledTextLabels. For this reason, the default value for this property is false - we can set it to true on a case-by-case basis.Important: 0657c25 is purely for testing purposes. It should be dropped from this PR before merging.