Is it possible to set FixedFieldSplitter's Width property in Style? The following code doesn't seem to do a blessed thing for the width, although the background works fine.
<
Style TargetType="{x:Type igDP:FixedFieldSplitter}">
Setter Property="Width" Value="1"/>
Setter Property="Background" Value="Red"/>
</
Style>
Hello,
This style does work, however, in the control template we are setting other sizes which are bigger than one pixel. That is why you are not seeing any change. If you set it to 10, then you will see it bigger.
If you want to change this, you would have to change the control template and remove the triggers/widths set there. The default templates you can find in the DefaultStyles directory in the Infragistics folder (DataPresenterGeneric_Express.xaml file).
Hi Alex,
I am trying to style the field splitter from the DefaultStyles provided as per the attached requirement. I am finding problem with the splitter taking up space of the header area. Is it possible for the splitter not to take up the header space at all.
The XAML style is as below.
<!-- ___________________________ Fixed Field Splitter Style ___________________________ -->
<Style TargetType="{x:Type igDP:FixedFieldSplitter}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type igDP:FixedFieldSplitter}">
<Grid Background="Transparent">
<Border x:Name="splitterMainBd" Background="Transparent" BorderBrush="Transparent"
BorderThickness="0" Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
<Border x:Name="splitterHoverBd" BorderBrush="Transparent" BorderThickness="0" Opacity="0"
Padding="0" SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
Background="Transparent"/>
<Border x:Name="innerStroke" Margin="0" BorderBrush="Transparent" BorderThickness="0" Opacity="0"/>
<Grid x:Name="gripperLinesVertical" Visibility="Collapsed" HorizontalAlignment="Center">
<Border Width="25" Height="10" HorizontalAlignment="Center" VerticalAlignment="Bottom"
Background="Red" />
</Grid>
<Grid x:Name="gripperLinesHorizontal" Visibility="Collapsed" VerticalAlignment="Center" Margin="0,1,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="0.15*"/>
<ColumnDefinition Width="0.7*"/>
</Grid.ColumnDefinitions>
<Border
Height="2"
Grid.Column="1"
HorizontalAlignment="Stretch"
Margin="0,0,0,2"
VerticalAlignment="Center"
Background="{DynamicResource {x:Static igDP:DataPresenterBrushKeys.FixedFieldsSplitterGripperDarkLineBrush}}"
BorderBrush="{DynamicResource {x:Static igDP:DataPresenterBrushKeys.FixedFieldsSplitterGripperLightLineBrush}}"
BorderThickness="0,0,0,1"/>
Margin="0,2,0,0"
<ControlTemplate.Triggers>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="Orientation" Value="Vertical"/>
<Condition Property="IsInHeader" Value="True"/>
</MultiTrigger.Conditions>
<Setter TargetName="gripperLinesVertical" Property="Visibility" Value="Visible"/>
<Setter TargetName="splitterMainBd" Property="Visibility" Value="Collapsed"/>
</MultiTrigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="Orientation" Value="Vertical">
<Setter Property="MinWidth" Value="7" />
<Setter Property="BorderThickness" Value="1,0,1,0"/>
<Setter Property="Background" Value="{DynamicResource {x:Static igDP:DataPresenterBrushKeys.FixedFieldsSplitterVerticalFillBrush}}"/>
<Setter Property="Cursor" Value="Hand" />
</Trigger>
</Style.Triggers>
</Style>