This question is locked. New answers and comments are not allowed.
Hello -
If I subclass RadTabStrip, I find that I lose the default theme. Here is the code:
public class Tabs : RadTabStrip |
{ |
} |
void Form1_Load(object sender, EventArgs e) |
{ |
var tabs = new RadTabStrip(); |
Controls.Add(tabs); |
tabs.BeginInit(); |
tabs.Dock = DockStyle.Fill; |
tabs.Items.Add(new TabItem() { Text = "First" }); |
tabs.Items.Add(new TabItem() { Text = "Second" }); |
tabs.Items.Add(new TabItem() { Text = "Third" }); |
tabs.EndInit(); |
} |
The above works great & is themed with the default Telerik theme. However, if I replace "new RadTabStrip()" above with "new Tabs()", the default theme is lost. For RadElement subclasses, I was told to override ThemeEffectiveType and return the base Telerik type, which works quite nicely. However, being a Control rather than a RadElement, RadTabStrip doesn't support this virtual method. I'm guessing there is some other simple way for my subclass to not get in the way of the theme mechanism.
Thanks!
- Mike