3 Answers, 1 is accepted
0
Hello Oran,
If you only need to change two brushes, you might want to reconsider the choice of a theme.
On the other hand, if you still need to change only brushes, what you need is a custom theme which will hold styles for each TelerikControl you use and manually change the two brushes for each of the controls.
However, you need to keep in mind that using a custom theme is more or less equal to hard-coding styles in your application - it needs maintenance with future releases of the control.
Regards,
Dani
the Telerik team
If you only need to change two brushes, you might want to reconsider the choice of a theme.
On the other hand, if you still need to change only brushes, what you need is a custom theme which will hold styles for each TelerikControl you use and manually change the two brushes for each of the controls.
However, you need to keep in mind that using a custom theme is more or less equal to hard-coding styles in your application - it needs maintenance with future releases of the control.
Regards,
Dani
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
0

Oran
Top achievements
Rank 1
answered on 12 Jan 2011, 10:34 AM
I think we have misunderstood each other..
I see that every theme has its own identical brush that ALL controls are using. For example : the Office Silver theme is using some orange highlight brush both for MouseOver and Selection(which is a darker orange than the MouseOver).
My guess was that these two brushes are used globally by all controls and i just need to know how to reconfigure them and all the application highlighted selections and mouse overs will change.
From your answer i may understand that there are no global brushes and each control hard code its brush identically...
Is That True??
Thanks,
Oran
I see that every theme has its own identical brush that ALL controls are using. For example : the Office Silver theme is using some orange highlight brush both for MouseOver and Selection(which is a darker orange than the MouseOver).
My guess was that these two brushes are used globally by all controls and i just need to know how to reconfigure them and all the application highlighted selections and mouse overs will change.
From your answer i may understand that there are no global brushes and each control hard code its brush identically...
Is That True??
Thanks,
Oran
0
Hi Oran,
There are "global" brushes. However you do not have access to them in their raw version. And even such access level was possible , it would not help you affect all controls. The theming mechanism for RadControls uses preprocessed XAML and merges only the needed resources.
Yes, a lot of the resources are, of course, shared. However, due to some considerations, this is not the case with all RadControls. For example, most controls use a ControlBackground_Normal brush for their background, but RadScheduler uses a SchedulerBackground brush.
Shortly, you cannot change a single brush that will affect all controls. What you need to do is generate the style for a control and change that brush from the generated resources. In case you have a custom theme with a separate style file for each control, of course, as a result some of the generated resources will be repeated . This is the point where you can take all shared brushes and other shared resources to a single external file referenced by all style files.
Regards,
Dani
the Telerik team
There are "global" brushes. However you do not have access to them in their raw version. And even such access level was possible , it would not help you affect all controls. The theming mechanism for RadControls uses preprocessed XAML and merges only the needed resources.
Yes, a lot of the resources are, of course, shared. However, due to some considerations, this is not the case with all RadControls. For example, most controls use a ControlBackground_Normal brush for their background, but RadScheduler uses a SchedulerBackground brush.
Shortly, you cannot change a single brush that will affect all controls. What you need to do is generate the style for a control and change that brush from the generated resources. In case you have a custom theme with a separate style file for each control, of course, as a result some of the generated resources will be repeated . This is the point where you can take all shared brushes and other shared resources to a single external file referenced by all style files.
Regards,
Dani
the Telerik team
Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>