Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android ListView - small line between items

I really don't know why, but I have a strange line between my list items.

Can somebody guess what it is?

Here is a picture: http://www.directupload.net/file/d/3892/aznspclv_png.htm

My chat_list_item.xml seems to be ok:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/linearLayoutChat"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/darker_gray" >

<com.android.volley.toolbox.NetworkImageView
    android:id="@+id/imgViewChatProfileIcon"
    android:layout_width="30dp"
    android:layout_height="30dp"
    android:layout_marginLeft="10dp"
    android:layout_marginRight="10dp"
    android:layout_marginTop="10dp"
    android:src="@drawable/icon_profile" />

<LinearLayout
    android:id="@+id/chatBox"
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:background="@drawable/chat_box"
    android:orientation="vertical" >

    <TextView
        android:id="@+id/text1"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Text 1"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:textColor="@color/lightblue" />

    <TextView
        android:id="@+id/text2"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_gravity="right"
        android:text="Text 2"
        android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>

like image 673
Maximus1809 Avatar asked Feb 08 '15 11:02

Maximus1809


1 Answers

Set these attribute to your ListView in the layout xml to remove the line:

android:divider="@null"
android:dividerHeight="0dp"

Or these to change its color and thickness:

android:divider="#FF9900"
android:dividerHeight="2px"
like image 52
Thanos Avatar answered Sep 28 '22 19:09

Thanos