Restore Theme

2 posts, 0 answers
  1. Andrés David Santacoloma Isaza
    Andrés David Santacoloma Isaza avatar
    51 posts
    Member since:
    Mar 2010

    Posted 02 Oct 2010 Link to this post

    I'm add changes to my themes using ColorBlending, but I need have the original theme too.
    then I need to know how restore a theme.

  2. Stefan
    Stefan avatar
    2911 posts

    Posted 07 Oct 2010 Link to this post

    Hi Andrés David Santacoloma Isaza,

    If you want to remove the color blend applied to a theme, you should just call the RemoveAllColorBlends method of the Theme instance, for example:
    // applying the color blend
    Telerik.WinControls.Theme currentTheme = Telerik.WinControls.ThemeResolutionService.GetTheme("BreezeExtended");
    currentTheme.AddColorBlend("BaseColor", Telerik.WinControls.HslColor.FromArgb(255, 56, 154, 254));
    currentTheme.ThemeProperties["BaseColor"] = Telerik.WinControls.HslColor.FromArgb(255, 245, 143, 41);
    // removing the color blend

    However, if you want to apply color blend to a theme and keep the original settings of the exact same theme, please note that this is not a supported behavior. The solution is to create a copy of your theme with a different theme name than the original theme. This article describes how to load one of the predefined themes. While saving it, you should just set a different theme name. The saved theme can be loaded in your project as described here. Finally, you will have two different themes in your project which give the same look and feel. When you apply the color blending to one of the themes, the other theme will remain untouched.

    I hope this helps.

    Best wishes,
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Back to Top