WPF Fluent Theme TextBox component in .NET 10 has different default height
Description
Hi,
we upgraded our WPF application (which is a WiX setup bootstrapper) from .NET 9 to .NET 10. We are using the fluent ui theme (ThemeMode="Dark").
We have seen that after the upgrade the TextBox heights have changed and the text is also not completely vertically centered anymore.
Was this change planned or is this for you also a bug?
Thanks in the meantime.
Reproduction Steps
With this XAML code, you should be able to reproduce the bug:
XAML code
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<TextBlock
Grid.Row="0"
TextWrapping="Wrap"
Text="Test:" />
<TextBox
Grid.Row="1"
Width="200"
HorizontalAlignment="Left"
Text="123" />
</Grid>
Expected behavior
I expect that the TextBox text is centered vertically. I also expect, when I change the height of the TextBox component to a smaller height than the default height, that the height I have set is applied correctly.
Compiled with .NET 9:
Actual behavior
Compiled with .NET 10:
Regression?
In .NET 9 it works for us, in .NET 10 not anymore.
Known Workarounds
Use .NET 9 instead.
Impact
Minimal.
Configuration
No response
Other information
No response
@eschgi we have changed the defaults of certain controls in .NET 10 to maintain consistency with other controls. This is a know by-product of the same.