Setting VisualStudio2013Palette.Palette.HeaderColor doesn't update all elements

2 posts, 0 answers
  1. Dan
    Dan avatar
    1 posts
    Member since:
    Oct 2016

    Posted 21 Oct 2016 Link to this post

    I'm using NoXaml libraries with the VisualStudio2013 theme. I'm able to set the values of the colours in VisualStudio2013Palette.Palette and this mostly seems to correctly update everything at runtime...

    Except that I'm using RadDocking, and each pane has a header. The background is AlternativeColor, and then when you click a header it switches to HeaderColor. If I change AlternativeColor at runtime, the unselected pane headers all update as expected. However the selected pane header is painting in the original colour of HeaderColor, and doesn't change. The only way to change that seems to be to set it during startup (e.g. in my MainWindow constructor).

    I looked at the theme implementations. In PaneHeaderControlTemplate there's:

    <p><ObjectAnimationUsingKeyFrames Storyboard.TargetName="Content" Storyboard.TargetProperty="Background"></p><p>    <DiscreteObjectKeyFrame KeyTime="0:0:0" Value="{telerik:VisualStudio2013Resource ResourceKey=HeaderBrush}"/><br></ObjectAnimationUsingKeyFrames></p>


    If I change HeaderBrush to AccentMainBrush and change that at runtime, behaviour is the same. So it must be something about referring to that brush from the animation storyboard that copies the original brush?

    Is there a way around this? It would be cool to have the theme consistently change its colours without needing a restart.

  2. Evgenia
    Evgenia avatar
    1437 posts

    Posted 26 Oct 2016 Link to this post

    Hello Dan,

    Thanks for contacting us.
    I'm sorry but I don't think I see the same visual apparance as you in the RadDocking control with VisualStudio2013 theme applied. Each RadPaneGroup has AlternativeBrush applied as Background no matter if it is selected or not. The onliest color that change is the Background of the Grid with Name "Content" that's inside the ControlTemplate of the RadPaneGroup. Please check attached image.

    Maybe we are talking about different things. If so can you please provide some more information on your setup. Any image demonstrating what you see onm your side and steps to reproduce are very welcome.

    Looking forward to hearing from you. 

    Telerik by Progress
    Do you need help with upgrading your WPF project? Try the Telerik API Analyzer and share your thoughts!
Back to Top