Subscript and Superscript a String in Android

后端 未结 15 1622
面向向阳花
面向向阳花 2020-11-22 09:20

How can you print a string with a subscript or superscript? Can you do this without an external library? I want this to display in a TextView in Android.

15条回答
  •  刺人心
    刺人心 (楼主)
    2020-11-22 09:56

    To all people asking, if you want to make it smaller besides of making super or subscript, you just need to add tag as well. EX:

    "X  2 "
    

提交回复
热议问题