|
|
|
@ -3,6 +3,7 @@ |
|
|
|
xmlns:dg="clr-namespace:Avalonia.Controls;assembly=Avalonia.DataGrid" |
|
|
|
xmlns:prim="clr-namespace:Avalonia.Controls.Primitives;assembly=Avalonia.DataGrid"> |
|
|
|
|
|
|
|
<!--TODO: Validation and Focus--> |
|
|
|
<Style Selector="dg|DataGridCell"> |
|
|
|
<Setter Property="Background" Value="Transparent"/> |
|
|
|
<Setter Property="HorizontalContentAlignment" Value="Stretch" /> |
|
|
|
@ -101,6 +102,17 @@ |
|
|
|
VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
|
|
|
Margin="{TemplateBinding Padding}"> |
|
|
|
<ContentPresenter Content="{TemplateBinding Content}"/> |
|
|
|
|
|
|
|
<Path Name="SortIcon" |
|
|
|
Grid.Column="1" |
|
|
|
Fill="#FF444444" |
|
|
|
HorizontalAlignment="Left" |
|
|
|
VerticalAlignment="Center" |
|
|
|
Stretch="Uniform" |
|
|
|
Width="8" |
|
|
|
Margin="4,0,0,0" |
|
|
|
Data="F1 M -5.215,6.099L 5.215,6.099L 0,0L -5.215,6.099 Z "/> |
|
|
|
|
|
|
|
</Grid> |
|
|
|
|
|
|
|
<Rectangle Name="VerticalSeparator" |
|
|
|
@ -207,6 +219,27 @@ |
|
|
|
<Setter Property="Opacity" Value="0.5"/> |
|
|
|
</Style> |
|
|
|
|
|
|
|
<Style Selector="dg|DataGridColumnHeader /template/ Path#SortIcon"> |
|
|
|
<Setter Property="IsVisible" Value="False"/> |
|
|
|
<Setter Property="RenderTransform"> |
|
|
|
<Setter.Value> |
|
|
|
<ScaleTransform ScaleX="0.9" ScaleY="0.9" /> |
|
|
|
</Setter.Value> |
|
|
|
</Setter> |
|
|
|
</Style> |
|
|
|
<Style Selector="dg|DataGridColumnHeader:sortascending /template/ Path#SortIcon"> |
|
|
|
<Setter Property="IsVisible" Value="True"/> |
|
|
|
</Style> |
|
|
|
<Style Selector="dg|DataGridColumnHeader:sortdescending /template/ Path#SortIcon"> |
|
|
|
<Setter Property="IsVisible" Value="True"/> |
|
|
|
<Setter Property="RenderTransform"> |
|
|
|
<Setter.Value> |
|
|
|
<ScaleTransform ScaleX="0.9" ScaleY="-0.9" /> |
|
|
|
</Setter.Value> |
|
|
|
</Setter> |
|
|
|
</Style> |
|
|
|
|
|
|
|
|
|
|
|
<!--FIX--> |
|
|
|
<Style Selector="dg|DataGridRow"> |
|
|
|
<Setter Property="Template"> |
|
|
|
@ -219,6 +252,7 @@ |
|
|
|
|
|
|
|
<prim:DataGridRowHeader Grid.RowSpan="3" Name="PART_RowHeader" prim:DataGridFrozenGrid.IsFrozen="True" /> |
|
|
|
<prim:DataGridCellsPresenter Grid.Column="1" Name="PART_CellsPresenter" prim:DataGridFrozenGrid.IsFrozen="True" /> |
|
|
|
<prim:DataGridDetailsPresenter Grid.Row="1" Grid.Column="1" Name="PART_DetailsPresenter"/> |
|
|
|
<Rectangle Grid.Row="2" Grid.Column="1" Name="PART_BottomGridLine" HorizontalAlignment="Stretch" Height="1" /> |
|
|
|
|
|
|
|
</prim:DataGridFrozenGrid> |
|
|
|
@ -468,7 +502,7 @@ |
|
|
|
|
|
|
|
<Rectangle Grid.Column="1" Grid.ColumnSpan="5" Fill="#FFFFFFFF" Height="1"/> |
|
|
|
<Rectangle Grid.Column="1" Grid.Row="1" Name="IndentSpacer" /> |
|
|
|
<ToggleButton Grid.Column="2" Grid.Row="1" Name="ExpanderButton" Height="15" Width="15" Margin="2,0,0,0"/> |
|
|
|
<ToggleButton Grid.Column="2" Grid.Row="1" Name="ExpanderButton" Margin="2,0,0,0"/> |
|
|
|
|
|
|
|
<StackPanel Grid.Column="3" Grid.Row="1" Orientation="Horizontal" VerticalAlignment="Center" Margin="0,1,0,1"> |
|
|
|
<TextBlock Name="PropertyNameElement" Margin="4,0,0,0" IsVisible="{TemplateBinding IsPropertyNameVisible}"/> |
|
|
|
@ -482,6 +516,23 @@ |
|
|
|
</ControlTemplate> |
|
|
|
</Setter> |
|
|
|
</Style> |
|
|
|
<Style Selector="dg|DataGridRowGroupHeader /template/ ToggleButton#ExpanderButton"> |
|
|
|
<Setter Property="Template"> |
|
|
|
<ControlTemplate> |
|
|
|
<Border Grid.Column="0" Width="20" Height="20" Background="Transparent" HorizontalAlignment="Center" VerticalAlignment="Center"> |
|
|
|
<Path Fill="Black" |
|
|
|
HorizontalAlignment="Center" |
|
|
|
VerticalAlignment="Center" |
|
|
|
Data="M 0 2 L 4 6 L 0 10 Z" /> |
|
|
|
</Border> |
|
|
|
</ControlTemplate> |
|
|
|
</Setter> |
|
|
|
</Style> |
|
|
|
<Style Selector="dg|DataGridRowGroupHeader /template/ ToggleButton#ExpanderButton:checked /template/ Path"> |
|
|
|
<Setter Property="RenderTransform"> |
|
|
|
<RotateTransform Angle="90" /> |
|
|
|
</Setter> |
|
|
|
</Style> |
|
|
|
|
|
|
|
<!-- |
|
|
|
|
|
|
|
|