To align mark and the label vertically in a Legend#3206
Merged
j9ac9k merged 1 commit intopyqtgraph:masterfrom Jan 25, 2025
Merged
To align mark and the label vertically in a Legend#3206j9ac9k merged 1 commit intopyqtgraph:masterfrom
j9ac9k merged 1 commit intopyqtgraph:masterfrom
Conversation
ixjlyons
approved these changes
Jan 12, 2025
Member
There was a problem hiding this comment.
This seems reasonable enough to me.
I'll point out that making the label text really small gives the opposite issue where the sample dictates the row size and the text appears aligned to the top of the row, but setting AlignVCenter on the label doesn't fix it. I think this is fairly unlikely unless/until we make the sample size modifiable in some way rather than hard-coding 20 (i.e. it's not really noticeable until you get down to labelTextSize="6pt" or so).
Note this should also close #3027
Member
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.

This will solve #3199
ItemSamplehad zero width and height.This change sets width and height according to the
boundingRectand adjusts horizontal spacing accordingly.Besides, vertical alignment option has been given.
Fixes #3199
Fixes #3027