I've been reading as much as I can on how to theme controls.
In particular, I wanted to react to this article:
One of the cons that isn't mentioned for implicit styles, is that when you want to create a new style, you have to use BasedOn, otherwise nothing will be rendered.
That is not what happens for regular WPF controls, because they still have their default (or theme) style applied. A custom style then only extend the default style, and if you want to disregard it altogether, you can set OverridesDefaultStyle to True.
I have 2 questions:
1. "Implicit styles for Telerik controls can’t be used if the application theme is set to other than the default Office_Black theme." => That is not something that I have observed. Using the 2019.2.510 Xaml packages, whichever theme I set is still honored when I create custom implicit styles. For example if I write this:
<Setter Property="FontWeight" Value="Bold" />
Then the buttons will have a Bold text and still apply the rest of my current theme set by StyleManager, whether it's Office_Black, Office2016, Green or anything else.
Could you explain what you meant, or if it is outdated and implicit styles are now supported with StyleManager?
2. Why was support for the built-in WPF mechanism for theming not adopted? If in the AssemblyInfo.cs if your NoXaml assemblies you set ExternalAssembly for the first parameter of ThemeInfo, then it would be possible for your customers to create a Generic assembly (e.g. Telerik.Windows.Controls.Generic) that contains the Themes/Generic.xaml that merges whichever theme they choose, and even further customize the theme. And/or for customers who don't want to customize the themes, you could directly provide those Generic theme assemblies in packages for each theme. Therefore, you'd have the best of both worlds as to apply the theme, customers would only need to reference the appropriate Generic assembly, and they'd have implicit styling support without having to specify BasedOn on all their custom styles.
Thanks in advance for any clarification