RadToolTipService
The RadToolTipService class provides a comprehensive service for managing tooltips in a WPF application. It enables the user to customize tooltip behavior through various properties and events, such as show and hide delays, position offsets, and tooltip content. This service supports the attachment of events for tooltip opening and closing, and facilitates dynamic updates to tooltips as the user interacts with UI elements. Furthermore, it manages the display of tooltips based on user actions (like mouse movement) and conditions, allowing for an enhanced user experience through rich tooltip customization.
Definition
Namespace:Telerik.Windows.Controls
Assembly:Telerik.Windows.Controls.dll
Syntax:
public static class RadToolTipService
Inheritance: objectRadToolTipService
Fields
BetweenShowDelayProperty
DependencyProperty
Identifies the BetweenShowDelay dependency property.
public static readonly DependencyProperty BetweenShowDelayProperty
HorizontalOffsetProperty
DependencyProperty
Identifies the HorizontalOffset dependency property.
public static readonly DependencyProperty HorizontalOffsetProperty
InitialShowDelayProperty
DependencyProperty
Identifies the InitialShowDelay dependency property.
public static readonly DependencyProperty InitialShowDelayProperty
IsEnabledProperty
DependencyProperty
Identifies the IsEnabled dependency property.
public static readonly DependencyProperty IsEnabledProperty
IsOpenProperty
DependencyProperty
Identifies the IsOpen dependency property.
public static readonly DependencyProperty IsOpenProperty
PlacementProperty
DependencyProperty
Identifies the Placement dependency property.
public static readonly DependencyProperty PlacementProperty
PlacementRectangleProperty
DependencyProperty
Identifies the PlacementRectangle dependency property.
public static readonly DependencyProperty PlacementRectangleProperty
PlacementTargetProperty
DependencyProperty
Identifies the PlacementTarget dependency property.
public static readonly DependencyProperty PlacementTargetProperty
ShowDurationProperty
DependencyProperty
Identifies the ShowDuration dependency property.
public static readonly DependencyProperty ShowDurationProperty
ToolTipClosingEvent
RoutedEvent
Identifies the ToolTipClosing routed event.
public static readonly RoutedEvent ToolTipClosingEvent
ToolTipContentProperty
DependencyProperty
Identifies the ToolTipContent dependency property.
public static readonly DependencyProperty ToolTipContentProperty
ToolTipContentTemplateProperty
DependencyProperty
Identifies the ToolTipContentTemplate dependency property.
public static readonly DependencyProperty ToolTipContentTemplateProperty
ToolTipOpeningEvent
RoutedEvent
Identifies the ToolTipOpening routed event.
public static readonly RoutedEvent ToolTipOpeningEvent
VerticalOffsetProperty
DependencyProperty
Identifies the VerticalOffset dependency property.
public static readonly DependencyProperty VerticalOffsetProperty
Methods
Adds handler for the ToolTipClosing event.
public static void AddToolTipClosingHandler(DependencyObject target, RoutedEventHandler handler)
The target.
handlerRoutedEventHandlerThe handler.
Adds handler for the ToolTipOpening event.
public static void AddToolTipOpeningHandler(DependencyObject target, RoutedEventHandler handler)
The target.
handlerRoutedEventHandlerThe handler.
Gets the maximum time between the display of two tooltips where the second tooltip appears without a delay.
public static int GetBetweenShowDelay(DependencyObject element)
The element.
Returns:Gets the offset from the left of the area that is specified for the tooltip by the PlacementRectangle and PlacementTarget properties.
public static double GetHorizontalOffset(DependencyObject element)
The element.
Returns:Gets the length of time before a tooltip opens.
public static int GetInitialShowDelay(DependencyObject element)
The element.
Returns:Gets whether a tooltip appears.
public static bool GetIsEnabled(DependencyObject element)
The element.
Returns:Gets whether a tooltip is currently visible.
public static bool GetIsOpen(DependencyObject element)
The element.
Returns:GetPlacement(DependencyObject)
PlacementMode
Gets the orientation of the tooltip when it opens, and specifies how the tooltip behaves when it overlaps screen boundaries.
public static PlacementMode GetPlacement(DependencyObject element)
The element.
Returns:PlacementMode
Gets the rectangular area relative to which the tooltip is positioned.
public static Rect GetPlacementRectangle(DependencyObject element)
The element.
Returns:Rect
GetPlacementTarget(DependencyObject)
UIElement
Gets the object relative to which the tooltip is positioned.
public static UIElement GetPlacementTarget(DependencyObject element)
The element.
Returns:UIElement
Gets the amount of time that a tooltip remains visible.
public static int GetShowDuration(DependencyObject element)
The element.
Returns:Gets the content of the ToolTip.
public static object GetToolTipContent(DependencyObject element)
The element.
Returns:GetToolTipContentTemplate(DependencyObject)
DataTemplate
Gets the ToolTip content template.
public static DataTemplate GetToolTipContentTemplate(DependencyObject element)
The element.
Returns:DataTemplate
Gets the distance from the top of the area that is specified for the tooltip by the PlacementRectangle and PlacementTarget properties.
public static double GetVerticalOffset(DependencyObject element)
The element.
Returns:Hides the tooltip.
public static void HideTooltip(FrameworkElement owner)
The owner of the tooltip.
Removes handler for the ToolTipClosing event.
public static void RemoveToolTipClosingHandler(DependencyObject target, RoutedEventHandler handler)
The target.
handlerRoutedEventHandlerThe handler.
Removes handler for the ToolTipOpening event.
public static void RemoveToolTipOpeningHandler(DependencyObject target, RoutedEventHandler handler)
The target.
handlerRoutedEventHandlerThe handler.
Sets the maximum time between the display of two tooltips where the second tooltip appears without a delay.
public static void SetBetweenShowDelay(DependencyObject element, int value)
The element.
valueintThe value.
Sets the offset from the left of the area that is specified for the tooltip by the PlacementRectangle and PlacementTarget properties.
public static void SetHorizontalOffset(DependencyObject element, double value)
The element.
valuedoubleThe value.
Sets the length of time before a tooltip opens.
public static void SetInitialShowDelay(DependencyObject element, int value)
The element.
valueintThe value.
Sets whether a tooltip appears.
public static void SetIsEnabled(DependencyObject element, bool value)
The element.
valueboolThe value.
Sets the orientation of the tooltip when it opens, and specifies how the tooltip behaves when it overlaps screen boundaries.
public static void SetPlacement(DependencyObject element, PlacementMode value)
The element.
valuePlacementModeThe value.
Sets the rectangular area relative to which the tooltip is positioned.
public static void SetPlacementRectangle(DependencyObject element, Rect value)
The element.
valueRectThe value.
Sets the object relative to which the tooltip is positioned.
public static void SetPlacementTarget(DependencyObject element, UIElement value)
The element.
valueUIElementThe value.
Sets the amount of time that a tooltip remains visible.
public static void SetShowDuration(DependencyObject element, int value)
The element.
valueintThe value.
Sets the content of the ToolTip.
public static void SetToolTipContent(DependencyObject element, object value)
The element.
valueobjectThe value.
Sets the ToolTip content template.
public static void SetToolTipContentTemplate(DependencyObject element, DataTemplate value)
The element.
valueDataTemplateThe value.
Sets the distance from the top of the area that is specified for the tooltip by the PlacementRectangle and PlacementTarget properties.
public static void SetVerticalOffset(DependencyObject element, double value)
The element.
valuedoubleThe value.