[英]Fix view at the bottom of the screen in an Activity in android
我想在屏幕底部固定一個視圖,該怎么辦?
您可以創建一個覆蓋整個屏幕的相對布局,並使用layout_alignParentBottom =“ true”
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"/>
</RelativeLayout>
現在,文本視圖應始終位於屏幕底部。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.