-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
WrapPanel ignores Right Padding value of Parent #3257
Comments
Hello michael-hawker, thank you for opening an issue with us! I have automatically added a "needs triage" label to help get things started. Our team will analyze and investigate the issue, and escalate it to the relevant team if possible. Other community members may also look into the issue and provide feedback 🙌 |
This appears to be an issue with how the scrollviewer is setup. Panels have no knowledge of the parent ItemsControl Padding. Only their own Padding |
@skendrot this works fine in the default ListView setup with ItemsStackPanel, so it's doing something special. I mean it may just be reaching up for padding info, but I figured I'd start here and ask the WinUI folks. |
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established. |
@ranjeshj can you provide any insights into what makes ItemsStackPanel special in this case for it to respect the padding value of its parent? Does it walk the visual tree or something or is it just tightly coupled somehow to when it's in a ListView? |
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established. |
Sorry.
Very likely. I would not be surprised at all if ItemsStackPanel walks up the tree to do this. |
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established. |
1 similar comment
This issue has been marked as "needs attention 👋" due to no activity for 15 days. Please triage the issue so the fix can be established. |
This still sounds like a core bug. Panels shouldn't need to walk up a visual tree to determine the parent's padding. The size given to the panel in the measure method should be the available space |
Describe the bug
WrapPanel doesn't respect the parent padding when in a ListView.
Steps to Reproduce
Steps to reproduce the behavior:
Expected behavior
Padding to be respected on Right-side of ListView as well.
Screenshots
Environment
Sample App
Additional context
This definitely appears to be some sort of behavior with ListView, as an ItemsStackPanel behaves fine. It must be doing something special in order to grab the padding from it's parent container. We should sync with the WinUI team on this. FYI @ranjeshj
We can see this with just a regular StackPanel as well like this:
The text was updated successfully, but these errors were encountered: