I am using Material design library and creating layout using CoordinatorLayout
,AppBarLayout ,RecyclerView
and TabLayout
.
My issue is i am unable to see Tab indicator in Tablayout
.Below is my xml file that i am using in AppCompactActivity
.
<android.support.design.widget.CoordinatorLayout
android:id="@+id/coodinate_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@+id/btn_next_screen">
<android.support.v7.widget.RecyclerView
android:id="@+id/list_recycle"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="30dp"
android:background="@color/white"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
/>
<android.support.design.widget.AppBarLayout
android:id="@+id/abar_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar_home"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorPrimary"
android:minHeight="?attr/actionBarSize"
app:layout_scrollFlags="scroll|enterAlways"
>
</android.support.v7.widget.Toolbar>
<android.support.design.widget.TabLayout
android:id="@+id/tab_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:tabBackground="@color/tab_bg"
app:tabIndicatorColor="@color/tab_indicator"
app:tabIndicatorHeight="5dp"
app:tabMode="fixed"
></android.support.design.widget.TabLayout>
</android.support.design.widget.AppBarLayout>
<android.support.design.widget.FloatingActionButton
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="15dp"
app:layout_anchor="@+id/list_recycle"
app:layout_anchorGravity="bottom|right"
android:id="@+id/floatin_ab_home"
app:fabSize="mini"
android:src="@drawable/ic_content_add"
/>
</android.support.design.widget.CoordinatorLayout>
Below is screen which don't showing Tab indicator so can any one known what i am missing .