[X] I have searched the opened issues and there are no duplicates
Describe the bug
When I resize the window, the image shrinks only if I resize horizontally. If I add expand=True, the image shrinks also when I resize the window vertically. This happens with every control I've tried. Adding page.vertical_alignment = ft.MainAxisAlignment.CENTER centers the image an make it move when I resize, but still crops the image.
Code
```python
import flet as ft
def main(page: ft.Page):
page.window.height = 500
page.window.width = 500
a = ft.Image(
src='assets/img/x.png',
width=200,
height=200,
)
page.add(a)
ft.app(main, assets_dir='assets')
```
To reproduce
Try the code, then try the same adding expand=true, see the difference
Expected behavior
To resize the image when I resize the window vertically without expand. Or to NOT resize the image when I resize the windows horizontally without expand. So I expect to be consistent
Duplicate Check
Describe the bug
When I resize the window, the image shrinks only if I resize horizontally. If I add expand=True, the image shrinks also when I resize the window vertically. This happens with every control I've tried. Adding page.vertical_alignment = ft.MainAxisAlignment.CENTER centers the image an make it move when I resize, but still crops the image.
https://github.com/user-attachments/assets/cbcf4f22-5bcc-49a2-ad22-4888a3603e8c
Code sample
Code
```python import flet as ft def main(page: ft.Page): page.window.height = 500 page.window.width = 500 a = ft.Image( src='assets/img/x.png', width=200, height=200, ) page.add(a) ft.app(main, assets_dir='assets') ```To reproduce
Try the code, then try the same adding expand=true, see the difference
Expected behavior
To resize the image when I resize the window vertically without expand. Or to NOT resize the image when I resize the windows horizontally without expand. So I expect to be consistent
Screenshots / Videos
Captures
[Upload media here]Operating System
Windows
Operating system details
Windows 11
Flet version
0.23.2
Regression
I'm not sure / I don't know
Suggestions
No response
Logs
Logs
```console [Paste your logs here] ```Additional details
No response