【发布时间】:2015-03-07 17:10:39
【问题描述】:
我遇到了 ScrollView 的问题,它在底部留下了一个空白区域。它填充了几个 TextViews 和 GridViews,应该填充整个 RelativeLayout 父级。
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
tools:context=".showPictures">
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView.../>
<GridView.../>
...
</LinearLayout>
</ScrollView>
</RelativeLayout>
有人知道出了什么问题吗?
【问题讨论】:
-
分享截图
-
使父视图(RelativeLayout)高度匹配父视图
-
设置滚动视图高度为
wrap_content
标签: android gridview scrollview