Android layout android ListView在RelativeLayout的标题和底部有一条黑线
请帮助我删除标题和底部的黑线。我还附上我的xml供您参考。非常感谢。 我不能发布图片,所以请参考下面的链接Android layout android ListView在RelativeLayout的标题和底部有一条黑线,android-layout,listview,Android Layout,Listview,请帮助我删除标题和底部的黑线。我还附上我的xml供您参考。非常感谢。 我不能发布图片,所以请参考下面的链接 1-使用uselesee容器会使布局过于复杂。2-很容易移除上下阴影。感谢man提供的关键字来解决此问题:)这是yourListView.setVerticalFadingEdgeEnabled(false)是的,从您的第一条评论和关键字“shadow”中,我找到了解决方案:)SolutionFaaaaaaantastic。。。竖起大拇指!!现在,您必须简化布局。我没有把它作为一个答案
1-使用uselesee容器会使布局过于复杂。2-很容易移除上下阴影。感谢man提供的关键字来解决此问题:)这是yourListView.setVerticalFadingEdgeEnabled(false)代码>是的,从您的第一条评论和关键字“shadow”中,我找到了解决方案:)SolutionFaaaaaaantastic。。。竖起大拇指!!现在,您必须简化布局。我没有把它作为一个答案发布,因为它会偏离主题。但我强烈推荐一种优化设计。
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/layoutRemind"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/wood">
<RelativeLayout
android:id="@+id/header"
style="@style/NavBar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
>
<TextView
android:id="@+id/tvTitle"
style="@style/NavBarText"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="center"
android:textSize="18dp"
android:padding="10dp"
android:textAllCaps="true"
android:textAppearance="?android:attr/textAppearanceLarge" />
<ImageButton
android:id="@+id/imgbtnShare"
style="@style/NavBarShareBtn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
/>
</RelativeLayout >
<RelativeLayout
android:id="@+id/footer"
style="@style/NavBar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
>
<ImageButton
android:id="@+id/btn1"
style="@style/NavBarBackBtn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentTop="true"
/>
</RelativeLayout >
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="5dp"
android:layout_above="@id/footer"
android:layout_below="@id/header">
<ListView
android:id="@android:id/list"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:divider="@drawable/divider"
android:scrollingCache="false"
android:overScrollMode="never"
android:dividerHeight="1px"/>
</LinearLayout>
</RelativeLayout >