How To Show The Tab Bar In Bottom, -tab With Fragment
I'm developing a tab based android application,I have seen that 'TabActivity' class is deprecated and instead use the Fragment to achieve the same, I used the following link and de
Solution 1:
First get rid of the outer LinearLayout, it's useless. Then put your TabWidget in last position of your inner LinearLayout and you're done.
Solution 2:
<RelativeLayoutxmlns:android="http://schemas.android.com/apk/res/android"xmlns:tools="http://schemas.android.com/tools"android:id="@+id/relativeLayout"android:layout_width="match_parent"android:layout_height="match_parent"android:gravity="center_horizontal"><TabHostxmlns:android="http://schemas.android.com/apk/res/android"android:id="@android:id/tabhost"android:layout_width="fill_parent"android:layout_height="fill_parent"><LinearLayoutandroid:orientation="vertical"android:layout_width="fill_parent"android:layout_height="fill_parent"android:background="#ff140c14"><FrameLayoutandroid:id="@android:id/tabcontent"android:layout_width="fill_parent"android:layout_height="0dp"android:layout_weight="1"/><TabWidgetandroid:id="@android:id/tabs"android:orientation="horizontal"android:layout_width="fill_parent"android:layout_height="wrap_content"android:layout_weight="0" /></LinearLayout></TabHost></RelativeLayout>
Works for me
Solution 3:
assign inner linear layout orientation vertical and put the Tab Host in the last position of Linear Layout.
Solution 4:
Whatever, bottom Tabbar today is a UX anti-pattern
http://developer.android.com/design/patterns/pure-android.html
Post a Comment for "How To Show The Tab Bar In Bottom, -tab With Fragment"