android中textView周围显示图片
16lz
2021-12-04
在Android 中,TextView 是继承于View,而Button是继承于TextView.这个有一个API就可以实现的。
android:drawableBottom | setCompoundDrawablesWithIntrinsicBounds(int,int,int,int) | The drawable to be drawn below the text. |
android:drawableLeft | setCompoundDrawablesWithIntrinsicBounds(int,int,int,int) | The drawable to be drawn to the left of the text. |
android:drawablePadding | setCompoundDrawablePadding(int) | The padding between the drawables and the text. |
android:drawableRight | setCompoundDrawablesWithIntrinsicBounds(int,int,int,int) | The drawable to be drawn to the right of the text. |
android:drawableTop | setCompoundDrawablesWithIntrinsicBounds(int,int,int,int) | The drawable to be drawn above the text. |
更多相关文章
- 浅谈Java中Collections.sort对List排序的两种方法
- python list.sort()根据多个关键字排序的方法实现
- Android(安卓)商显会议平板聚光灯效果实现
- Android实现圆角弹框功能
- 美图秀秀自由拼图android实现
- android:实现双击事件(DoubleClick)
- android实现好看的自定义提示框
- Android(安卓)实现Xmpp工具类
- Android(安卓)通知Notification的两种实现方法