I am trying to display an ImageView with 4 textView. "Name" "times" "age" and "information". All of them are in the global horizontal layout. And 4 textViews are upright. The fact is that I want to have the "time" and "age" of the same line. But it cannot be with a vertical layout. Here is my xml code:
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="wrap_content" android:orientation="horizontal" > <ImageView android:id="@+id/imgLink" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/ic_launcher" /> <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" > <TextView android:id="@+id/title" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Titre" android:textSize="8sp" android:textStyle="bold" /> <TextView android:id="@+id/time" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="8sp" android:text="age" /> <TextView android:id="@+id/age" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="8sp" android:text="age" /> <TextView android:id="@+id/information" android:layout_width="wrap_content" android:layout_height="wrap_content" android:ellipsize="end" android:textSize="8sp" android:text="phrase" /> </LinearLayout>
thanks
source share