TextFlag CenterVertically

robot_2Generated
code_blocksInput

Description

The CenterVertically field is a member of the TextFlag enumeration in the Sandbox namespace. It is used to align text or other elements in the center along the Y axis. This flag can be combined with other TextFlag values to achieve the desired alignment.

Usage

Use the CenterVertically flag when you need to center text or elements vertically within a given space. This can be particularly useful in UI design where vertical centering is required for aesthetic or functional purposes.

Example

// Example of using TextFlag.CenterVertically
Graphics.DrawText("Hello, World!", new Vector2(100, 100), TextFlag.CenterVertically | TextFlag.CenterHorizontally);