Reputation: 2128
So I have a divider.xml
<?xml version="1.0" encoding="utf-8" ?>
<shape xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="@color/red"/>
</shape>
My View looks like this :
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<Mvx.MvxListView
android:id="@+id/suppliersListView"
android:divider="@drawable/divider"
android:scrollbars="vertical"
android:choiceMode="singleChoice"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="left|start"
local:MvxItemTemplate="@layout/item_supplier"
local:MvxBind="ItemsSource ReceptionSuppliersList; ItemClick ReceptionBasicInformationSelectCommand"/>
</LinearLayout>
in @layout/item_supplier i have no red styling attributes.
So when I run the view it shows like this, my 2nd,4th etc... line are way more highlighted then the line between 1st and 2nd element.
Any ideas why?
Upvotes: 3
Views: 412
Reputation: 9187
This is a typically behaviour for an emulator. Some pixels get lost while painting of tiny objects like lines or dots.
Start your app on a real device and it should work properly.
Upvotes: 3
Reputation: 5711
Add below properties in your Listview
And use your prefered color in android:divider
And put Transparent Color in android:cacheColorHint
like below:
android:divider="#00000000"
android:cacheColorHint="#00000000"
android:fadingEdge="none"
Upvotes: 1