Created
July 28, 2023 18:40
-
-
Save timheuer/be3049e5e05ebccd4ace4d32e8e6ad55 to your computer and use it in GitHub Desktop.
WPF Styling problem
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<HierarchicalDataTemplate x:Key="TreeViewRunNodeDataTemplate" ItemsSource="{Binding Jobs}"> | |
<StackPanel Orientation="Horizontal" HorizontalAlignment="Left"> | |
<TextBlock VerticalAlignment="Center" FontFamily="{StaticResource CodiconFont}" | |
Foreground="{Binding Path=Conclusion, Converter={StaticResource ConclusionColorConverter}}" | |
Text="{Binding Path=Conclusion, Converter={StaticResource ConclusionIconConverter}}"/> | |
<emoji:TextBlock Text="{Binding DisplayName}" VerticalAlignment="Bottom" Tag="{Binding Url}"/> | |
</StackPanel> | |
</HierarchicalDataTemplate> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<TreeView BorderThickness="0" FontWeight="Normal" PreviewMouseWheel="HandlePreviewMouseWheel" x:Name="tvCurrentBranch" ItemTemplate="{StaticResource TreeViewRunNodeDataTemplate}" HorizontalAlignment="Stretch" HorizontalContentAlignment="Stretch"> | |
<TreeView.Resources> | |
<Style TargetType="{x:Type TreeViewItem}" BasedOn="{StaticResource {x:Type TreeViewItem}}"> | |
<EventSetter Event="MouseDoubleClick" Handler="JobItem_MouseDoubleClick"/> | |
</Style> | |
</TreeView.Resources> | |
</TreeView> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment