[英]How to decrease the height of a linearLayout with initial height as fill_parent
What I am trying to achieve is to implement a typical texting screen, where I have a LinearLayout initially occupying the whole screen by setting the height to be fill_parent, except a RelativeLayout containing an EditText at the bottom of the screen using android:layout_alignParentBottom. 我想要实现的是实现一个典型的文本屏幕,其中我将LinearLayout最初通过将高度设置为fill_parent来占据整个屏幕,除了RelativeLayout在屏幕底部使用android:layout_alignParentBottom包含EditText之外。
Now, I need to display an extra RelativeLayout at the bottom of the small RelativeLayout, which should reduce the height of the LinearLayout, and push the original RelativeLayout up. 现在,我需要在小RelativeLayout的底部显示一个额外的RelativeLayout,这将减小LinearLayout的高度,并向上推原始的RelativeLayout。
Please advise what is the best way to achieve the above scenario. 请告知实现上述情况的最佳方法是什么。 Thank you. 谢谢。
I find easier the use of RelativeLayout for cases like this. 对于这种情况,我发现使用RelativeLayout更容易。
Good luck friend! 祝你好运的朋友!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.