Or you can use constraint layout and just create a chain of the textviews and use the spread evenly…
Jorge Aguilar
1

Thanks for the suggestion. I tried, with the code below. The layout looks good. But the animation is faulty, i.e. after remove Worst, the space at the end is too wide as per GIF below

<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="?android:attr/actionBarSize"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_margin="4dp"
android:animateLayoutChanges="true"
android:background="#0ff"
android:orientation="horizontal">

<TextView
android:id="@+id/txt_good"
style="@style/MyStyle"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:text="@string/text_good"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toStartOf="@+id/txt_intermediate"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent" />

<TextView
android:id="@+id/txt_intermediate"
style="@style/MyStyle"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:text="@string/text_ok"
app:layout_constraintStart_toEndOf="@+id/txt_good"
app:layout_constraintEnd_toStartOf="@+id/txt_bad"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent" />

<TextView
android:id="@+id/txt_bad"
style="@style/MyStyle"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:text="@string/text_bad"
app:layout_constraintStart_toEndOf="@+id/txt_intermediate"
app:layout_constraintEnd_toStartOf="@+id/txt_worst"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent" />

<TextView
android:id="@+id/txt_worst"
style="@style/MyStyle"
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:text="@string/text_worst"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@+id/txt_bad"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent" />

</android.support.constraint.ConstraintLayout>
One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.