-
Hello 🖐, In a goal to share some of my modification of the style of HandyControl (that I really like btw 😊). In order to not have a file of 2000 lines, I separate my modification in differents files and then have a Theme.xaml where I merge all my ResourceDictionary. To achieved my modification I need to access to specify RessourceDictionnary of Handy and not get each time the 13000 line Handy's Theme.xaml 😅 <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/Theme.xaml"/>
<ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/SkinDark.xaml"/>
<ResourceDictionary Source="Color.xaml"/>
<ResourceDictionary Source="Styles/Navigation.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary> My custom modification Navigation.xaml : <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:theme="https://handyorg.github.io/handycontrol">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="pack://application:,,,/HandyControl;component/Themes/Styles/Base/ListBoxBaseStyle.xaml"/>
</ResourceDictionary.MergedDictionaries>
<Style x:Key="NavigationListBox" TargetType="ListBox" BasedOn="{StaticResource ListBoxBaseStyle}">
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Background" Value="Transparent"/>
</Style>
<Style x:Key="NavigationListBoxItem" TargetType="ListBoxItem" BasedOn="{StaticResource ListBoxItemBaseStyle}">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderThickness" Value="0,0,0,2"/>
<Setter Property="Margin" Value="5,0"/>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Opacity" Value="0.7"/>
<Setter Property="Background" Value="Transparent"/>
</Trigger>
<Trigger Property="IsSelected" Value="True">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="BorderBrush" Value="{StaticResource PrimaryBrush}"/>
</Trigger>
</Style.Triggers>
</Style></ResourceDictionary> When I use this solution to use the
I have also try the Handy's |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
@ghost1372 , @NaBian ? |
Beta Was this translation helpful? Give feedback.
@ghost1372 , @NaBian ?