I got a simple question for all you friendly XAML experts. I have a datagrid with some row headers, which default horizontal alignment is center. All i want is to change this alignment to left. I have tried with the following code, but that dosent seem to work. Is it because the content consists of a textblock? If so, how do i get to change its alignment? I have tried changing the background of the header and it seems to work just fine.
Style:
<Style x:Key="DataGridRowHeaderStyle" TargetType="sdk:DataGridRowHeader">
<Setter Property="HorizontalContentAlignment" Value="Left"/>
</Style>
Control:
<sdk:DataGrid x:Name="CheeseWeightsColumnStatsDataGrid"
ItemsSource="{Binding CheeseWeightColumnStats}" IsReadOnly="True"
AutoGenerateColumns="False"
HeadersVisibility="Row"
LoadingRow="CheeseWeightsColumnStatsDataGrid_OnLoadingRow"
RowHeaderStyle="{StaticResource DataGridRowHeaderStyle}">
</sdk:DataGrid>