This is a migrated thread and some comments may be shown as answers.

Dynamically change application theme without reloading application?

3 Answers 338 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
David
Top achievements
Rank 1
David asked on 26 Aug 2010, 06:35 PM
Hello,

In all the various examples that I've seen of changing the application theme, when changing the theme from one to the other it will reload the entire application and all default values.  Is there a way to change the application theme without having to do it in the constructor of the app?

For example, in your online demos and local demos after installing the WPF toolkit, there is a drop down box that allows the user to change the theme of the current demo.  If it's the combo box demo, if I change the values of the combo boxes to something else and then change the theme, the default values are selected again and my previous selections are reset.  The same thing happens in the dock manager demo, if I close one or both of the top tabs and then change the theme, the tabs are reloaded.  This appears to be because in all the demos, the themes are set in the constructors, thus changing them would require the constructors to reload which would cause any user input to be completely forgotten.

Is there a way of getting around this?  Or would I be forced to individually change the themes on each individual control instead of the application theme to get what I want?

Thanks,
David

3 Answers, 1 is accepted

Sort by
0
David
Top achievements
Rank 1
answered on 26 Aug 2010, 07:05 PM
I'm just looking for a way to invalidate the already-drawn controls so they are redrawn with the new theme (without reloading the app).
0
David
Top achievements
Rank 1
answered on 01 Sep 2010, 12:48 AM
No ideas?
0
Veselin Vasilev
Telerik team
answered on 01 Sep 2010, 08:10 AM
Hello David,

This forum thread should shed some light about your question.

Kind regards,
Veselin Vasilev
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
Tags
General Discussions
Asked by
David
Top achievements
Rank 1
Answers by
David
Top achievements
Rank 1
Veselin Vasilev
Telerik team
Share this question
or