-
Notifications
You must be signed in to change notification settings - Fork 47
TreeView
Javier Suárez edited this page Aug 16, 2020
·
4 revisions
The TreeView
displays data in a hierarchical structure with expanding and collapsing nodes.
- Support for selection.
- Can customize the text font properties, etc.
- Customize the selected item.
- ControlTemplate support.
<controls:TreeView
SelectionMode="Single">
<controls:TreeView.RootNodes>
<controls:TreeViewNode
Icon="folder.png"
Text="Controls"
IsExpanded="True">
<controls:TreeViewNode.Children>
<controls:TreeViewNode
Icon="file.png"
IconSelected="whitefile.png"
Text="AvatarView"/>
<controls:TreeViewNode
Icon="folder.png"
Text="DataVisualization"
BackgroundColorSelected="DarkBlue">
<controls:TreeViewNode.Children>
<controls:TreeViewNode
Icon="file.png"
IconSelected="whitefile.png"
Text="Area Chart"/>
<controls:TreeViewNode
Icon="file.png"
IconSelected="whitefile.png"
Text="Bar Chart"/>
<controls:TreeViewNode
Icon="file.png"
IconSelected="whitefile.png"
Text="Line Chart"/>
</controls:TreeViewNode.Children>
</controls:TreeViewNode>
</controls:TreeViewNode.Children>
</controls:TreeViewNode>
</controls:TreeView.RootNodes>
</controls:TreeView>