Skip to content

Instantly share code, notes, and snippets.

@Antarix
Created November 20, 2013 07:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save Antarix/7559204 to your computer and use it in GitHub Desktop.
Save Antarix/7559204 to your computer and use it in GitHub Desktop.
Android ListView item design background like Google+ card
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<!-- Use this color for listview background or your layout #e5e5e5 -->
<item>
<shape android:shape="rectangle"
android:dither="true">
<corners android:radius="2dp"/>
<solid android:color="#ccc" />
</shape>
</item>
<item android:bottom="2dp">
<shape android:shape="rectangle"
android:dither="true">
<corners android:radius="2dp" />
<solid android:color="@android:color/white" />
<padding android:bottom="8dp"
android:left="8dp"
android:right="8dp"
android:top="8dp" />
</shape>
</item>
</layer-list>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment