So this is my GroupBox
:
<GroupBox
Header="My header"
Background="Transparent"
Foreground="Gainsboro"
BorderBrush="Gainsboro" />
And i have several things that i want to change/issues:
Foreground
is still in black although i have changed it.boder
around the Header
: i want to remove it in order to achieve this kind of style (the header
is over the border
):Edit:
After add the style
that user @mm8 suggested, this is the results:
Why i can see duplicate border ?
Create your own set of controls to have full control, similar to this:
<Grid Width="100" Height="200" Background="DodgerBlue">
<Grid.RowDefinitions>
<RowDefinition Height="20"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Border BorderThickness="1" BorderBrush="Gainsboro">
<TextBlock Foreground="Gainsboro">Header</TextBlock>
</Border>
<Border Grid.Row="1" BorderThickness="1" BorderBrush="Gainsboro">
<!--Content-->
</Border>
</Grid>