Silverlight Telerik Control Learning: Theme Theme Toggle HTML Tutorial

Source: Internet
Author: User
Tags silverlight

Telerik's radcontrols for Silverlight includes the following theme styles:
Office Black-This is the default and does not require any additional DLL files to be loaded.
Office Blue-Requires reference to Telerik.Windows.Themes.Office_Blue.dll.
Office Silver-Requires reference to Telerik.Windows.Themes.Office_Silver.dll.
Summer-Need to reference Telerik.Windows.Themes.Summer.dll.
Vista-requires reference to Telerik.Windows.Themes.Vista.dll.
Windows 7-requires reference to Telerik.Windows.Themes.Windows7.dll.
Transparent-Need to reference Telerik.Windows.Themes.Transparent.dll
Here's how to switch:
1. Local Switching/setting method
<telerik:radbutton height= "width=" "content=" Pop "telerik:stylemanager.theme=" Windows7 "click=" RadButton_ Click "/>
This is like inline styles in CSS that affect only the current control
2. Global switching/Setting method
In the App.xaml.cs file, add a line of code to the app's constructor, which is referenced below:
Public App ()
{
Stylemanager.applicationtheme = new Windows7theme ();
This. Startup + = this. Application_Startup;
This. Exit + = this. Application_exit;
This. UnhandledException + = this. Application_unhandledexception;
InitializeComponent ();
}
This is like a CSS global file referenced in Web authoring with link ref.
3. Custom Themes
If you are not satisfied with the built-in theme, you can also customize it as follows:
Define a topic class first
public class CustomTheme:Telerik.Windows.Controls.Theme
{
}
The source is then indicated in the constructor of this class
Public Customtheme ()
{
This. Source = new Uri ("/telerik.windows.themes.customtheme;component/themes/generic.xaml", urikind.relative);
}
The things in the back are exactly the same as the one mentioned earlier.

Original Address wpf123

Silverlight Telerik Control Learning: Theme Theme Toggle HTML Tutorial

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.