TextFlag LeftTop

book_4_sparkGenerated
code_blocksInput

Description

The LeftTop field is a member of the TextFlag enumeration in the Sandbox namespace. It is used to anchor text or other elements to the top left corner of a designated area. This flag is part of a set of flags that dictate the positioning of text, allowing for precise control over text alignment within a graphical interface.

Usage

Use the LeftTop flag when you need to position text at the top left corner of a container or graphical element. This is particularly useful in UI design where consistent text alignment is required across different components.

Example

// Example of using TextFlag.LeftTop in a drawing context
Graphics.DrawText("Hello, World!", new Vector2(10, 10), TextFlag.LeftTop);