Android - Using Custom Font

后端 未结 21 2028
别跟我提以往
别跟我提以往 2020-11-22 04:38

I applied a custom font to a TextView, but it doesn\'t seems to change the typeface.

Here is my code:

    Typeface myTypeface = Typeface         


        
21条回答
  •  暗喜
    暗喜 (楼主)
    2020-11-22 05:08

    Make sure to paste the above code into onCreate() after your call to the super and the call to setContentView(). This small detail kept my hung up for awhile.

提交回复
热议问题