The image above has many problems starting with the icon is not top aligning with the image. Also, I'd love to have UserName centered with respect to the icon.
Finally, I want to have the last line aligned with the bottom of the Image to the left.
I started using layout_weight and i couldn't get it to work. So, I applied hard widths and heights.
Ideally, I would like to have the first ImageView occupy 30% of the row. The Icon would occupy 7% and the rest will be allocated to the textview on first row.
Thanks for your suggestions.
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/custom_shape"
>
<ImageView
android:id="@+id/imgVideo"
android:src="@drawable/video_default_preview"
android:layout_width = "150dp"
android:layout_height= "150dp"
android:layout_marginLeft="10dp"
android:layout_marginRight="10dp"/>
<ImageView
android:id="@+id/imgOwner"
android:layout_width = "35dp"
android:layout_height= "35dp"
android:src="@drawable/icon_default_avator"
android:layout_marginBottom="10dp"
android:layout_alignTop="@+id/imgVideo"
android:layout_marginRight="10dp"
android:layout_toRightOf="@id/imgVideo"/>
<TextView
android:id="@+id/txtUserName"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Plus"
android:layout_marginBottom="10dp"
android:layout_toRightOf="@id/imgOwner"/>
<TextView
android:id="@+id/txtVideoTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Mercedes SL 55"
android:textSize="10sp"
android:layout_marginBottom="10dp"
android:layout_alignLeft="@+id/imgOwner"
android:layout_below="@id/imgOwner"/>
<TextView
android:id="@+id/txtVideoName"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="European Car ..."
android:textSize="10sp"
android:layout_alignLeft="@+id/txtVideoTitle"
android:layout_below="@+id/txtVideoTitle"
/>
</RelativeLayout>