feat(non linear font scaling): add TypedValue.deriveDimension()
deriveDimension() is the inverse of TypedValue.applyDimension(), so devs don't hardcode equations to convert px -> dp etc. The reason we need to discourage hardcoding is to ensure that devs are using the correct non- linear font scaling curves calculated by applyDimension(). Test: atest FrameworksCoreTests:android.content.res.FontScaleConverterTest && atest FrameworksCoreTests:android.util.TypedValueTest Bug: b/237558231 Change-Id: Id4252b6ddcb6183c7b4fc3489918bcfd95ee1103
Loading
Please register or sign in to comment