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

IllegalArgumentException thrown in DrawString method #31

Closed
Kischloren opened this issue Sep 28, 2021 · 3 comments
Closed

IllegalArgumentException thrown in DrawString method #31

Kischloren opened this issue Sep 28, 2021 · 3 comments

Comments

@Kischloren
Copy link

Would it be possible to check str value in drawString(String str, float x, float y) method which will prevent the following IllegalArgumentException?

java.lang.IllegalArgumentException: Can`t add attribute to 0-length text at java.base/java.text.AttributedString.addAttribute(AttributedString.java:322)

Thank you very much.

attributedString.addAttribute(TextAttribute.FONT, font);

rototor added a commit that referenced this issue Sep 28, 2021
@rototor
Copy link
Owner

rototor commented Sep 28, 2021

I'll do a release with this fix later today.

rototor added a commit that referenced this issue Sep 28, 2021
rototor added a commit that referenced this issue Sep 28, 2021
@rototor
Copy link
Owner

rototor commented Sep 28, 2021

I've just released version 0.33 with the fix.

@rototor rototor closed this as completed Sep 28, 2021
@Kischloren
Copy link
Author

Thank you very much.

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