Best Practice for Text on Android and Its Internals
summary
Shows how to speed up Android text rendering by identifying TextView hotspots with systrace and by turning off hyphenation to cut layout cost roughly in half. Describes moving expensive TextView measure/layout off the UI thread using PrecomputedText(Compat) and the getTextFuture / setTextFuture helpers, and explains caching strategy (LRU sizes) while warning about a known framework crash and a single large lock contention on older Android versions.
AI-written summary · about
chapters (14)
- 0:00Introduction
- 3:04Text rendering slowness
- 9:54TextView layout internals
- 17:13Text layout caching
- 21:50Precompute layout with threads
- 26:15Prefetch and background layout
- 33:07Android 9/10 font features
- 37:11Font collection and variable fonts
- 38:58Locale-aware font selection
- 39:51System serif font install
- 40:35Parallel text layout Android 10
- 41:17CJK justification support
- 42:02Tall script line spacing
- 43:04Q&A
related talks
37mAndroid Text, The Good The Bad and The ugly
36mBest practices for using text in Android
15mUse Android text like a pro
35mBest practices for text on Android
41mAndroid Textual Layout
46mTypesetting: designing and building beautiful text layouts
35mMake It Fit, how Android measures and draws views
48mEfficient Android Layouts
