Skip to content

HorizontalAlignment

Eduard Gushchin edited this page Jun 21, 2026 · 5 revisions

HorizontalAlignment

Back to API Reference

Namespace: Electron2D

Summary

Defines horizontal text alignment values used by Electron2D text drawing APIs.

Declaration

public enum Electron2D.HorizontalAlignment : System.IComparable, System.IConvertible, System.IFormattable, System.ISpanFormattable

Remarks

This type is part of the Electron2D 0.1.0 Preview public API.

Thread Safety

Enum values are immutable and can be used from any thread.

Since

This enum is available since Electron2D 0.1.0 Preview.

See Also

  • Electron2D.CanvasItem.DrawString(Electron2D.Font,Electron2D.Vector2,System.String,Electron2D.HorizontalAlignment,System.Single,System.Int32,System.Nullable{Electron2D.Color})

Members

Member Kind Summary
Center Enum value Align text to the center of the available width.
Fill Enum value Expand text spacing to fill the available width when supported.
Left Enum value Align text to the left side of the available width.
Right Enum value Align text to the right side of the available width.

Member Details

Center

Kind: Enum value

public const Electron2D.HorizontalAlignment Center

Summary

Align text to the center of the available width.

Remarks

Use this value with APIs that accept HorizontalAlignment.

Since

This API is available since Electron2D 0.1.0 Preview.

See Also

  • Electron2D.HorizontalAlignment

Fill

Kind: Enum value

public const Electron2D.HorizontalAlignment Fill

Summary

Expand text spacing to fill the available width when supported.

Remarks

Use this value with APIs that accept HorizontalAlignment.

Since

This API is available since Electron2D 0.1.0 Preview.

See Also

  • Electron2D.HorizontalAlignment

Left

Kind: Enum value

public const Electron2D.HorizontalAlignment Left

Summary

Align text to the left side of the available width.

Remarks

Use this value with APIs that accept HorizontalAlignment.

Since

This API is available since Electron2D 0.1.0 Preview.

See Also

  • Electron2D.HorizontalAlignment

Right

Kind: Enum value

public const Electron2D.HorizontalAlignment Right

Summary

Align text to the right side of the available width.

Remarks

Use this value with APIs that accept HorizontalAlignment.

Since

This API is available since Electron2D 0.1.0 Preview.

See Also

  • Electron2D.HorizontalAlignment

Clone this wiki locally