-5

How do I add a custom font into a <TextView /> or a Custom view for an Android application?

MiguelHincapieC
  • 5,297
  • 5
  • 39
  • 66

1 Answers1

0

Try this,

  TextView tx = (TextView)findViewById(R.id.hello);
  Typeface custom_font = Typeface.createFromAsset(getAssets(),
  "fonts/Erika Type.ttf");
  tx.setTypeface(custom_font);
K Neeraj Lal
  • 6,700
  • 3
  • 22
  • 33