Skip to content

Instantly share code, notes, and snippets.

View majidnow's full-sized avatar

Majid Nasiri majidnow

  • Zanjan, Iran
View GitHub Profile
majidnow /
Created June 17, 2017 14:50 — forked from artem-zinnatullin/
If you need to set one font for all TextViews in android application you can use this solution. It will override ALL TextView's typefaces, includes action bar and other standard components, but EditText's password font won't be overriden.
public class MyApp extends Application {
public void onCreate() {
TypefaceUtil.overrideFont(getApplicationContext(), "SERIF", "fonts/Roboto-Regular.ttf"); // font from assets: "assets/fonts/Roboto-Regular.ttf