android shape设置渐变、圆角、边框线
来源:互联网 发布:java文件上传到服务器 编辑:程序博客网 时间:2024/05/29 19:26
1、渐变实体背景+圆角:
应用场景:按钮
<shape> <gradient android:endColor="@color/theme_24A7F2" android:startColor="@color/theme_1AC6FF" android:type="linear" /> <corners android:bottomLeftRadius="100dp" android:bottomRightRadius="100dp" android:topLeftRadius="100dp" android:topRightRadius="100dp" /> </shape>
2、不带渐变的实体弧角shape
应用场景:弹窗,对话框
<shape xmlns:android="http://schemas.android.com/apk/res/android"><corners android:topLeftRadius="12dp" <!-- 左上角 --> android:topRightRadius="12dp" <!-- 右上角 --> android:bottomLeftRadius="12dp" <!-- 左下角 --> android:bottomRightRadius="12dp"/> <!-- 右下角 --> <solid android:color="#24A7F2"/></shape>
3、带边框的圆角shape
应用场景:按钮
<shape xmlns:android="http://schemas.android.com/apk/res/android"> <solid android:color="#00000000" /><!-- 背景填充颜色 --> <stroke android:width="2dp" android:color="#FF5252" /><!-- 描边,边框宽度、颜色 --> <corners android:radius="100dp" /><!-- 边角圆弧的半径 --></shape>
阅读全文
0 0
- android shape设置渐变、圆角、边框线
- Android使用shape设置虚线、圆角、渐变
- Android中用shape做渐变,边框,圆角等效果
- Android使用Shape进行渐变设置
- Android代码设置Shape渐变色
- android使用shape设置下边框
- android使用shape设置下边框
- shape颜色渐变、圆角、半圆角、边框、填充
- Android背景渐变[shape]
- android shape渐变详解
- Android shape 矩形边框
- android shape 边框
- Android下Shape设置stroke描边部分机型不显示边框线
- Android 背景渐变 渐变背景 shape
- shape边框,圆角
- Android Shape Drawable Resources TextView渐变 背景色 圆角
- Android Shape Drawable Resources TextView渐变 背景色 圆角
- Android drawable shape绘制边框
- python常用模块platform的基本用法
- MySQL常用增删改查
- IDEA 服务器激活教程搭建
- java统计字符串中每个字符出现的次数并查询出现次数最多的字符和次数
- eclipse genymotion插件离线版
- android shape设置渐变、圆角、边框线
- OTA编译失败两种情况的解决办法
- 短文本Python库TextGrocery
- 播放器解码硬解跟软解有什么区别
- js数组删除指定元素
- 错误提示:error while loading shared libraries: libpcap.so.1: cannot open shared object file: No such fil
- sublime text3插件总结
- 数组与字符串长度sizeof()、strlen()、string的length()和size()
- 仿微信,自定义聊天对话框图片控件