silverlight datagrid 行样式
我在页面上放了一个datagrid控件,
<Canvas Height="372" Canvas.Left="612" Canvas.Top="120" Width="588" > <sdk:DataGrid Height="378" Width="518" x:Name="ErrorGrid" AutoGenerateColumns="False" Background="#009496CB" Canvas.Left="-5" Canvas.Top="0" SelectionChanged="ErrorGrid_SelectionChanged" LoadingRow="ErrorGrid_LoadingRow" AlternatingRowBackground="#000919FF" HorizontalGridLinesBrush="#FFB3B6CB" RowBackground="#AA819BB1" VerticalGridLinesBrush="#FF647272"> <sdk:DataGrid.BorderBrush> <LinearGradientBrush> <GradientStop Color="#FFA3AEB9" Offset="0" /> <GradientStop Color="#FF8399A9" Offset="0.375" /> <GradientStop Color="#FF718597" Offset="0.375" /> <GradientStop Color="#FF938C93" Offset="1" /> </LinearGradientBrush> </sdk:DataGrid.BorderBrush> <sdk:DataGrid.RenderTransform> <TransformGroup> <ScaleTransform/> </TransformGroup> </sdk:DataGrid.RenderTransform> </sdk:DataGrid>
<DataGrid.RowStyle > <Style TargetType="DataGridRow"> <Style.Triggers> <Trigger Property="IsMouseOver" Value="True"> <Setter Property="Background" Value="#FFF1FAFF"/> <Setter Property="FontSize" Value=" 20"/> <Setter Property="Height" Value="30"/> <Setter Property="Foreground" Value="Blue"/> </Trigger> </Style.Triggers> </Style> </DataGrid.RowStyle> <DataGrid.CellStyle > <Style TargetType="DataGridCell"> <Style.Triggers > <Trigger Property="IsSelected" Value="True"> <Setter Property="Background" Value="#FFF1FAFF"/> <Setter Property="FontSize" Value=" 15"/> <Setter Property="Foreground" Value="Blue"/> </Trigger> </Style.Triggers> </Style> </DataGrid.CellStyle>