Struct Text2DAutoFit
When added to an entity with a Text2DRenderer component, auto-fits the text. For Text2DAutofit to work, you must also add a RectTransformFinalSize component to the entity.
Namespace: Unity.Tiny.Text
Syntax
public struct Text2DAutoFit : IComponentData
Fields
maxSize
The maximum font size.
Declaration
public float maxSize
Field Value
Type | Description |
---|---|
System.Single |
minSize
The minimum font size. If the font size computed at runtime to fit in the RectTransform is below this value, the text does not render.
Declaration
public float minSize
Field Value
Type | Description |
---|---|
System.Single |