xamarin android制作圆角边框
来源:互联网 发布:一级msoffice模拟软件 编辑:程序博客网 时间:2024/06/05 03:08
xamarin android制作圆角边框
效果图如下:
关键代码:
drawable文件夹新建shape_corner_down.xml
<?xml version="1.0" encoding="utf-8"?><shape xmlns:android="http://schemas.android.com/apk/res/android"> <solid android:color="#dedede" /> <corners android:topLeftRadius="8dp" android:topRightRadius="8dp" android:bottomRightRadius="8dp" android:bottomLeftRadius="8dp"/> <stroke android:width="1dp" android:color="#000000" /></shape>
布局layout文件代码
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="match_parent" android:layout_height="match_parent" android:background="#FFFFFF"> <RelativeLayout android:id="@+id/login_div" android:layout_width="fill_parent" android:layout_height="150dip" android:padding="15dip" android:layout_margin="15dip" android:background="@drawable/shape_corner_down" /></LinearLayout>
xamarin android制作圆角边框原理:
drawable文件夹下新建的xml文件 shape:表示一个形状 ,solid:填充的颜色,corners:表示四个方向的弯曲度,如果四个角度都是一样的可以直接写成<corners android:radius="5dp" /> ,stroke表示边框
2 0
- xamarin android制作圆角边框
- CSS圆角边框 纯CSS制作
- 纯css制作圆角矩形边框
- android圆角边框
- Android边框圆角
- Android 边框圆角
- android 边框圆角
- Android圆角边框
- Android 圆角边框
- Android 边框圆角
- 2. android 边框圆角
- Android实现边框圆角
- Android 圆角边框实现
- android 设置边框圆角
- Android实现圆角边框
- android实现边框圆角
- Android实现圆角边框
- Android实现边框圆角
- 学习笔记:插入排序的C++、JavaScript、Java实现
- 腾讯2017暑期实习生编程题
- 单片机_I2C通讯协议_基础篇
- Git安装与配置
- Java动态代理一——动态类Proxy的使用
- xamarin android制作圆角边框
- 大连网赛 1009 HDU5876 稠密图的最短路
- Centos 6.4 rpm方式不联网安装gcc、gcc-c++
- 多线程编程1
- Spring多数据源配置
- 多线程编程2
- JavaEE中关于路径问题的总结
- 多线程编程3
- 算法二(贪心算法)