Replies: 4 comments 6 replies
-
This was already well debated in WinUI. The consensus -- and the way WinUI works now-- is that the properties need to follow the Content property which is specially handled in XAML. If I set the content of an Expander and it goes below the header in the content area why would I expect setting Padding would actually apply to the Header the way it currently works? Padding is conceptually to surround the content. So the Padding property needs to go with the Content. Then what to do about Background, BorderBrush, etc... Well, we dare not make some properties apply to the header and some to the content area. By simple extension these need to apply to the content area as well. If I have the time I'll add links to the old discussions in WinUI. The arguments are pretty logical though as stated above. |
Beta Was this translation helpful? Give feedback.
-
This isn't entirely true. There are now resources to control all of this with the lightweight styling concept. There is absolutely no need to re-template to set things like header background. |
Beta Was this translation helpful? Give feedback.
-
Another option, maybe debatable, is to add
|
Beta Was this translation helpful? Give feedback.
-
It's quite hard to determine, because different controls have different focus. |
Beta Was this translation helpful? Give feedback.
-
Currently it's sometimes unclear where properties like
Padding
,Background
,Foreground
etc. should be applied to. The header-part or the content-part? This affects allHeaderedContentControls
likeTabControl
,Expander
, ... See #9270 as example7 votes ·
Beta Was this translation helpful? Give feedback.
All reactions