0

我想知道如何将两个或多个 UI 元素对齐到屏幕底部,而不是像往常一样堆叠。

4

1 回答 1

0

像这样的东西:

<RelativeLayout
android:id="@+id/myBottomLayout"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
   android:layout_alignParentBottom="true">
     <View
         android:id="@+id/leftItem"
         android:layout_height="wrap_content"
         android:layout_width="wrap_content">
     <View
         android:id="@+id/rightItem"
         android:layout_height="wrap_content"
         android:layout_width="wrap_content"
         android:layout_toRightOf="id/leftItem">
</RelativeLayout>
于 2010-09-25T17:07:03.867 回答