Guest User

item_list.xml

a guest
May 10th, 2016
17,808
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 2.12 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <android.support.v7.widget.CardView
  3.     xmlns:android="http://schemas.android.com/apk/res/android"
  4.     android:id="@+id/card_view"
  5.     android:clickable="true"
  6.     android:layout_width="match_parent"
  7.     android:layout_height="80dp"
  8.     android:layout_marginBottom="8dp"
  9.     android:layout_marginLeft="16dp"
  10.     android:layout_marginRight="16dp"
  11.     android:foreground="?attr/selectableItemBackground"
  12. >
  13.     <RelativeLayout
  14.         android:layout_width="match_parent"
  15.         android:gravity="center"
  16.         android:layout_height="match_parent">
  17.  
  18.         <ImageView
  19.             android:id="@+id/daftar_icon"
  20.             android:layout_width="40dp"
  21.             android:layout_height="40dp"
  22.             android:layout_centerVertical="true"
  23.             android:layout_alignParentLeft="true"
  24.             android:layout_marginLeft="10dp"
  25.             android:scaleType="centerCrop"
  26.             android:src="@mipmap/ic_launcher" />
  27.  
  28.         <TextView
  29.             android:id="@+id/daftar_judul"
  30.             android:layout_centerVertical="true"
  31.             android:layout_width="match_parent"
  32.             android:layout_height="wrap_content"
  33.             android:layout_marginLeft="16dp"
  34.             android:layout_toRightOf="@+id/daftar_icon"
  35.             android:text="Daftar Judul"
  36.             android:textColor="#000000"
  37.             android:textAppearance="?attr/textAppearanceListItem"
  38.             android:textSize="16sp" />
  39.  
  40.         <TextView
  41.             android:id="@+id/daftar_deskripsi"
  42.             android:layout_width="match_parent"
  43.             android:layout_height="wrap_content"
  44.             android:layout_below="@+id/daftar_judul"
  45.             android:layout_marginLeft="16dp"
  46.             android:layout_toRightOf="@+id/daftar_icon"
  47.             android:textColor="#000000"
  48.             android:ellipsize="end"
  49.             android:singleLine="true"
  50.             android:text="Ini adalah contoh text deskripsi "
  51.             android:textAppearance="?attr/textAppearanceListItem"
  52.             android:textSize="14sp" />
  53.     </RelativeLayout>
  54. </android.support.v7.widget.CardView>
Advertisement
Add Comment
Please, Sign In to add comment