我试图在两个EditText小部件之间添加一条水平线,但奇怪的是该线没有填充在底部,所以它显示为“粘在”它下面的小部件。水平线填充
这是我的代码(在layout.xml,与垂直方向的LinearLayout中内):
<EditText android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:capitalize="sentences"
android:singleLine="true"
android:maxLength="30" />
<View android:background="#FF00FF00"
android:layout_width="fill_parent"
android:layout_height="1dip" />
<EditText android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingTop="10dp"
android:scrollbars="vertical"
android:capitalize="none"
android:autoLink="all"
android:maxLines="8" />
,这是它的样子:
我会喜欢在线下添加一些填充。我在View小部件中使用了android:paddingBottom,并在下面的EditText小部件中使用了android:paddingTop,但结果是一样的(它被忽略)。
打秒我:) – Maximus 2011-04-18 16:20:42