ListView没有分割线怎么办?

<ListView
        
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_marginBottom="51dp"
        android:dividerHeight="1px"
        android:divider="@color/gray13"
        />

只需要添加

android:dividerHeight="1px"     (设置线的粗细)
android:divider="@color/gray13"(设置线的颜色的)
这两句话就好!
原文地址:https://www.cnblogs.com/niupi/p/5772565.html