Closed codecat closed 2 months ago
Yeah, this is probably something that could either be part of SpriteFont (give it a string plus width, and get a wrapped string back) or part of the Sprite Batcher (just draw the given string but wrapped to a given width)...
I've implemented various methods for calculating and rendering word-wrapping inside of SpriteFont! I think it could use some improvements but the basics work!
I don't see an API for drawing word wrapped text. This might be something that can be easily achieved externally, but perhaps would be nice to have built-in to Foster.