You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary:
Pull Request resolved: #54715
Changelog: [Android][Fixed] Fixed `adjustsFontSizeToFit` scaling the font size too much down
Fixes#54356
Previous implementation was always using the starting font size as base for calculating ratio and was applying it to the already scaled down font sizes in each iteration. This caused the text size to be scaled down too aggresively.
In this diff I changed the implementation to use the font size from the previous iteration for calculating the scale ratio to fix that. I also updated it to use binary seach instead of linear search for finding the largest fitting font size.
Reviewed By: cortinico
Differential Revision: D87973778
fbshipit-source-id: 42bf5ffd8751ef8e29e06e657175fcbe98a93d5b
0 commit comments