| | |
| | | <Setter Property="VerticalContentAlignment" Value="Center"/> |
| | | <Setter Property="BorderThickness" Value="0"/> |
| | | <Setter Property="BorderBrush" Value="LightGray"/> |
| | | <Setter Property="Foreground" Value="{Binding Foreground,RelativeSource={RelativeSource Mode=FindAncestor, |
| | | AncestorType=DataGridCell,AncestorLevel=1}}"/> |
| | | <Setter Property="Template"> |
| | | <Setter.Value> |
| | | <ControlTemplate TargetType="{x:Type local:TreeItemContentControl}"> |
| | |
| | | <Line x:Name="line" X1="7.5" Y1="0" X2="7.5" Y2="{Binding ElementName=lineGrid,Path=ActualHeight}" StrokeThickness="1" |
| | | Stroke="{Binding RelativeSource={RelativeSource Mode=FindAncestor,AncestorType=DataGridRow},Path=Foreground}" StrokeDashArray="1,1"/> |
| | | </Grid> |
| | | <!-- 这里放开有个问题,会让只有一个根节点的树列表显示错误 --> |
| | | <!--这里放开有个问题,会让只有一个根节点的树列表显示错误--> |
| | | <!--<DataTemplate.Triggers> |
| | | <DataTrigger Binding="{Binding IsLastItem}" Value="true"> |
| | | <Setter Property="Visibility" Value="Collapsed"/> |
| | |
| | | </ListBox> |
| | | </Grid> |
| | | |
| | | <ToggleButton x:Name="ExpanderButton" Grid.Column="1" Style="{StaticResource ClearToggleStyle}" HorizontalAlignment="Left" |
| | | <ToggleButton x:Name="ExpanderButton" |
| | | Cursor="Hand" |
| | | Grid.Column="1" Style="{StaticResource ClearToggleStyle}" HorizontalAlignment="Left" |
| | | |
| | | IsChecked="{Binding RelativeSource={RelativeSource Mode=TemplatedParent},Path=TreeData.IsExpanded,Mode=TwoWay}" |
| | | Content="{Binding RelativeSource={RelativeSource Mode=TemplatedParent},Path=TreeData.IconType}" |
| | | ContentTemplate="{StaticResource Icon_Template}" |