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

Skip to content
Commit 46926698 authored by Romain Guy's avatar Romain Guy
Browse files

Don't allocate new typefaces when not needed.

The Typeface.create(Typeface, int) API can be used to create a new
typeface derived from an existing typeface. The implementation would
however create a new Typeface instance on every call, creating
unnecessary garbage in text-heavy applications. This changelist
adds a small cache of derived typefaces to avoid allocations whenever
possible.

Change-Id: Ib7290b3183e372aae12cf66033690e15cd4d0691
parent 3fe4eb9c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment