Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0" encoding="utf-8"?>
- <ListView xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@android:id/list"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:paddingTop="@dimen/menu_padding"
- android:background="@color/customBlue"
- android:divider="@drawable/list_divider"
- android:dividerHeight="2px" />
- <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:tools="http://schemas.android.com/tools"
- android:layout_width="match_parent"
- android:layout_height="50dp"
- android:orientation="horizontal"
- tools:ignore="contentDescription"
- android:background="@color/strongBlue" >
- <ImageView
- android:id="@+id/row_icon"
- android:layout_width="50dp"
- android:layout_height="50dp"
- android:padding="10dp"
- android:src="@drawable/ic_launcher" />
- <TextView
- android:id="@+id/row_title"
- android:layout_width="0dp"
- android:layout_height="match_parent"
- android:layout_weight="1"
- android:gravity="center_vertical"
- android:padding="10dp"
- android:textColor="@color/white"
- android:textAppearance="@android:style/TextAppearance.Medium" />
- </LinearLayout>
- <?xml version="1.0" encoding="utf-8"?>
- <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:bottom="1px">
- <shape android:shape="line">
- <stroke
- android:color="#0C0832"
- android:width="2dp"
- />
- <size
- android:height="1px"
- />
- </shape>
- </item>
- <item android:top="1px">
- <shape android:shape="line">
- <stroke
- android:color="#2D2E57"
- android:width="2dp"
- />
- <size
- android:height="1px"
- />
- </shape>
- </item>
- </layer-list>
- Instead of pixel you can provide dp
- android:dividerHeight="10dp"
- android:divider="#ffffff"
- Instead of making custom drawable for divider you can directly give color to divider.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement