Using of system colors in WinUI3 without DynamicResource - is it possible?

Viewed 260

I am porting some XAML from WPF to WinUI3. As far as I understand for now I can't use DynamicResource in WinUI3, but is there any workaround to use system color like this one in WPF:

<SolidColorBrush Color="{DynamicResource {x:Static SystemColors.HighlightColorKey}}"/>
1 Answers

You could use the corresponding theme resource:

<SolidColorBrush Color="{ThemeResource SystemColorHighlightColor}"/>
Related