I am using the text generator so I can remove individual lines of text and prevent problems with wrapping, but I have no idea how to use it. How can I render the text generator on a canvas? I can populate it with characters but nothing is visible. The docs have no information about how the text generator class can be used in conjunction with the UI, so if anyone can help, I would appreciate it. Thanks in advance.
if you want use text generator on a canvas it should follow step below.
1.generate text
2.generate mesh by generated text
3.set font material
if use CanvasRenderer not MeshRenderer , you need set Vertex according generated text instead of generating mesh。and UGUI will set mesh for you because your script will inherit UnityEngine.UI.MaskableGraphic. Simultaneously,you change Vertex s position to reach some effect ,such as oblique text below。
and the code is here :link text hope can help you