android背景圆角的实现
1.建立一个xml文件,命名为circle_corner,放置到drawable目录下,内容如下:
<? xml version ="1.0" encoding ="utf-8" ?>
< shape xmlns:android = "http://schemas.android.com/apk/res/android" >
< gradient android:endColor ="@android:color/transparent" android:startColor ="#000000" android:gradientRadius ="60" android:type ="radial" />
< corners android:radius ="10px" />
</ shape >
2.在需要圆角背景的元件上设置背景为circle_corner
< TextView android:text ="abc" android:background ="@drawable/circle_corner" android:layout_width ="wrap_content" android:layout_height ="wrap_content"
>

更多相关文章

  1. android实现图片模糊背景效果
  2. Android(安卓)ClickableRoundedBackground Span实现(初版)
  3. Android中带分割线的九宫格
  4. Android编程中的常见小问题ZZ
  5. Android系统自带样式Theme总结
  6. android 设置Button或者ImageButton的背景透明
  7. android 之 selector
  8. SJ64 拿起工具(Android(安卓)Studio)开始造轮子(贺卡App)
  9. android——xml drawable实现背景样式

随机推荐

  1. android 网络状态
  2. 暂时只会这种导航,实时显示自己的位置,,求其
  3. Android启动activity的几种方式
  4. android真机调试出现offline解决方法
  5. [Android]编译错误:Could not get unknow
  6. 手机蓝牙和蓝牙模块进行通信
  7. android百度地图:MapController
  8. android 浅谈service
  9. android格式化日期与时间戳学习
  10. 组件(Widget)的复合使用