我有一个简单的TextView,只有一行。我希望将其高度设置为match_parent/fill_parent,但Android的行为是仅包裹内容。
有没有办法强制TextView占据所有高度?
Tkx
编辑:
这就是我得到的:
和我的布局:
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:id="@+id/date"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:gravity="center"
android:paddingLeft="13dp"
android:paddingRight="3dp"
android:textColor="@android:color/white"
android:textStyle="bold" />
[...]
</RelativeLayout>