Использовать настраиваемый TabLayout
<android.support.design.widget.TabLayout
android:id="@+id/tabs"
android:layout_width="match_parent"
android:layout_height="40dp" // select your height
app:tabBackground="@drawable/buttons_selector" // this to customize tabs
app:tabSelectedTextColor="@color/your_tab_text_color"
app:tabTextAppearance="@style/TabTextAppearance"
app:tabIndicatorHeight="0dp" // hide the indicator line
app:tabGravity="fill" // or center
app:tabMode="fixed" // or scrollable
>
отрисовываемый button_selector.xml
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<!-- drawable for selected tab -->
<item
android:drawable="@drawable/button_selected"
android:state_selected="true"/>
<!-- drawable for unselected tab -->
<item
android:drawable="@drawable/button_not_selected"
android:state_selected="false"/>
</selector>
отрисовываемый button_not_selected.xml
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<!-- unselected tab background -->
<solid
android:color="@android:color/transparent" />
drawable button_selected
<?xml version="1.0" encoding="utf-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle">
<corners android:topLeftRadius="10dp" android:topRightRadius="10dp"
android:bottomLeftRadius="10dp" android:bottomRightRadius="10dp" />
<!-- color of the selected tab -->
<solid
android:color="@color/your_color"/>
</shape>
Вы можете играть с цветами, радиусом и т. д.