wpf icon indicating copy to clipboard operation
wpf copied to clipboard

Fluent2 TabItem MinWidth Is Too Large

Open robert-abeo opened this issue 1 year ago • 0 comments

Description

A MinWidth for TabItem of 180 is far too large for the Fluent theme. Remember WinUI doesn't have a TabControl, it has a TabView with page tabs that can be torn off and re-ordered, etc. It's a different design/use-case.

For existing WPF apps a MinWidth of 180 breaks the UI and requires re-templating.

Reproduction Steps

https://github.com/dotnet/wpf/blob/673c35418e5416e486e6651b69b89712a36fcf5c/src/Microsoft.DotNet.Wpf/src/Themes/PresentationFramework.Fluent/Styles/TabControl.xaml#L228

Expected behavior

  1. The MinWidth should be much smaller -- in fact removing it is better
  2. There needs to be a lightweight styling resource to set this without re-templating (if it stays)

Note that WinUI doesn't set a value at all here:

https://github.com/microsoft/microsoft-ui-xaml/blob/d74a0332cf0d5e58f12eddce1070fa7a79b4c2db/src/controls/dev/TabView/TabView.xaml#L296

Actual behavior

180 is hard-coded

Regression?

No response

Known Workarounds

No response

Impact

No response

Configuration

No response

Other information

No response

robert-abeo avatar Oct 03 '24 19:10 robert-abeo