Often encountered the need to put a control on the bottom of the phone situation, before the linearlayout try to use gravity= "bottom", but, no effect, later on the Internet found the method, as follows
<linearlayout xmlns:android= "Http://schemas.android.com/apk/res/android"Android:layout_width= "Match_parent"Android:layout_height= "Match_parent"android:orientation= "Vertical" > <TextView android:layout_width= "Wrap_content"Android:layout_height= "Wrap_content"Android:layout_marginstart= "12DP"Android:layout_marginend= "12DP"Android:layout_margintop= "12DP"android:textsize= "15SP"Android:textcolor= "#323232"Android:text= "@string/master_clear_final_desc"/>
<!--This is the key, which is to occupy the next screen all the way down--
<LinearLayout Android:id= "@+id/content"Android:layout_width= "Fill_parent"Android:layout_height= "0DP"Android:layout_weight= "1"android:orientation= "vertical" > </LinearLayout> <button android:id= "@+id/execute_master_clear"style= "@style/securitypreferencebuttonfunuiconfirm"Android:text= "@string/master_clear_final_button_text"/></linearlayout>
As for the android:layout_height= "0DP" android:layout_weight= "1 " with the use, has been a little puzzled, do not know what the role of the future will pay attention to, Anyway, this is going to make the Execute_master_clear bureau bottom.
Android-linearlayout controls at the bottom