TX Text Control .NET for WPF

GetToolTipDescription Method

Method|Introduced in 27.0
Namespace
TXTextControl.WPF
Package
TXTextControl.TextControl.WPF.SDK as TXTextControl.WPF.dll from the private NuGet feed or Text Control Offline Packages

Description

Gets the tool tip description that is associated with an item and specified by the identifier parameter. Such an identifier can be the string conversion of an enumeration that is associated with an item (such as RibbonFormattingTab.RibbonItem.TXITEM_Paste). By default CultureInfo.CurrentUiCulture determines the language of the tool tip description resources. If no resource translation is provided, that corresponds to the current ui culture or the value of the culture paramter, the returned tool tip description is based on the English resources.

Syntax

GetToolTipDescription(string)

Gets the tool tip description that is associated with the specified item identifier.

public static string GetToolTipDescription(string identifier);
ParameterDescription
identifier

The identifier of the item that is associated with the requested tool tip description.

GetToolTipDescription(string, CultureInfo)

Gets the tool tip description that is associated with the specified item identifier in the specified language.

public static string GetToolTipDescription(string identifier, CultureInfo culture);
ParameterDescription
identifier

The identifier of the item that is associated with the requested tool tip description.

culture

Specifies the language in which the tool tip description is returned.

Return Value

The tool tip description that is assigned to the item. If no tool tip description is associated with the source, the method returns an empty string.

Examples

The following example retrieves tool tip description from the resource provider.

var result = TXTextControl.WPF.ResourceProvider.GetToolTipDescription("Quarterly report", System.Globalization.CultureInfo.GetCultureInfo("en-US"));
Console.WriteLine($"Get Tool Tip Description result: {result}");