TX Text Control .NET for Windows Forms

HorizontalAlignment Enumeration

Enumeration
Namespace
TXTextControl
Package
TXTextControl.TextControl.WinForms.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.dll
Install
dotnet add package TXTextControl.TextControl.WinForms.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.dll from the setup.

Description

Determines values for the horizontal alignment of the text or of text frames, images and charts. The enumeration contains the following values:

Syntax

public enum HorizontalAlignment

Members

MemberValueDescription
Left1The alignment is left aligned.
Right2The alignment right aligned.
Center3The alignment is centered.
Justify4The alignment is justified. This value is only used with text. It cannot be used with text frames, images and charts.

Examples

The following example selects the Center value from the Horizontal Alignment enumeration and uses it as a documented workflow choice.

TXTextControl.HorizontalAlignment value = TXTextControl.HorizontalAlignment.Center;
Console.WriteLine($"Using Horizontal Alignment: {value}");

See Also

ParagraphFormat.Alignment Property, FrameBase.Alignment Property, ChartCollection.Add Method, ImageCollection.Add Method, TextFrameCollection.Add Method.

Further Reading