Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0f770686 authored by Tyler Freeman's avatar Tyler Freeman
Browse files

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
parent 763a69a3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment