Open drasticactions opened 1 year ago
This can also be replicated even with set widths inside of the grid.
Edit: Scratch that, I'm setting a color on a grid that is the full width, it better cover the whole thing! lol.
But the above should stand.
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.
Verified this issue with Visual Studio Enterprise 17.7.0 Preview 2.0. Can repro on windows and iOS platform with sample project.
https://github.com/drasticactions/MauiRepros/tree/main/MauiImageLayout
Description
For WinUI, Catalyst, and iOS, If you use an
Image
as a root element in aCollectionView
and set itsWidthRequest
, the width for the image is set, but the underlying frame seems not to be, taking up the entire width of the container. On Android, it respects the set width.I'm unsure if this is a bug or how images generally work on the platform. I can replicate this behavior by using
Where the underlying image breaks out of the grid, even though the grid is set to have a width and height. However, if I use
Then the width and height are respected on all platforms.
Steps to Reproduce
Link to public reproduction project repository
https://github.com/drasticactions/MauiRepros/tree/main/MauiImageLayout
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
iOS, Windows, macOS
Affected platform versions
Current Stable.
Did you find any workaround?
Wrap the image in a
Grid
and then set the Width and Height on the image itself.Relevant log output
No response