Skip to content

Latest commit

 

History

History
95 lines (79 loc) · 4.38 KB

theming.md

File metadata and controls

95 lines (79 loc) · 4.38 KB
title page_title description slug tags published position
Theming
Theming
Check our "Theming" documentation article for the RadToolTip {{ site.framework_name }} control.
radtooltip-theming
theming
true
3

Theming

{% if site.site_name == 'Silverlight' %} Telerik themes are not turned on by default in RadToolTip. This article describes two approaches which can be used to theme the RadToolTip control.

The first approach that can be used for setting up the RadToolTip theming is to set the RadToolTipContentView control inside the ToolTipContent property.

[XAML] Example 2: Setting ToolTipContent property

{{region radtooltip-theming-1}} telerik:RadToolTipService.ToolTipContent telerik:RadToolTipContentView </telerik:RadToolTipContentView> </telerik:RadToolTipService.ToolTipContent> {{endregion}}

The second approach to use predefined Telerik styles is to define a ContentTemplate for the RadToolTip component and use the RadToolTipContentView control inside the template. The following code example demonstrates how to set up RadToolTip to use the Telerik themes.

[XAML] Example 1: Setting ToolTipContentTemplate property

{{region radtooltip-theming-0}} telerik:RadToolTipService.ToolTipContentTemplate telerik:RadToolTipContentView </telerik:RadToolTipContentView> </telerik:RadToolTipService.ToolTipContentTemplate> {{endregion}}

{% endif %}

{% if site.site_name == 'WPF' %}

Telerik themes are not turned on by default in RadToolTip. In order to use the predefined Telerik styles you can define a ContentTemplate for the RadToolTip component and use the RadToolTipContentView control inside the template.

The following code example demonstrates how to set up RadToolTip to use the Telerik themes.

[XAML] Example 1: Setting ToolTipContentTemplate property

{{region radtooltip-theming-0}} telerik:RadToolTipService.ToolTipContentTemplate telerik:RadToolTipContentView </telerik:RadToolTipContentView> </telerik:RadToolTipService.ToolTipContentTemplate> {{endregion}}

Another approach that can be used for setting up the RadToolTip theming is to set the ToolTipContentTemplate property to null and then define the RadToolTipContentView control inside the ToolTipContent.

[XAML] Example 2: Setting ToolTipContent property

{{region radtooltip-theming-1}} telerik:RadToolTipService.ToolTipContent telerik:RadToolTipContentView </telerik:RadToolTipContentView> </telerik:RadToolTipService.ToolTipContent> {{endregion}}

{% endif %}

The end result is demonstrated in the picture below: {% if site.site_name == 'WPF' %}radtooltip-theming-wpf 01{% endif %}{% if site.site_name == 'Silverlight' %}radtooltip-theming-sl 01{% endif %}

See Also

  • [Getting Started]({%slug radtooltip-getting-started%})