1 当遇到布局底部需要保持内容时 或者横向使用 比例使用
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<android.support.v7.widget.RecyclerView
android:id="@+id/mMyRecyclerView"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@color/white"
tools:listitem="@layout/item_beatch_deliver"></android.support.v7.widget.RecyclerView>
<include
layout="@layout/layout_select_bottom_view"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
android:layout_height="0dp"
android:layout_weight="1"
作用是给与底部空间足够的空间 ,剩余的再给本控件