Creé un archivo de diseño xml para esto, puede inflar esto en su Listview. A continuación se muestra el código fuente de ese archivo xml y la captura de pantalla adjunta de cómo se ve en el Editor gráfico de Eclipse. (Lo siento, no sé cómo formatear texto en estilo de código en Quora).
<LinearLayout xmlns: android = "Página en android.com"
android: layout_width = “match_parent”
android: layout_height = “match_parent”
android: orientación = “vertical”>
<RelativeLayout
android: layout_width = “match_parent”
android: layout_height = “100dp”
android: background = “@ android: color / blanco”>
- ¿Es AndEngine la mejor opción para juegos 2D para Android?
- Cuando fuerzo la detención de una aplicación de Android, ¿todos los permisos de aplicaciones siguen ejecutándose en segundo plano?
- Cómo reparar un sistema Android
- ¿Cuáles son las mejores opciones para un paquete de análisis para una aplicación que abarcará iPhone (y similares) y Android?
- ¿Cuáles son los conocimientos básicos para crear aplicaciones en Android?
<TextView
android: id = “@ + id / textView1”
android: layout_width = “2dp”
android: layout_height = “wrap_content”
android: layout_alignParentLeft = “true”
android: layout_alignParentTop = “true”
android: layout_marginLeft = “30dp”
android: background = “@ android: color / darker_gray” />
<TextView
android: id = “@ + id / textView2”
android: layout_width = “2dp”
android: layout_height = “match_parent”
android: layout_alignParentLeft = “true”
android: layout_marginLeft = “30dp”
android: layout_below = “@ + id / imageView1”
android: background = “@ android: color / darker_gray” />
<ImageView
android: id = “@ + id / imageView1”
android: layout_width = “50dp”
android: layout_height = “50dp”
android: layout_alignParentLeft = “true”
android: layout_marginLeft = “5dp”
android: contentDescription = “@ null”
android: layout_below = “@ + id / textView1”
android: src = “@ drawable / circle” />
<TextView
android: id = “@ + id / textView4”
android: layout_width = “wrap_content”
android: layout_height = “wrap_content”
android: layout_alignTop = “@ + id / imageView1”
android: layout_marginLeft = “30dp”
android: layout_toRightOf = “@ + id / imageView1”
android: text = “@ string / default_text1” />
<TextView
android: id = “@ + id / textView3”
android: layout_width = “match_parent”
android: layout_height = “1dp”
android: background = “@ android: color / darker_gray” />
Captura de pantalla: