Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
265
LabelPresenterStyle with theme
posted

Hi,

I followed the post here http://forums.infragistics.com/forums/p/37921/219286.aspx to add a "select all" checkbox on the column header. That works fine, but the checkbox header loses its background color that gets set from the xamdatagrid royal strong theme, and making it look different from the rest of the field headers.

Please advise how I can preserve the theme color on the header while setting LabelPresenterStyle?

I also want to know how I can set the header CheckBox value at run time? 

Here's the xaml I have:

<igDP:XamDataGrid x:Name="grid" GroupByAreaLocation="None" DataSource="{Binding Path=Rules}" Theme="RoyaleStrong">

 

............

<igDP:XamDataGrid.Resources>

<

 

Style x:Key="CheckBoxedHeaderStyle" TargetType="{x:Type igDP:LabelPresenter}">

<

 

Setter Property="ContentTemplate">

<

 

Setter.Value>

<

 

DataTemplate>

<

 

CheckBox Name="HeaderCheckBox" Content="{Binding}" Click="HeaderCheckBox_Click"/>

</

 

DataTemplate>

</

 

Setter.Value>

</

 

Setter>

</

 

Style>

</

 

igDP:XamDataGrid.Resources>

 ................

 

<

 

igDP:Field Name="IncludeValuationPercent" Label="Include Val%" Width="85">

<igDP:Field.Settings>

 

 

 

 

<igDP:FieldSettings EditorStyle="{StaticResource customCheckEditor}" LabelPresenterStyle="{StaticResource CheckBoxedHeaderStyle}">

 

 

 

 

</igDP:FieldSettings>

 

 

 

 

</igDP:Field.Settings</igDP:Field>