开发者

how to show gridline in the column header after applying background

开发者_如何学Python

After applying background to column header, the grid line cannot be seen anymore. Any simple way to get the gridline back?


You can specify BorderBrush and BorderThickness for the DataGridColumnHeader. Example

<DataGrid.Resources>
    <Style TargetType="{x:Type DataGridColumnHeader}">
        <Setter Property="Background" Value="Blue"/>
        <Setter Property="BorderBrush" Value="Red"/>
        <Setter Property="BorderThickness" Value="1,1,1,1"/>
    </Style>
</DataGrid.Resources>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜