S Zain Bukhari S Zain Bukhari - 1 year ago 159
Android Question

How to import external font/ typeface in ANDROID STUDIO?

I wanna know how do I use an external font in Android Studio as there is no Assets folder. I have look for a helpful turtorial on internet but they all pretend to use Assets folder. I created an asset folder myself in src/main but Android Studio doesnt recognie getAssets(). So help me maybe :)

Thank You

Answer Source

Go on your Project: app-->src-->main

Create a assets folder like this:







and then use

     Typeface face=Typeface.createFromAsset(getAssets(),"fonts/digital.ttf");
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download