How to change fontFamily of TextView in Android

后端 未结 30 3084
感动是毒
感动是毒 2020-11-22 01:05

So I\'d like to change the android:fontFamily in Android but I don\'t see any pre-defined fonts in Android. How do I select one of the pre-defined ones? I don\'

30条回答
  •  我在风中等你
    2020-11-22 01:32

    What you want is not possible. You must need to set TypeFace in your Code.

    In XML what you can do is

    android:typeface="sans" | "serif" | "monospace"
    

    other then this you can not play much with the Fonts in XML. :)

    For Arial you need to set type face in your code.

提交回复
热议问题