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

Style Templates

9 Answers 174 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jed
Top achievements
Rank 2
Jed asked on 23 Jun 2008, 06:56 PM
I apologize in advance for any ignorance concerning the matter as I am new to Silverlight and come from a background of CSS when it comes to styling. I surely don't expect Telerik to be responsible for teaching us how to apply styles to Telerik controls if the method for doing so is exactly the same as the built-in Silverlight controls; though, I can't ignore how helpful it would be.

That being said, I'm having a frustrating time getting these RadControls for Silverlight 2 CTP to look the way we need them to look. My main difficulty here is knowing the structure inside the RadControls. As I understand it, to apply custom styles to a control, one has to understand what the control is composed of to declare the style of each individual component contained in the control. If I am wrong, please correct me. Under this assumption, however, I have used the .NET Reflector to read the ResourceDictionary XAML files from the Telerik.Windows.Controls.dll and used this ResourceDictionary as a reference for which style properties I can actively change to my liking. This only gave me a small piece of the picture though. I'm not sure if I'm going about this in the wrong way or if I'm just having a hard time with the learning curve here. I have examined the code on the Online Demos and haven't seen anything that really stuck out as a missing link.

To be more specific, I was simply just trying to change the background color and opacity of the RadMenu control. I had no problems tinkering with the RadMenuItem control's background color and opacity, but the RadMenu control itself is where the problem was. I saw LinearGradientBrush tags defined in the ResourceDictionary with x:Key="MenuBackground" and tried to override these values without success. Is there something I don't know about? I'm sure there is.

9 Answers, 1 is accepted

Sort by
0
Accepted
Hristo
Telerik team
answered on 24 Jun 2008, 03:08 PM
Hello Jed,

First, I want to thank you for your feedback.

Blend 2.5 June Preview doesn't support editing custom control templates so this is one major problem for all customers trying to reskin our controls. This will change with future version of Blend 2.5. At the moment we are thinking some workarounds like distributing a solution that include all of our skins. This way people will be able to edit all skins in Blend including controls States.

In the attached file you can find application that use custom skins defined in separate file (MenuResources.xaml) and see what is the current way to skin our controls.
Please keep in mind that this mechanism will probably change with the final version of our controls.

If you have further questions, do not hesitate to contact me.

Regards,
Hristo
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Jed
Top achievements
Rank 2
answered on 30 Jun 2008, 08:32 PM
Thank you for the response. Unfortunately, we are forced to move on to the next stages of development at this time and I can't look into this styling stuff any more until a later phase of polishing our controls.
0
Jaime
Top achievements
Rank 2
answered on 08 Jan 2009, 06:50 PM
Hi!,

Skinning and templating  is still impossible in the December Release using Blend.

Any help on this?

Best Regards.

0
max
Top achievements
Rank 1
answered on 09 Jan 2009, 06:46 AM
Indeed, I'm trying to open TelerikThemingApplication in Blend with the December release installed and it doesn't work.  How can the Window and Menu be styled at present?  I only need to make simple changes to colours.  (It does open and compile in VS2008 though.)
0
Nikolay
Telerik team
answered on 09 Jan 2009, 03:36 PM
Hello max,

The project you referred to is obsolete and it does not run against the latest Blend edition. We will improve the theming mechanism so that it will not be needed to open one such project in order to customize the themes. For the time being, we can help you change the theme in the XAML. Could you please tell us what are the changes you would like to make so that we can send you sample code?

Expecting your reply,
Nick
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
max
Top achievements
Rank 1
answered on 09 Jan 2009, 03:43 PM
Thanks for your quick response.
There are three things I'd like to change the colour of:
1) The colour menu items go when the mouse is hovering over (i.e. 'Open' if the file menu is open and you're hovering over 'Open')
2) The colour of the header of the currently open menu (i.e. 'File' if the file menu is open and you're hovering over 'Open')
3) The two colours for the gradient fill of the currently open menu.
Cheers,
Max Christian

0
max
Top achievements
Rank 1
answered on 09 Jan 2009, 03:52 PM
Thanks for your quick response.
There are three things I'd like to change the colour of:
1) The colour menu items go when the mouse is hovering over (i.e. 'Open' if the file menu is open and you're hovering over 'Open')
2) The colour of the header of the currently open menu (i.e. 'File' if the file menu is open and you're hovering over 'Open')
3) The two colours for the gradient fill of the currently open menu.
Cheers,
Max Christian

0
Dan
Top achievements
Rank 1
answered on 12 Jan 2009, 05:34 AM
Is there a new version of this demo available?  I tried running it with the latest version of the controls and there were a number of XAML problems preventing it from running correctly.
0
Hristo Deshev
Telerik team
answered on 12 Jan 2009, 05:07 PM
Hello Dan,

The latest Silverlight release has been published on December 17, 2008. Are you using that build? Also, can you paste a log of the errors you are getting?

Kind regards,
Hristo Deshev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
General Discussions
Asked by
Jed
Top achievements
Rank 2
Answers by
Hristo
Telerik team
Jed
Top achievements
Rank 2
Jaime
Top achievements
Rank 2
max
Top achievements
Rank 1
Nikolay
Telerik team
Dan
Top achievements
Rank 1
Hristo Deshev
Telerik team
Share this question
or