Calligraphy
Calligraphy copied to clipboard
Adds A Config Option To Provide a FontPath Substitution Map
Summary: In order to A/B test fonts, this adds an option to the CalligraphyConfig to provide a fontPath substitution map. This enables dynamically changing fonts at run time and requires no changes to XML files. The logic to substitute the fontPath is in the TypefaceUtils. The reason the map is set on the TypeFaceUtils class instead of the TypefaceUtils checking the CalligraphyConfig is that this way it doesn't require constant invocations of CalligraphyConfig.get().
Test Plan:
- Verified with sample app that the new config option works as expected.