-
Notifications
You must be signed in to change notification settings - Fork 772
Add WrapPanel API Spec based on Windows Community Toolkit (WCT) #10858
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…ol for Public Review
|
How about changing |
Not sure I agree, as because "Lined" is in the name, the Line spacing makes more sense, and has context which does not exist with a wrap panel. |
This is discussed previously in AvaloniaUI/Avalonia#18079. I think |
You could do maybe Row spacing, and Item spacing, which may make sense, but HorizontalSpacing and VerticalSpacing is consistent with many other controls, and should still be relevant regardless of orientation. You could also have ItemHorizontalSpacing and ItemVerticalSpacing, which should also be agnostic regardless of the panel's Orientation. |
@mdtauk RowSpacing, and ItemSpacing, make more sense than H/V Spacing, but not as good as LineSpacing. If you set Orientation to Horizontal, the Line is a Column. And ItemHorizontalSpacing and ItemVerticalSpacing is a even worse naming than H/V spacing. First, it's tied to direction, causing confusion when switching Orientation. Second, the word
|
@mdtauk the current behavior of the WrapPanel (which is the same as it is in the Windows Community Toolkit) is that each row's height is calculated from the largest item in that row. You can see that with the random image sizes in the sample gallery:
So, I think that would cover your scenario? Unless I'm misunderstanding. But it should be called out within the spec somewhere on these expectations. |
|
@zxbmmmmmmmmm thanks to the link to the Avalonia discussion, that's useful context. I'll take a look. |





This PR adds the dev and functional spec for WinUI WrapPanel (from Windows Community Toolkit).
Community members can provide feedback by commenting directly on the PR, or through a code suggestion with GitHub tools.
Feedback should be constructive and specific, addressing potential use cases, design concerns, and functionality.
This PR will be open for feedback for a month: October 27th – November 27th
For more info on the public api review process: https://aka.ms/winappsdk/api-specs-review