When I change a radribbonview control's theme ,RadRibbonGallery lost its scroll bar and button. Any suggestions?
first capture image is before use theme, second is after use theme.
code:
Theme ConvertToTheme(string themeName)
{
if (string.IsNullOrWhiteSpace(themeName))
return new Windows7Theme();
return (Theme)typeof(Theme).Assembly.CreateInstance(string.Format("Telerik.Windows.Controls.{0}Theme", themeName));
}
first capture image is before use theme, second is after use theme.
code:
Theme ConvertToTheme(string themeName)
{
if (string.IsNullOrWhiteSpace(themeName))
return new Windows7Theme();
return (Theme)typeof(Theme).Assembly.CreateInstance(string.Format("Telerik.Windows.Controls.{0}Theme", themeName));
}
void SetGlobalTheme(Theme theme)
{
StyleManager.ApplicationTheme = theme;
StyleManager.SetTheme(radRibbonView1, theme);
}
private void RadRibbonRadioButton_Click(object sender, RoutedEventArgs e)
{
RadRibbonRadioButton radioButton = (RadRibbonRadioButton)sender;
Theme currentTheme = ConvertToTheme(radioButton.Text);//Button's content is theme name, like Office_Silver
SetThemeToAllViews(currentTheme);
}