<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
		xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
		xmlns:local="clr-namespace:CustomThemeBasedOnOfficeBlack_GridWpf;assembly=CustomThemeBasedOnOfficeBlack_GridWpf"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"  
        
    xmlns:grid="clr-namespace:Telerik.Windows.Controls.GridView;assembly=Telerik.Windows.Controls.GridView"
    
    
    >
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="Resources.xaml"/>
    </ResourceDictionary.MergedDictionaries>
    

    <ControlTemplate x:Key="GridViewAggregateResultCellTemplate" TargetType="grid:GridViewAggregateResultCell">
        <Border Height="Auto" VerticalAlignment="Center" Background="{TemplateBinding Background}" >
            <StackPanel Orientation="Horizontal" VerticalAlignment="Center">
                <Rectangle Fill="{StaticResource GridViewAggregateResultCellBorderFill}" Stretch="Fill" Stroke="{StaticResource GridViewAggregateResultCellBorderStroke}" Width="2" Height="13" Margin="10,0,0,0" 
						   
						   SnapsToDevicePixels="True"
							
							/>
                <TextBlock Margin="5,0,5,0" TextAlignment="Right" VerticalAlignment="Center"
                           Foreground="{TemplateBinding Foreground}" 
                           Text="{Binding Caption}"/>
                <TextBlock Margin="5,0,5,0" TextAlignment="Right" VerticalAlignment="Center"
                           Foreground="{TemplateBinding Foreground}" 
                           Text="{Binding Value}"/>
            </StackPanel>
        </Border>
    </ControlTemplate>

    <Style 
        
        x:Key="{telerik:ThemeResourceKey ThemeType=local:CustomTheme, ElementType=grid:GridViewAggregateResultCell}"
        
        TargetType="grid:GridViewAggregateResultCell">
        <Setter Property="Template" Value="{StaticResource GridViewAggregateResultCellTemplate}" />
        <Setter Property="Background" Value="{StaticResource GridViewAggregateResultCellBackground}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="BorderBrush" Value="{StaticResource GridViewAggregateResultCellBorderBrush}" />
    </Style>
    
</ResourceDictionary>