Button.ImageSource stretch the image on Windows, respect the original image size on Android
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 23.3k
- Forks
- 2k
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 296
Description
### Description
I suppose the expected behavior is to keep the original image size, so the bug is on windows.
### Steps to Reproduce
Add a button with an ImageSource.
On Windows the image is streatched, on Android the image has its original dimensions.
### Link to public reproduction project repository
https://github.com/rmotta01/MauiBugBtnImgSource01
### Version with bug
7.0 (current)
### Last version that worked well
Unknown/Other
### Affected platforms
Windows
### Affected platform versions
windows10.0.19041.0
### Did you find any workaround?
Add a button with an ImageSource.
On Windows the image is stretched, on Android the image has its original dimensions.
### Relevant log output
_No response_
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the linked public reproduction project and compare the Button ImageSource behavior on Windows and Android. The work is done when the Windows button preserves the image's original dimensions consistently with Android.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, csharp
- Domain
- desktop, frontend, mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100