-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathGeneric.xaml
20 lines (20 loc) · 1.38 KB
/
Generic.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:dxci="http://schemas.devexpress.com/winfx/2008/xaml/core/internal"
xmlns:local="clr-namespace:DXSample">
<Style TargetType="{x:Type local:CustomControl1}">
<Setter Property="Foreground" Value="{dxci:ThemeResource ThemeKey='Brush.Foreground, Win11=Brush.Foreground.Alt'}" />
<Setter Property="Background" Value="{dxci:ThemeResource ThemeKey='Brush.Window.Background, Win11=Brush.Foreground.AltMuted, Win10=#FFFF0000'}"/>
<Setter Property="BorderThickness" Value="3" />
<Setter Property="BorderBrush" Value="{dxci:ThemeResource ThemeKey='Brush.Window.Background, Win11=#FF00FF00, Win11Dark=#FF0000AA'}"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:CustomControl1}">
<Border Background="{TemplateBinding Background}" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}">
<TextBlock Foreground="{TemplateBinding Foreground}" Text="{TemplateBinding Text}"/>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>