grantland / android-autofittextview

A TextView that automatically resizes text to fit perfectly within its bounds.
Apache License 2.0
4.27k stars 689 forks source link

fixed StackOverflowError when pasting text lines larger than maxLines #25

Closed mariotaku closed 9 years ago

grantland commented 9 years ago

Could you post a sample of how to repro this condition? I've tried Autofiting an EditText and pasting in a multi-line text snippet, but it does not cause a stackoverflow.

grantland commented 9 years ago

This seems to be a solution for the condition where there's an Autofit view with maxLines > 1 and text with more than maxLines new lines will cause a stackoverflow.

Example: maxLines=2, paste "test\ntest\ntest"

11

grantland commented 9 years ago

Fixed by #32