TX Text Control .NET for WPF

FontStyle Property

Property|Introduced in 16.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 or sets the font style of the text control. This is a dependency property. The property value has the type System.Windows.FontStyle. The default value is FontStyles.Normal.

Syntax

public FontStyle FontStyle { get; set; }

Examples

The following example uses TextControl.FontStyle to configure font style as part of the text control workflow. The configured value is checked before the workflow continues.

textControl.FontStyle = System.Windows.FontStyles.Normal;
Console.WriteLine($"Font Style used by Text Control: {textControl.FontStyle}");