How to align the text to top of TextView?

后端 未结 6 756
梦如初夏
梦如初夏 2020-12-04 16:58

How to align the text to top of a TextView?
Equivalent Android API for Swings setInsets()?
that is top of text should start be in (0,0) of TextView



        
6条回答
  •  离开以前
    2020-12-04 17:28

    Possible, you do not need make your view based on TextView. Try to extend View and write your text in onDraw().

    Look at here: https://stackoverflow.com/a/32081250/1263771

提交回复
热议问题