【发布时间】:2020-09-25 13:45:01
【问题描述】:
这里我使用了滚动视图,我想在页面底部留出一个空间,这样只有条款和条件可以滚动,并且复选框和按钮不滚动它应该在页面底部,你能帮我吗? xml。我附上了一张图片,我想要这样的设计,底部的按钮不会移动Design Example herea
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".Common.PolcyPage">
<LinearLayout
android:id="@+id/liner_layout_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="35dp"
android:layout_marginLeft="35dp"
android:layout_marginTop="60dp"
android:fontFamily="@font/segoe_ui_bold"
android:text="@string/terms_of_services"
android:textColor="@color/colorTandC"
android:textSize="25sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="35dp"
android:layout_marginLeft="35dp"
android:text="@string/updated_date_terms"
android:textColor="@color/colorTandC_titles" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="2dp"
android:layout_marginTop="38dp"
android:background="@color/colorTandC_desc" />
</LinearLayout>
<ScrollView
android:scrollbars="none"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="35dp"
android:layout_marginLeft="35dp"
android:layout_marginTop="35dp"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:fontFamily="@font/segoe_ui_semibold"
android:text="@string/terms_one_title"
android:textColor="@color/colorTandC_titles"
android:textSize="14sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:layout_marginEnd="30dp"
android:layout_marginRight="30dp"
android:text="@string/terms_one_desc"
android:textColor="@color/colorTandC_desc"
android:textSize="13sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="30dp"
android:fontFamily="@font/segoe_ui_semibold"
android:text="@string/terms_two_title"
android:textColor="@color/colorTandC_titles"
android:textSize="14sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:layout_marginEnd="30dp"
android:layout_marginRight="30dp"
android:text="@string/terms_two_desc"
android:textColor="@color/colorTandC_desc"
android:textSize="13sp" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="25dp"
android:layout_marginLeft="25dp"
android:layout_marginEnd="30dp"
android:layout_marginRight="30dp"
android:text="@string/terms_two_desc_terms"
android:textColor="@color/colorTandC_desc"
android:textSize="13sp" />
</LinearLayout>
</ScrollView>
</LinearLayout>
</RelativeLayout>
【问题讨论】:
标签: android android-studio user-interface graphics android-xml