Name Property
- Namespace
TXTextControl
- Package
TXTextControl.asTextControl. WPF. SDK TXTextControl.from the private NuGet feed or Text Control Offline Packagesdll
Description
Gets or sets the name of the style.
Syntax
public string Name { get; set; }Public Property Name As StringExamples
The following example creates a reusable emphasis style and adds it to the document by using FormattingStyle.Name.
FormattingStyle formattingStyle = new InlineStyle("Emphasis");
formattingStyle.Name = "FormattingStyle1";
if (!string.IsNullOrWhiteSpace(formattingStyle.Name))
{
Console.WriteLine($"Name: {formattingStyle.Name}");
}
textControl.InlineStyles.Add((InlineStyle)formattingStyle);Dim formattingStyle As FormattingStyle = New InlineStyle("Emphasis")
formattingStyle.Name = "FormattingStyle1"
If Not String.IsNullOrWhiteSpace(formattingStyle.Name) Then
Console.WriteLine($"Name: {formattingStyle.Name}")
End If
textControl.InlineStyles.Add(DirectCast(formattingStyle, InlineStyle))