Windows title bar size not changing when text size is changed for accessibility reasons #23980
Labels
area-controls-titlebar
platform/windows 🪟
s/triaged
Issue has been reviewed
s/verified
Verified / Reproducible Issue ready for Engineering Triage
t/bug
Something isn't working
Milestone
Description
I’m working on a MAUI application for Windows and I’m trying to set the top padding of a UI element so it does not overlap the titlebar. I’ve written a function to calculate the required padding on top, which I’ll provide below. The problem arises when I change the text size setting in Windows for accessibility reasons. While the default title bar of other applications adjusts correctly, the MAUI application’s title bar does not change in the same way. My function returns the correct height that matches the required padding for any default window other than the MAUI application.
My code for calculating the titlebar height
This function return 32 for normal text size and 51 on 225% Text Size setting which seem to match the default title bar height behavior.
If the text size is set to 100% the GitBash window I used as an example has the same title bar height as the test MAUI application.
But when I set the text size to 225% the GitBash window title bar adjusts, but the test application title bar height seems to be unchanged.
I checked this documentation : https://learn.microsoft.com/en-us/windows/apps/design/basics/titlebar-design#search and I see that the title bar height is 32 by default and with special elements it is 48. My question is if this is a settings issue or it is just not adjusting by default in MAUI? I could not find a setting that disables the default behavior. Thanks
Steps to Reproduce
Link to public reproduction project repository
No response
Version with bug
8.0.70 SR7
Is this a regression from previous behavior?
Not sure, did not test other versions
Last version that worked well
Unknown/Other
Affected platforms
Windows
Affected platform versions
No response
Did you find any workaround?
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered: