<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
					xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
					
				
					xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"     
					xmlns:grid="clr-namespace:Telerik.Windows.Controls.GridView;assembly=Telerik.Windows.Controls.GridView"
					xmlns:treelist="clr-namespace:Telerik.Windows.Controls.TreeListView;assembly=Telerik.Windows.Controls.GridView"
					xmlns:controls="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.GridView"
				
				
			
	>

    <SolidColorBrush x:Key="GridViewHeaderCellDropMarkerPenBrush" Color="#FF3D3D3D" />
<SolidColorBrush x:Key="GridView_HeaderBackground_Over" Color="#FF878787" />
<LinearGradientBrush x:Key="GridView_HeaderOuterBorder_Over" EndPoint="0.971000015735626,0.5" StartPoint="0.0399999991059303,0.5">
		<GradientStop Color="#FFB0B0B0" Offset="0"/>
		<GradientStop Color="#FFB0B0B0" Offset="1"/>
		<GradientStop Color="#FFE0E1E2" Offset="0.5"/>
	</LinearGradientBrush>
<LinearGradientBrush x:Key="GridView_HeaderBackground_Selected" EndPoint="0.5,1" StartPoint="0.5,0">
		<GradientStop Color="#FF616060" Offset="0"/>
		<GradientStop Color="#FFCDCDCD" Offset="1"/>
		<GradientStop Color="#FFCDCDCD" Offset="0.14"/>
	</LinearGradientBrush>
<LinearGradientBrush x:Key="GridView_HeaderOuterBorder_Selected" EndPoint="1,0.5" StartPoint="0,0.5">
		<GradientStop Color="#FF595959" Offset="0"/>
		<GradientStop Color="#FF595959" Offset="1"/>
		<GradientStop Color="#FFA3A3A3" Offset="0.5"/>
	</LinearGradientBrush>
<SolidColorBrush x:Key="GridView_SortIndicatorColor" Color="#FF262626" />
<telerik:Expression_DarkTheme x:Key="Theme" />
<SolidColorBrush x:Key="GridView_HeaderForeground_Over" Color="Black" />
<SolidColorBrush x:Key="GridView_HeaderForeground_Selected" Color="#FF262626" />
<SolidColorBrush x:Key="GridView_HeaderBackground" Color="#FF2D2E32" />
<LinearGradientBrush x:Key="GridView_HeaderOuterBorder" EndPoint="1,0.5" StartPoint="0,0.5">
		<GradientStop Color="#FF707070" Offset="1"/>
		<GradientStop Color="#FF707070"/>
		<GradientStop Color="#FFA3A3A3" Offset="0.5"/>
	</LinearGradientBrush>
<SolidColorBrush x:Key="GridView_HeaderForeground" Color="#FFDDDDDD" />

    
	<grid:GridLineWidthToThicknessConverter x:Key="GridLineWidthToThicknessConverter" />

	
	<Pen x:Key="GridViewHeaderCellDropMarkerPen" Brush="{StaticResource GridViewHeaderCellDropMarkerPenBrush}" Thickness="2" />
	

	<Style x:Key="ColumnHeaderGripperStyle" TargetType="Thumb">
		<Setter Property="Width" Value="6"/>
		<Setter Property="Background" Value="Transparent" />
		<Setter Property="BorderBrush" Value="Transparent" />
		<Setter Property="BorderThickness" Value="0" />
		<Setter Property="HorizontalContentAlignment" Value="Stretch" />
		<Setter Property="VerticalContentAlignment" Value="Stretch" />
		<Setter Property="Padding" Value="0" />
		<Setter Property="Cursor" Value="SizeWE"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="Thumb">
					<Border Padding="{TemplateBinding Padding}" 
							Background="{TemplateBinding Background}" 
							BorderBrush="{TemplateBinding BorderBrush}"
							BorderThickness="{TemplateBinding BorderThickness}"
							HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
							VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>

	<Style TargetType="ContentControl" x:Key="StretchedContentControl">
		<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
		<Setter Property="VerticalContentAlignment" Value="Stretch"/>
	</Style>

	<ControlTemplate x:Key="GridViewHeaderCellTemplate" TargetType="grid:GridViewHeaderCell">
		<Grid x:Name="PART_HeaderCellGrid">
			<Grid.ColumnDefinitions>
				<ColumnDefinition Width="*" />
				<ColumnDefinition Width="Auto"  />
			</Grid.ColumnDefinitions>			
			
			
			<Border x:Name="GridViewHeaderCell" Grid.ColumnSpan="2"
					Background="{TemplateBinding Background}"
					BorderBrush="{TemplateBinding BorderBrush}" 
					BorderThickness="{TemplateBinding BorderThickness}" />
			
			<Border x:Name="GridViewHeaderCell_Over" Grid.ColumnSpan="2"
					Background="{StaticResource GridView_HeaderBackground_Over}" 
					BorderBrush="{StaticResource GridView_HeaderOuterBorder_Over}" 
					BorderThickness="{TemplateBinding BorderThickness}" Visibility="Collapsed" />
			
			<Border x:Name="GridViewHeaderCell_Selected" Grid.ColumnSpan="2"
					Background="{StaticResource GridView_HeaderBackground_Selected}" 
					BorderBrush="{StaticResource GridView_HeaderOuterBorder_Selected}" 
					BorderThickness="{TemplateBinding BorderThickness}" Visibility="Collapsed" />
			

			<ContentControl x:Name="ContentPresenter" Grid.Column="0" Foreground="{TemplateBinding Foreground}"
							Style="{StaticResource StretchedContentControl}"
							Margin="{TemplateBinding Padding}" IsTabStop="{TemplateBinding IsTabStop}"
							Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}"
							VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
							HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" />

	
			<Path x:Name="PART_SortIndicator" Grid.ColumnSpan="2" Stroke="{x:Null}" 
				  Fill="{StaticResource GridView_SortIndicatorColor}" 
				  Stretch="Fill" HorizontalAlignment="Center" VerticalAlignment="Top"
				  Margin="0,4,0,0"
				  Data="M0,0 L5,0 L2.480835,3 L0,0 z"                           
				  Width="6" Height="6"
				  RenderTransformOrigin=".5,.5"
				  Visibility="Collapsed">
				<Path.RenderTransform>
					<TransformGroup>
						<ScaleTransform ScaleX="1" ScaleY="-1"/>
						<SkewTransform AngleX="0" AngleY="0"/>
						<RotateTransform Angle="0"/>
						<TranslateTransform X="0" Y="0"/>
					</TransformGroup>
				</Path.RenderTransform>
			</Path>

			<grid:FilteringDropDown Name="PART_DistinctFilterControl" Grid.Column="1"
									Visibility="{TemplateBinding FilteringUIVisibility}"
									telerik:StyleManager.Theme="{StaticResource Theme}" 
									Margin="0,0,8,0"/>
			
			<Thumb x:Name="PART_LeftHeaderGripper" HorizontalAlignment="Left" IsTabStop="{TemplateBinding IsTabStop}" Style="{StaticResource ColumnHeaderGripperStyle}" Grid.ColumnSpan="2" />
			<Thumb x:Name="PART_RightHeaderGripper" HorizontalAlignment="Right" IsTabStop="{TemplateBinding IsTabStop}" Style="{StaticResource ColumnHeaderGripperStyle}" Grid.ColumnSpan="2" />
			
		</Grid>
		
		<ControlTemplate.Triggers>

			<Trigger Property="IsMouseOver" Value="True">
				<Setter Property="Foreground" Value="{StaticResource GridView_HeaderForeground_Over}" />
				<Setter TargetName="GridViewHeaderCell_Over" Property="Visibility" Value="Visible" />
			</Trigger>

			<Trigger Property="SortingState" Value="Ascending">
				<Setter Property="Foreground" Value="{StaticResource GridView_HeaderForeground_Selected}" />
				<Setter TargetName="PART_SortIndicator" Property="Visibility" Value="Visible" />
				<Setter TargetName="PART_SortIndicator" Property="LayoutTransform" >
					<Setter.Value>
						<ScaleTransform ScaleX="1" ScaleY="1"/>
					</Setter.Value>
				</Setter>
				<Setter TargetName="GridViewHeaderCell_Selected" Property="Visibility" Value="Visible" />
			</Trigger>
			<Trigger Property="SortingState" Value="Descending">
				<Setter Property="Foreground" Value="{StaticResource GridView_HeaderForeground_Selected}" />
				<Setter TargetName="PART_SortIndicator" Property="Visibility" Value="Visible" />
				<Setter TargetName="GridViewHeaderCell_Selected" Property="Visibility" Value="Visible" />
			</Trigger>
			<Trigger Property="SortingState" Value="None">
				<Setter TargetName="PART_SortIndicator" Property="Visibility" Value="Collapsed" />
			</Trigger>
		</ControlTemplate.Triggers>
		
	</ControlTemplate>

	<Style 
		
		x:Key="{telerik:ThemeResourceKey ThemeType=telerik:ExpressionDarkTheme, ElementType=grid:GridViewHeaderCell}"
		
		TargetType="grid:GridViewHeaderCell">

		<Setter Property="Template" Value="{StaticResource GridViewHeaderCellTemplate}" />
		
		<Setter Property="Background" Value="{StaticResource GridView_HeaderBackground}" />
		<Setter Property="BorderBrush" Value="{StaticResource GridView_HeaderOuterBorder}" />
		<Setter Property="BorderThickness" Value="0,1,1,1" />
		<Setter Property="VerticalContentAlignment" Value="Center" />
		<Setter Property="HorizontalContentAlignment" Value="Stretch" />
		<Setter Property="Padding" Value="5,0,3,0" />
		
		<Setter Property="Foreground" Value="{StaticResource GridView_HeaderForeground}" />
		
		<Setter Property="DropMarkPen" Value="{StaticResource GridViewHeaderCellDropMarkerPen}" />
		<Setter Property="SnapsToDevicePixels" Value="True" />
		
		
	</Style>
	
	
</ResourceDictionary>