Catlike Coding’s Text Box 2
for advanced text layout in Unity
Want to do some serious text layout in Unity? Now you can! Mix custom styles and fonts. Write your own renderers. Create multi-column layouts. Flow text around custom shapes. Use nested clipping and scrolling. Support clickable text. And it renders fast, on mobiles, with dynamic text, while keeping memory clean.
Text Box 2 is currently in beta. New features are released regularly, but documentation is still sparse. Text Box 1, which still runs on Unity 3.5.7, is also included in the package.
Version 2 beta 3.2 is now available!
(Below is the introduction for Text Box 1, which works with Unity 3.5.7 and is included with Text Box 2 beta.)
Here’s a text box that is powerful, fast, efficient, and runs anywhere. With word wrapping, text justification, character modififcations, outlines, shadows, and other fancy effects. For when “just text” isn’t good enough and you want the ultimate text solution for Unity.
Features
What key features does the ultimate text box have? I say these:
- Automatic word wrapping
- Text justification
- WYSIWYG editing
- Color and placement modification
- Excellent performance
- Memory-friendly dynamic content
- Clickable text
- Fancy text effects
- Bitmap font importer
- Gradient tool
- Documentation
- Support
It renders text using imported bitmap fonts, which means you can include exactly those characters you want, packed as efficiently as possible. There are multiple free tools to do this with. All characters from the Basic Multilingual Plane are supported.
Screenshots
Here’s some screenshots. All text is rendered using distance maps, the effects are applied by modifiers and shaders.
(The images get scaled down a bit to fit the forum, open them in a new view to see them at full size)
vertical gradient plus outline, text justified and set to stay inside the box width
shadow added with a shader
marked text colored yellow with a modifier
wrapped around a cylinder with a modifier
text made vague at a distance with a shader
Those screenshots were all from editor mode scene view, by the way. Here’s one with the text selected.
And here’s the text component’s inspector.
You also get a gradient asset, for those extra special color transitions.
Demo Scene
Here’s the demo scene, running on an iPad.
Demo Video
Here’s a demonstration video that shows how to get a nice text box up and running.