Keep text in TextView with drawableLeft centered

后端 未结 21 1572
野的像风
野的像风 2021-02-03 17:10

In my app I have a header bar which consists of a single textview with fill_parent as width, which have a specific background color and some centered text. Now I want to add a d

21条回答
  •  半阙折子戏
    2021-02-03 17:34

    One simple solution is to use a transparent image with the same size on the opposite side of the textview. In my example i copied my actual vector_image and changed the colors to be transparent.

    
    

提交回复
热议问题