Description
The WhiteSpace.Normal
field is a member of the Sandbox.UI.WhiteSpace
enumeration. It represents the default behavior for handling white spaces in text content. In this mode, sequences of white spaces are collapsed into a single space, and text will wrap when necessary to fit within the container.
Usage
Use WhiteSpace.Normal
when you want text to behave in a standard manner, where extra spaces are not preserved, and text wraps naturally at the end of a line. This is suitable for most text content where readability and space efficiency are priorities.
Example
// Example of using WhiteSpace.Normal in a UI component
var textComponent = new TextComponent();
textComponent.WhiteSpace = WhiteSpace.Normal;
textComponent.Text = "This is a sample text that will wrap and collapse spaces.";