android 将一个容器里 取出两个 放进另一个容器,Android RelativeLayout:当两个视图不在同一个容器中时,如何将视图放在另一个视图下面...

这篇博客探讨了如何通过使用相对布局而非线性布局来改进Android应用的界面设计。作者指出,相对布局可以更好地适应不同屏幕尺寸,提高用户体验。内容涉及设置布局参数,如`match_parent`和`wrap_content`,以及利用`layout_below`和`layout_weight`属性来实现组件的堆叠和权重分配。此方法旨在实现更灵活和响应式的界面设计。
摘要由CSDN通过智能技术生成

我认为你可以通过使用相对布局而不是线性布局来实现这一点.我没有测试过,但它应该工作.

android:layout_height="match_parent"

>

android:layout_width="match_parent"

android:layout_height="50dp">

android:layout_width="120dp"

android:layout_height="wrap_content"

android:layout_below="@id/lotTopTitleBar">

android:layout_height="60dp"

android:background="@null" />

android:layout_height="60dp"

android:background="@null" />

android:layout_height="0dp"

android:layout_below="@id/lotTopTitleBar"

android:id="@+id/lotLL"

android:layout_weight="1">

android:layout_below="@id/lotLL"

android:layout_height="50dp">

编辑

android:layout_below="@id/lotLL"

android:layout_alignParentBottom="true"

android:id="@+id/lotLastLL"

android:layout_height="50dp">

android:layout_height="match_parent"

android:layout_below="@id/lotTopTitleBar"

android:layout_above="@id/lotLastLL"

android:id="@+id/lotLL"

>

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值