Description
The TextTransform.Capitalize
field is a member of the TextTransform
enumeration within the Sandbox.UI
namespace. It specifies that each word in the text should be capitalized, meaning the first letter of each word is converted to uppercase while the rest of the letters remain unchanged.
Usage
Use TextTransform.Capitalize
when you want to apply a text transformation that capitalizes the first letter of each word in a string. This is typically used in UI components where text styling is required to enhance readability or adhere to design guidelines.
Example
// Example of using TextTransform.Capitalize in a UI component
var label = new Label();
label.Text = "hello world";
label.TextTransform = TextTransform.Capitalize;
// The label will display: "Hello World"