LinearLayout布局中每个控件之间添加分割线
2016-10-17 13:05
309 查看
在drawable文件夹下创建shape类型的xml
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@color/software_textColor_unselected"></solid>
<size android:height="1px"></size>
</shape>
在布局中引用
android:divider="@drawable/hengxian"
android:showDividers="middle"
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<solid android:color="@color/software_textColor_unselected"></solid>
<size android:height="1px"></size>
</shape>
在布局中引用
android:divider="@drawable/hengxian"
android:showDividers="middle"
相关文章推荐
- 控件布局——LinearLayout(上)
- 如何在多个LinearLayout中添加分割线
- Android Material Design :LinearLayoutCompat添加分割线divider
- android之Linearlayout布局下,如何将一个控件置于底部
- Android 布局控件之LinearLayout详细介绍
- android 较高版本,页面分割线实现LinearLayoutCompat布局简单事例
- LinearLayout布局中将一个控件放在屏幕的最下方-Android
- Android UI控件系列:LinearLayout(线性布局)
- Android布局控件之LinearLayout详解
- Android布局控件之LinearLayout详解
- RecyclerView列表布局(LinearLayout)简单分割线
- android 较高版本,页面分割线实现LinearLayoutCompat布局简单事例
- android学习总结(16.08.23)LinearLayout(线性布局)中控件的摆放位置——orientation,gravity,layout_gravity的关系
- Android中利用LinearLayout动态添加控件
- Android:控件布局(相对布局)RelativeLayout RelativeLayout是相对布局控件:以控件之间相对位置或相对父容器位置进行排列。 相对布局常用属性: 子类控件相对子
- Android Linearlayout 添加分割线
- android中在Layout布局文件中添加控件ID,在Activity中findViewById找不到
- 在Layout布局文件中添加控件ID,在Activity中findViewById找不到
- Android 布局之LinearLayout 子控件weight权重的作用详析
- 布局嵌套其他布局(比如说每个页面的顶部都有同样的控件,那就不要一一去添加,采用此方法)