Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Text word wrapping #82

Closed
codecat opened this issue Mar 28, 2024 · 2 comments
Closed

Text word wrapping #82

codecat opened this issue Mar 28, 2024 · 2 comments

Comments

@codecat
Copy link
Contributor

codecat commented Mar 28, 2024

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.

@NoelFB
Copy link
Collaborator

NoelFB commented Mar 28, 2024

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)...

@NoelFB
Copy link
Collaborator

NoelFB commented Jun 6, 2024

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!

@NoelFB NoelFB closed this as completed Jun 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants